The finish line circuit below detects the first of three cars to cross the line and illuminates a 25 watt 120 VAC lamp indicating the winning lane. Three photo transistors are used which can be embedded into the track with a light shining down onto the finish line so that as the car crosses over the sensor, the light is blocked, activating the relay and lighting the lamp for the appropriate track. The light source should be an incandescent type, florescent lights may not work due to low infra-red content. The circuit was tested using a 100 watt incandescent light fixture about 3 feet above the photo transistors.
The photo transistors are connected so that a logic low (0 volts) normally appears at the input to a NAND gate and as a car crosses the line blocking light to the transistor the logic level will move high (+6 volts). The resulting logic low level from the output of the gate (3 input NAND) is fed to a SET/RESET latch made from two dual input NAND gates (1/2 of a 74HC00) the (logic high) output of which controls the MPS2222A buffer transistor and solid state relay. The inverted output of the latch (logic low) is connected back to the remaining two (3 input NAND gate) inputs locking them out. Two extra 74HC00 gates are not used and should have their inputs (pins 9,10,12,13) connected to ground to avoid possible oscillation. The circuit is reset with a momentary push button connected to the reset side of each latch. The reset button may need to be pressed after power is first applied. Components for the circuit may be obtained from Radio Shack, however the RSU numbers may need to be special ordered or obtained from another source. The 74HC00 and 74HC10 are CMOS parts and should be handled carefully to avoid possible damage from static electricity. You may want to use IC sockets so the wiring can be completed before the ICs are inserted into the sockets. You can briefly touch a grounded surface (computer chassis or other metal ground surface) just before handling CMOS circuits to reduce the possibility of damage from static electricity.
circuit from http://www.bowdenshobbycircuits.info/page7.htm#derby.gif