Here's the regulation from the days of steam (it's quoted in the manual for the Consolidation):
"Required illumination.
(a) General provisions. Each steam locomotive used between sunset and sunrise shall be equipped with an operable
headlight that provides illumination sufficient for a steam locomotive engineer in the cab to see, in a clear atmosphere,
a dark object as large as a man of average size standing at least 800 feet ahead and in front of such headlight. If a steam
locomotive is regularly required to run backward for any portion of its trip other than to pick up a detached portion of its
train or to make terminal movements, it shall also be equipped on its rear end with an operable headlight that is capable
of providing the illumination described in this paragraph (a).
(b) Dimming device. Such headlights shall be provided with a device whereby the light from same may be diminished in
yards and at stations or when meeting trains."