Professional Documents
Culture Documents
2023 - Fall - Progress Test 1 - 02 - SE17xx - Gy
2023 - Fall - Progress Test 1 - 02 - SE17xx - Gy
Description:
- There are 6 LEDs in the traffic light system: G1, Y1, R1 and G2, Y2, R2 (representing Green,
Yellow, and Red of Street 1-3 and 2-4, respectively).
- There are two modes: auto (A) and manual (M). If the auto mode is selected, traffic lights operate
with the defined delay. If manual mode is selected, the traffic lights are controlled from serial
input.
- In auto mode: the defined delay values are as below:
- In manual mode: input the name of the light (G1, Y1, R1 and G2, Y2, R2) to turn on the
corresponding light, and the others are controlled accordingly.
- In serial input:
1
Rename filename.
Reference:
https://www.civil.iitb.ac.in/tvm/nptel/571_TrSignal/web/web.html
https://www.tinkercad.com/things/bR15c4ltSPD-copy-of-2-way-traffic-light/editel?tenant=circuits
Answer
1. Block diagram:
3. Flowchart (algorithm)
4. Code:
5. Tinkercad link: