I am working on a system with a microcontroller than controls other microcontrollers, mainly sending commands to the other micros.

I built in a Watchdog Overflow function on the 8051, which basically just puts the device in an endless loop, thus not kicking the watchdog periodically, which then makes it fall over (reset). Like: for(;;)

The way I understand is that overflowing the watchdog in firmware is essentially the same as doing a hardware reset on the micro.

Why do I then get different results when overflowing the watchdog than power cycling the entire unit?

The 8051 is the heart of the unit and controls all the other devices.

  • 1
    \$\begingroup\$ How are the results different? Obviously, the watchdog reset on the "master" 8051 isn't going to have any effect on the other processors; if they need to be reset as well, the 8051 will have to take care of that in its startup code. \$\endgroup\$
    – Dave Tweed
    Apr 8, 2015 at 11:27
  • \$\begingroup\$ Yes the 8051 has functions to initialize all of the rest. Something must be missing, like explained in the answer below, to reset everything to default and then re-initialize. I think I should look at resetting all of the other modules before resetting the micro, the will hopefully have the same result as a power down? \$\endgroup\$
    – AJBotha
    Apr 8, 2015 at 11:49

1 Answer 1


Power cycling resets everything except battery backed RAM and ROM's to a defaulted state. Flip flops are set (or should be) to a default state, other smart chips like communication IC's or other intelligent controllers go through their own default boot sequence.

Just resetting the processor doesn't do all that.

That is visible even on regular PC's on occasion, if something goes wonky, just restarting the OS doesn't necessarily fix it, sometimes you have to power the box down, and press the big button again.

  • \$\begingroup\$ The board has flip flops, I2C chip, and RAM to name but a few. I basically want to be able to remotely simulate a power cycle, so I guess I will have to take a closer look at resetting peripherals before resetting the micro. For the same amount of effort I might just as well investigate why it is falling over in the first place. I strongly suspect an I2C bug, which is used to communicate with all of the other peripherals. Thanks! \$\endgroup\$
    – AJBotha
    Apr 8, 2015 at 11:52

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.