Presentation is loading. Please wait.

Presentation is loading. Please wait.

Overview of Project 5 Slides are available at : Project will be checked off in class

Similar presentations


Presentation on theme: "Overview of Project 5 Slides are available at : Project will be checked off in class"— Presentation transcript:

1 Overview of Project 5 Slides are available at : http://www.pages.drexel.edu/~mjm46 Project will be checked off in class http://www.pages.drexel.edu/~mjm46 Matthew Murach

2 Project 5: Traffic Light Controller For this project, you are designing a two way communication system that builds on the principles of project 4. For this project, you are designing a two way communication system that builds on the principles of project 4. There are two separate boards that must be programmed the controller and the traffic light. There are two separate boards that must be programmed the controller and the traffic light. If your project is functioning, you should be able to transmit changes in state as well as observe time out operations of the traffic light If your project is functioning, you should be able to transmit changes in state as well as observe time out operations of the traffic light

3 Project 5: Traffic Light Controller For this project your code should be organized roughly as follows: For this project your code should be organized roughly as follows: Void traffic_light(); Void control(); Void main(); /* starts processes control and traffic light *? Note that like project 4, the traffic_light() and control() functions must be independent of main() and each other. Note that like project 4, the traffic_light() and control() functions must be independent of main() and each other. The control function pushes a change light signal if there is a car i.e. start_press() or a timeout on states has occurred. The control function pushes a change light signal if there is a car i.e. start_press() or a timeout on states has occurred.

4 Project 5: Traffic Light Controller Unlike project 4, this project requires ACK to be sent by the remote site to indicate that the change was accepted. Unlike project 4, this project requires ACK to be sent by the remote site to indicate that the change was accepted. The controller side should then display it’s current state on the LCD. The controller side should then display it’s current state on the LCD. The remote site should indicate one of the four states given in Nagvajara’s notes. i.e. R-G, The remote site should indicate one of the four states given in Nagvajara’s notes. i.e. R-G, R-Y,G-R, and Y-R.

5 Project 5: Traffic Light Controller Since there are two directions i.e. N-S and E-W the start_button() should signify traffic is present in one direction and the stop_button() should indicate traffic is present in the other direction Since there are two directions i.e. N-S and E-W the start_button() should signify traffic is present in one direction and the stop_button() should indicate traffic is present in the other direction Note that an instantaneous change in states by the start or stop button ONLY changes the state iff the other direction has no traffic. Note that an instantaneous change in states by the start or stop button ONLY changes the state iff the other direction has no traffic.

6 Project 5: Traffic Light Controller Red - GreenRed - Yellow Yellow - RedGreen - Red

7 Project 5: Traffic Light Controller Your controller should send a change signal iff a car is waiting in the direction of the stop light and no other traffic is present at the other light. Note that if both roads are busy then the remote site will, after timeout, change the state and hence the light. Your controller should send a change signal iff a car is waiting in the direction of the stop light and no other traffic is present at the other light. Note that if both roads are busy then the remote site will, after timeout, change the state and hence the light. To test your code only one handyboard should be needed. Simply cross-connect the output pins with the input pins. The receive function should poll the input pins and the send function should send a predefined message through the digital outputs To test your code only one handyboard should be needed. Simply cross-connect the output pins with the input pins. The receive function should poll the input pins and the send function should send a predefined message through the digital outputs Note that controller must be updated whenever the remote site is updated. Note that controller must be updated whenever the remote site is updated.


Download ppt "Overview of Project 5 Slides are available at : Project will be checked off in class"

Similar presentations


Ads by Google