Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Consider the controller of a traffic light. This traffic light is at the intersection of a little used farm road and a busy highway. Detector

image text in transcribed

Consider the controller of a traffic light. This traffic light is at the intersection of a little used farm road and a busy highway. Detector Cdetects a car on the farm road The light remains green for the highway until a car is detected on the farm road. Once a car is detected on the farm road, the highway light goes from green to yellow for 5 seconds and then from yellow to red. .Both lights will be red for 5 seconds and then the farm road light will go green he farm road light stays green until no more cars are detected, or 40 seconds has assed When the farm road light transitions, it goes to yellow for 5 seconds and then to red Both lights will be red for 5 seconds and then the highway light will go green Once the highway goes green, it stays there at least 40 seconds, even if another car is detected on the farm road Create a state transition diagram for the traffic light controllier. Submit the diagram Write the C code for the traffic light state machine. You may only use Arduino code for the delay functions. Use the format in the Mustang blinker example as a guide to the format Assume the set up below tEtE Hirhway Lig Ferm Roed Lihts 2 Consider the controller of a traffic light. This traffic light is at the intersection of a little used farm road and a busy highway. Detector Cdetects a car on the farm road The light remains green for the highway until a car is detected on the farm road. Once a car is detected on the farm road, the highway light goes from green to yellow for 5 seconds and then from yellow to red. .Both lights will be red for 5 seconds and then the farm road light will go green he farm road light stays green until no more cars are detected, or 40 seconds has assed When the farm road light transitions, it goes to yellow for 5 seconds and then to red Both lights will be red for 5 seconds and then the highway light will go green Once the highway goes green, it stays there at least 40 seconds, even if another car is detected on the farm road Create a state transition diagram for the traffic light controllier. Submit the diagram Write the C code for the traffic light state machine. You may only use Arduino code for the delay functions. Use the format in the Mustang blinker example as a guide to the format Assume the set up below tEtE Hirhway Lig Ferm Roed Lihts 2

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access with AI-Powered Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Students also viewed these Databases questions