Truncated match.
PICList
Thread
'Reset'
2000\03\13@113252
by
Mike Andersen
part 0 514 bytes
<META content=text/html;charset=iso-8859-1 http-equiv=Content-Type>
<META content='"MSHTML 4.72.3110.7"' name=GENERATOR>
</HEAD>
<BODY bgColor=#ffffff>
<DIV><FONT color=#000000 size=2>I would appreciate it if anyone could tell my
how to reset a PIC16C73, without using the watchdog.</FONT></DIV>
<DIV><FONT color=#000000 size=2>It should reset the pic, and clear the
stack.</FONT></DIV></BODY></HTML>
</x-html>
2000\03\13@120450
by
Dan Michaels
|
Mike wrote:
>I would appreciate it if anyone could tell my how to reset a PIC16C73,
without using the watchdog.
>It should reset the pic, and clear the stack.
>
Now, here is a trick which I am sure will frost the butt of any
real programmer. Maybe in some cases, you want to "clear the
stack", but not necessarily need to "reset" the chip per se.
Well, the stack on the PIC "wraps around". This means you can
simply "discard" all those return addresses to break out of a
routine and go back to the top level. So ....
a) Use a h.w. interrupt (timer, RS-232, peripheral, other external),
possibly in conjunction with a flag setting.
b) From inside the interrupt service routine, trap out the specific
event, and use a GOTO back to "start", rather than a RETFIE to
exit. Make sure you reset the interrupt flags, etc.
Great way to break out of an infinite loop. All those levels of
return addresses magically poof into thin air. The stack is "clear".
- Dan Michaels
Oricom Technologies
http://www.sni.net/~oricom
==========================
2000\03\13@121752
by
M. Adam Davis
Tie a pin to MCLR, and raise them both through a resister to high. When you
want to reset, set the pin to output, and low.
After reset the pins are defined as inputs, so you shouldn't have any problems
with it staying in reset.
-Adam
> Mike Andersen wrote:
>
> I would appreciate it if anyone could tell my how to reset a PIC16C73, without
> using the watchdog.
> It should reset the pic, and clear the stack.
More... (looser matching)
- Last day of these posts
- In 2000
, 2001 only
- Today
- New search...