1
\$\begingroup\$

I want to protect an Arduino from stop running using a 555 timer. I saw some projects that use the Arduino RESET pin to do that but there are cases that my Arduino project still stop working even when I do a reset using the RESET pin.

So I used the circuit below to cut the 5v line of my Arduino. I choose the 5v line instead of the ground because I have only one 5v pin and more than one ground at Arduino.

My problem is how can the Arduino reset the 555 counter? How can I pulse the 555 to prevent it from disable the Arduino? If I connect the D2 Arduino pin to the Threshold/Trigger/Capacitor pin like I saw on some projects, and keep the capacitor charged, it works when the Arduino is running but if it disables it never turn on again because the Arduino don't allow the capacitor to charge again and it stays forever off.

schematic

simulate this circuit – Schematic created using CircuitLab

asked Apr 30, 2018 at 18:59
\$\endgroup\$
1
  • \$\begingroup\$ I know what cause my problem. If you turn off and turn on the Arduino really fast it can stay in a state on when you ground the reset pin it turn off but come back to the same state when you release the reset. And the circuit is working, I just made it wrong here. I just don't know how to "pulse" the 555. \$\endgroup\$ Commented Apr 30, 2018 at 20:22

4 Answers 4

2
\$\begingroup\$

These microcontrollers used in Arduinos typically contain a so-called Watchdog, which fulfills exactly the role of your 555, but is

  • already integrated, thus needs zero additional components (and thus, sources of failure),
  • uses an amount of power that is, even with lab equipment, pretty much impossible to measure, whereas the classic 555 is a true power hog,
  • can be way more accurate,
  • will reliably reset your system exactly once until it is started again (which you typically do early on in your firmware),
  • is designed and tested by experts for production in the millions to billions and I'd thus expect it to be way more reliable than your own analog circuit and
  • leaves your Arduino in a defined state instead of violently disconnecting it from power, which leads to a brown-out situation with currents flowing in directions noone foresees.

So, abandon the 555 approach and simply learn how to use the watchdog. It's superior in any aspect I can think of.

answered Apr 30, 2018 at 19:04
\$\endgroup\$
3
  • 1
    \$\begingroup\$ Although the watchdog is probably technically correct, the OP seems to be breaking something so fundamental that even a hard reset doesn't fix it - "stop working even when I do a reset using the RESET pin". \$\endgroup\$ Commented Apr 30, 2018 at 19:14
  • 3
    \$\begingroup\$ Which makes it an XY problem. \$\endgroup\$ Commented Apr 30, 2018 at 19:18
  • \$\begingroup\$ Very true, haven't looked at it that way. Op is probably actually overloading something that goes into shutdown or something similar. \$\endgroup\$ Commented Apr 30, 2018 at 19:20
1
\$\begingroup\$

There are easier ways of doing this. There's the internal watchdog timer (WDT) in the Arduino, but there are also dedicated watchdog ICs. These are easier than using a 555 because they are very low power and have configurable time periods. One example is the TI TPL5010 but there are many. When working on a very low power applications sometimes the external watchdog IC uses less current than the internal WDT.

answered Jul 17, 2018 at 23:54
\$\endgroup\$
0
\$\begingroup\$

A watchdog, as described by Marcus is the better solution than a 555 timer. The way that I use a 555 timer is by using a pulse (based on your program) out of the Arduino in your case into the reset pin of the timer. As long as your program is running the 555 gets reset before it "goes off". If you program stops running, then it doesn't get a reset and trigger the processor reset when it times out.

answered Apr 30, 2018 at 19:17
\$\endgroup\$
0
\$\begingroup\$

Some mentioned using the watchdog. I must say that while the watchdog is present it too has failed me multiple times. A hardware reset watchdog is the only sure way. I too am looking for a solution like this but my solution targets pulling down the reset pin. Now if a hard reset such as that doesn't reset the arduino then you may have another more serious problem.

P.S, the FET you are using is that logic level?

answered Jul 17, 2018 at 20:48
\$\endgroup\$

Your Answer

Draft saved
Draft discarded

Sign up or log in

Sign up using Google
Sign up using Email and Password

Post as a guest

Required, but never shown

Post as a guest

Required, but never shown

By clicking "Post Your Answer", you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.