What could cause a microcontroller to unexpectedly reset?

What could cause a microcontroller to unexpectedly reset?

One particularly irritating variety of bug in a microprocessor-controlled system is for the microprocessor to unexpectedly reset. An important tool for debugging this kind of problem is a list of possible causes. What could cause a microcontroller to unexpectedly reset?

Do you need a VCAP pin on a microcontroller?

Make sure the power rails feeding the processor are stable. May require more cap somewhere, perhaps decoupling cap directly on the processor. Some microcontrollers have a Vcap pin, which must not be connected to VDD and must have its own capacitor to common.

Can a voltage spike on a microcontroller cause reverse current?

Voltage/current spike on any of the microcontroller pins (worst is the oscillator) can cause reverse current and may switch internal register (same as voltage spikes on the supply line). In general, when interfacing to a kind of industrial environment caution needs to be applied (for more see: http://www.ichaus.biz/wp1_mcu_interface ).

What causes a processor to run out of power?

Could be caused by any number of external problems, including a damaged regulator or a dip in the upstream supply. Make sure the power rails feeding the processor are stable. May require more cap somewhere, perhaps decoupling cap directly on the processor.

How to find cause of reset in PIC16F microcontroller?

Haven’t found much in the initial search of the datasheet either: I just found the PCON register in the datasheet (took some searching). See page 61 of the linked datasheet: Haven’t heard of a stack underflow error. Searching the meaning of that now…

How does a watchdog timer work in a microcontroller?

A watchdog timer operates like the computer system in Lost. The rest of the microcontroller is the stressed-out characters who are free to do anything but must periodically service a counter or there is a reset of the microcontroller (AKA the end of the world).