Hi, i'm doing a traffic light project with an IR sensor and a microcontroller. if there is something blocking the connection between the IR emitter and the receiver at specific time, say for 30 seconds, the sensor will send data to the microcontroller that there is a long line of cars. if there is a heavy traffic, the microcontroller will provide an input to the traffic light and then the traffic light will show an output which is a lengthened GREEN light because of the traffic.