Page 1 of 1
Timer circuit in traffic light
Posted: Mon Jun 22, 2020 2:09 am
by Daniel977
Hello everyone
Is there any samples for timer circuits? Im currently trying to build this traffic light system with a timer for each light and finding it a bit hard to do this. Would kindly appreciate the help
Re: Timer circuit in traffic light
Posted: Thu Jun 25, 2020 9:25 am
by Daniel977
So Im trying to make a 4 bit down counter based on the one from sample by changing q and ~q output pin destinations (see image) but there still seems to be some kind of problem. Output on the display shows numbers 22-20, 27-20, 0F, 2E,1E,0E,7E,6E and stops(see image). And ive deleted hour, minute outputs and reset button as well, since i only need a 60 sec countdown. Any suggestions to fix this?
Re: Timer circuit in traffic light
Posted: Thu Jun 25, 2020 10:10 am
by admin
Why do you need down counter? For traffic light you will need a shift register for 3 bits. During the initialization you will set one bit to 1 and other two to 0. Then each clock input shift and cycle the last bit to the first. To send a clock signal to the shift you need to divide frequency with a counter. For simplicity you can count to 64 instead of 60 seconds.
Re: Timer circuit in traffic light
Posted: Thu Jun 25, 2020 10:20 am
by Daniel977
well my task is to design a traffic light with a 7 segment display countdown timer, where green remains ON 59s to 0s, then yellow 5 to 0 and red 30 to 0. You think shift register is a better option for this?
Re: Timer circuit in traffic light
Posted: Thu Jun 25, 2020 10:46 am
by admin
You did not mention the countdown display before. The shift register is for controlling the traffic light itself. The countdown is different story. For more specific discussion please attach your project and provide better description of what you are trying to build.
Re: Timer circuit in traffic light
Posted: Fri Jun 26, 2020 7:10 am
by Daniel977
I've replied in pm.