Question: 1- Traffic Light Controller The Question will be implemented using functionality, truth tables, function tables, state diagrams etc. on it. You have to design traffic
1-Traffic Light Controller
The Question will be implemented using functionality, truth tables, function tables, state diagrams etc. on it.
You have to design traffic controller for DLD Square. The configuration of Square is given below.
There are total four roads. Each road has two partitions, one for the traffic coming towards the square (trafficIn) and the other one for traffic going out of the square (TrafficOut). Each partition has three lanes. The cars at right most lane go on the road at right side. The cars in middle lane go straight. The cars in left most lane go on the left side of road. Your task is to implement a system with following requirements:
System should show the flow of cars
Cars will randomly come on TrafficIn partitions
Each lane can have 15 cars at max and you need to display only 4 cars per lane
There is one traffic signal per road for trafficIn. TrafficIn will stop if the signal is red and start running when it turns green
Four signals (one per road) run clockwise i.e. road 1s signal will be green at start, then road 2s then road 3s, then road 4s and then again road 1s signal will be green
Each signal remains green for 16 ticks at max or until there is no car on that road
Signal will turn yellow for 4 ticks before turning red




3 Traffic Light Controller You have to design traffic controller for DLD Square The configuration of quare is given below Traffic There are total four roads. Fach oad has two partitions, one for the traffic coming towards the square (trafficln) and the other one for traffic going out of the square (TrafficOuti. Each artition has three lanes. The cars at right most lane go on the road at right side. The cars in middle lane go straight. The cars n left most la go on the left side of road. Your task is to imp lement a system with following requireme nts: 1 System should sh the flow of cars 2 Cars randomly come on Trafficln partitions 3- Each lane can have 15 cars at max and you need to display only 4 cars per lane 1 There is one traffic signal per road for trafficln. Trafficln ill stop if the signal is red and start running when it turns green 5 Four signals ione p road) run clockwise
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
