Good day folks. I'm trying to build a little circuit for a project of mine which requires pressing a button to toggle an output in the following fashion: if the button is held for around 5s, the output goes high. When the button is released, the output goes low instantly. If the button is released before the output actually goes high, the next press of the button should require 5s again before the output goes high again. This last bit is important, because what I was able to find was THIS circuit which uses the 555 timer to create a delayed-on circuit.
There's a couple of caveats I'm facing though: obviously you can see there's no button there - the countdown essentially starts when power is first applied to the whole circuit, so I'm not quire sure where I should drop the button. I guess I could cut VCC to the whole circuit using a SPDT. Even after the fact, I simulated this circuit and although it works, there's still the problem I mentioned earlier: if the button is released too soon, before the output actually swings high, the next press turns it on instantly, since the capacitor is still charged and pin 2, TR, is pulled to GND immediately. I cannot figure out how to overcome this...I tried coming up with various ways to "discharge" that cap so it'd be ready for a new cycle, but couldn't find one that works.
Most circuits I've seen work in the completely opposite way: the turn-on is instant and they SLOOWLY discharge the cap to get a delayed-OFF...
Any ideas on how to achieve such result ? Thanks.
EDIT: here's another idea I came up with and simulated and seems to work. I ditched the 555 entirely and used a MOSFET instead. I got the idea after watching THIS here video which coincidentally or not also talks about a delayed on>instant off scenario towards the end.
There's a couple of caveats I'm facing though: obviously you can see there's no button there - the countdown essentially starts when power is first applied to the whole circuit, so I'm not quire sure where I should drop the button. I guess I could cut VCC to the whole circuit using a SPDT. Even after the fact, I simulated this circuit and although it works, there's still the problem I mentioned earlier: if the button is released too soon, before the output actually swings high, the next press turns it on instantly, since the capacitor is still charged and pin 2, TR, is pulled to GND immediately. I cannot figure out how to overcome this...I tried coming up with various ways to "discharge" that cap so it'd be ready for a new cycle, but couldn't find one that works.
Most circuits I've seen work in the completely opposite way: the turn-on is instant and they SLOOWLY discharge the cap to get a delayed-OFF...
Any ideas on how to achieve such result ? Thanks.
EDIT: here's another idea I came up with and simulated and seems to work. I ditched the 555 entirely and used a MOSFET instead. I got the idea after watching THIS here video which coincidentally or not also talks about a delayed on>instant off scenario towards the end.
Comment