Answered step by step
Verified Expert Solution
Question
1 Approved Answer
This task will complete the traffic light system you began in part 1 of this project and will incorporate a pedestrian crossing button / switch
This task will complete the traffic light system you began in part of this project and will
incorporate a pedestrian crossing buttonswitch into the system rather than the system
automatically transitioning and will include a Stateflow Chart block in the model.
A Stateflow Chart is a block in Simulink that allows us to implement finite statemachines
FSMs which are systems that can be described as a
set of states that transition depending on certain
conditions being met. Traffic lights are ideal
examples of FSMs; we can consider this system as
being made up of Three states;
cars go green light and pedestrians stop red
light
cars given caution signal yellow light and
pedestrians stop red light and
Cars stop red light and pedestrians go green light
Part A
Modify the basic structure of the traffic light system you built for part of this project to
simulate use Dashboard components a FSM version of this system that behaves as follows:
The system must still consist of Three traffic lights red
yellow and green and Two pedestrian lights red and green
The system must also have a pedestrian button a Dashboard
push button that detects when a person wants to cross the road.
The FSM must be defined as having Three states only.
State allows the traffic to go the green traffic and red
pedestrian lights will both be on all other lights will be off and
this state will remain active until the pedestrian button is pushed.
After the pedestrian button is pushed, the system will transition
to state where the traffic is cautioned for Three seconds the yellowamber traffic
and red pedestrian lights will both be on all other lights will be off
Finally, state allows the pedestrian to cross the road for Six seconds the red
traffic and green pedestrian lights will be on all other lights will be off
The system must then reset back to state and repeat this process.
For your design methodology, ensure you use an algorithmic state diagram and state
transition table to show how the system should work.
Part B
Once youre happy your simulation is working, and youve troubleshot anything that needs
fixing, replace the simulation blocks Lamps and Pushbutton with the appropriate Arduino
inputsoutputs and deploy this system to the Arduino Uno hardware. The system should
behave the same as before, but red, green, and yellow LEDs should light up instead of the
simulated lamps, and youll use a momentary switch on your breadboard to act as the
pedestrian button.
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started