Parallax Forums
  HomeLog InRegisterCommunity CalendarSearch the ForumHelp
   
Parallax Forums > Public Forums > SX Microcontrollers, SX/B Compiler and SX-Key Tool > setting !option for a watchdog in an sxB program  Forum Quick Jump
 
New Topic Post Reply Printable Version
[ << Previous Thread | Next Thread >> ] | Show Newest Post First ]

nick bernard
Registered Member



Email Address Not AvailablePersonal Homepage Not AvailablePrivate Messaging Not AvailableAIM Not AvailableICQ Not AvailableY! Not AvailableMSN Not Available
Date Joined Aug 2004
Total Posts : 329
 
   Posted 7/17/2006 6:38 AM (GMT -8)    Quote This PostAlert An Admin About This Post.
i've never used a watchdog timer before and i'm having trouble
this snippet is giving me compilation errors in the src file. any help?

program is attached

thanks guys
nick

'Watchdog prescale
\ setb !option.3
\ setb !option.2
\ clrb !option.1
\ clrb !option.0


engineer, fireman, bowler, father, WoW addict ;)



File Attachment :
program.txt   3KB (text/plain)
This file has been downloaded 117 time(s).
Back to Top
 

nick bernard
Registered Member



Email Address Not AvailablePersonal Homepage Not AvailablePrivate Messaging Not AvailableAIM Not AvailableICQ Not AvailableY! Not AvailableMSN Not Available
Date Joined Aug 2004
Total Posts : 329
 
   Posted 7/17/2006 6:51 AM (GMT -8)    Quote This PostAlert An Admin About This Post.
'Watchdog prescale
OPTION = %1111_1100

is this sxB line equivalent?


engineer, fireman, bowler, father, WoW addict ;)

Back to Top
 

Bean (Hitt Consulting)
Forum Moderator



Email Address Not AvailablePersonal Homepage Not AvailablePrivate Messaging Not AvailableAIM Not AvailableICQ Not AvailableY! Not AvailableMSN Not Available
Date Joined Jul 2004
Total Posts : 5761
 
   Posted 7/17/2006 7:23 AM (GMT -8)    Quote This PostAlert An Admin About This Post.
Nick,
  You cannot set the option register bit-by-bit.
  You need to set the whole thing at once, like you did in the second post.

Bean.


Cheap 4-digit LED display with driver IC www.hc4led.com
Low power SD Data Logger www.sddatalogger.com
 
"I'm a man, but I can change, if I have to, I guess" The Red Green Show
 

Back to Top
 

nick bernard
Registered Member



Email Address Not AvailablePersonal Homepage Not AvailablePrivate Messaging Not AvailableAIM Not AvailableICQ Not AvailableY! Not AvailableMSN Not Available
Date Joined Aug 2004
Total Posts : 329
 
   Posted 7/17/2006 7:36 AM (GMT -8)    Quote This PostAlert An Admin About This Post.
thanks bean!


engineer, fireman, bowler, father, WoW addict ;)

Back to Top
 
[ << Previous Thread | Next Thread >> ]
New Topic Post Reply Printable Version
 
Forum Information
Currently it is Saturday, November 21, 2009 11:29 AM (GMT -8)
There are a total of 393,855 posts in 55,536 threads.
In the last 3 days there were 84 new threads and 706 reply posts. View Active Threads
Who's Online
This forum has 17692 registered members. Please welcome our newest member, old guy.
65 Guest(s), 16 Registered Member(s) are currently online.  Details
heater, Siri, MichelB, Kenny Gardner, keith_kw, Jay Kickliter, mctrivia, Alsowolfman, Shawn Lowe, dMajo, Harprit, Rick Brooks, Beau Schwabe (Parallax), SRLM, Leon, MicroDirk