Our legal system is not black-and-white – it is a constant balancing of conflicting rules, conflicting interests & policies, and conflicting facts & circumstances. The “law” is not ultimately what is in the books, but what a judge says it is in a given case.
Yes, there is a general legal principle that, if the law requires certain people (but not others) to do something (like stop at a RR crossing), then there is an assumption (not necessarily conclusive) that those others don’t have to follow that rule under the same circumstances. (By the time I went to law school, even the Jesuits didn’t require Latin, so I won’t try to quote the technical name of the principle!)
And yes, a train always has right-of-way, so all crossing traffic has to always be prepared to yield, and stop if necessary.
And yes, if there is active crossing protection, the driver is allowed to assume that there is no train, if the crossing protection is not activated.
And yes, every driver must always control his/her vehicle, such that he/she can stop in time to avoid any mishap (a rear-ender is almost always the fault of the rear car, regardless of how unreasonable was the stopping of the front car).
And yes, if the traffic control equipment does not give sufficient warning, given the allowed & reasonable speeds & traffic conditions, then this may be considered a mitigation of the driver’s responsibility.
Bottom line, even if there is no ambiguity whatsoever in a signal (or rule), there were still b