Traffic Light Controller
Introduction
In this project I am going to design and stimulate a traffic light controller. If done correctly my traffic light controller will oscillate through the light inputs just light a regular traffic light on the road. I will be using 4 Flip Flop D Up Mod 9 Counter which will then control the light sequence going from green, to yellow, and then to red. I will first start by making the counter. I will then modify the counter which originally counts from 0 to 15. I am going to change it to go from 2 to 11. The numbers 0 and 1 will be "don't care" conditions as well as 11 to 15. Once done with making the counter I will create the AOI circuit to make the probes set off at the proper numbers. If done correctly green displays at 2, 3, and 4. Yellow will display at 5, 6, and 7. Lastly, red will display at 8, 9, 10.
Truth Table
Unsimplified Logic Expression
Green: A'B'CD'+A'B'CD+A'BC'D'
Yellow: A'BC'D+A'BCD+A'BCD'
Red: AB'C'D+AB'C'D+AB'CD'
Yellow: A'BC'D+A'BCD+A'BCD'
Red: AB'C'D+AB'C'D+AB'CD'
K-Map
Simplified Logic Expression
Green: BC'D'+A'B'CD'
Yellow: BCD'+AB'CD'
Red: A'C'D+AB'C'D
Yellow: BCD'+AB'CD'
Red: A'C'D+AB'C'D
Multisim Circuit
Conclusion
In this project I successfully created a traffic light controller that would go from green, to yellow, to red. I began by creating a truth table. The truth table had 4 inputs and had 3 outputs, which were green, yellow, and red. The outputs for 0 and 1 are "Don't Care" because they are not included in the counter making them irrelevant. That is also the case for 11, 12, 13, 14, and 15. For the numbers 2, 3, and 4 only green is turned on, and that is signified by a 1 on the truth table, while the other outputs have a 0. For the numbers 5, 6, and 7 only yellow is turned on, and that is signified by a 1 on the truth table, while the other outputs have a 0. For the numbers 7, 8, and 9 only red is turned on, and that is signified by a 1 on the truth table, while the other outputs have a 0. Once done I began my K mapping. For the K mapping I began by putting the outputs on three separate tables. I then did my grouping and simplified them. However the simplified K mapping logic expressions did not work for the counter like it should have so I had to also simplify it with Boolean Algebra, which ended up working out for me in the end. Once done with the K mapping and making the simplified logic expressions, I went on multisim to begin creating my circuit of the traffic light controller. I started by putting down 4 D Flip Flops. I also placed down a clock, a power source, a ground, a 4 input NAND gate, single pole double throw, and a green hex display. Once I had everything I began my wiring. I started by wiring the ground to my clock and the single pole double throw. I then changed the net color so that I knew that, those specific wires and items were grounded. I then connected my power source to the preset of the 1st, 3rd, and 4th D Flip Flops. I connected the power source to the clear of the 2nd D Flip Flop. I did this because I wanted to make the number the hex display starts at 2. Since in binary the number 2 is shown as 0010 and I have to do it backwards do to the circuit it looks as if it is 0100. I then went to the NAND gate and connected it to the opposite. Say if it went to clear for power it would go to preset from the NAND gate. Once everything was wired I connected it to my signaling probes. It indeed did work and counted from 2 to A (which is 10). Once I saw that worked I created my AOI circuit with the signifying probes being the A, B, C, and D. The one all the way on the left was A, and all the way to the right was D. I then made the three different circuits, connecting each to the corresponding probe. I then stacked the probes so that they looked like a traffic light, and hit play on the circuit. It worked!