stops execution of a program and puts the PIC to sleep until reset or watchdog timeout.
The assembly language sleep instruction does for a PIC what the End instruction does for the BASIC Stamp; it shuts down the clock oscillator, halting program execution and reducing current draw to a few microamperes. If the PIC's watchdog timer is disabled (by a _wdt_off switch in the _config directive), that's it until the PIC is reset.
However, if the watchdog timer is on, the PIC will reawaken at the next timeout. If you want a watchdog-protected PIC to stay asleep, you must include code that checks the timeout and power-down bits (to and pd) for 00 and immediately puts the PIC back to sleep. See the section on the Sleep instruction for more information.
|file: /Techref/microchip/seepicsrc/psbpix/end.htm, 2KB, , updated: 2002/1/4 20:54, local time: 2023/6/9 06:46,
|©2023 These pages are served without commercial sponsorship. (No popup ads, etc...).Bandwidth abuse increases hosting cost forcing sponsorship or shutdown. This server aggressively defends against automated copying for any reason including offline viewing, duplication, etc... Please respect this requirement and DO NOT RIP THIS SITE. Questions?|
<A HREF="http://techref.massmind.org/techref/microchip/seepicsrc/psbpix/end.htm"> microchip seepicsrc psbpix end</A>
|Did you find what you needed?|
Welcome to massmind.org!
Welcome to techref.massmind.org!