CCS C Software and Maintenance Offers
FAQFAQ   FAQForum Help   FAQOfficial CCS Support   SearchSearch  RegisterRegister 

ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

CCS does not monitor this forum on a regular basis.

Please do not post bug reports on this forum. Send them to CCS Technical Support

wake up from sleep on pin change 10F222

 
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion
View previous topic :: View next topic  
Author Message
mvanvliet



Joined: 02 Jun 2009
Posts: 123
Location: The Netherlands

View user's profile Send private message

wake up from sleep on pin change 10F222
PostPosted: Fri Aug 07, 2009 3:49 am     Reply with quote

Is there a function which can be used when the 10F222 is waked up from sleep due to a pin change? In the datasheet there is a GPWUF flag which is set when the pic is waked up from sleep from pin change. In the 10F222.h file there a some options with the restart_cause() but not "on pin change".

I want to change a variable when the pic wakes up from sleep. So any other option is also welcome.

IDE: 4.092
mvanvliet



Joined: 02 Jun 2009
Posts: 123
Location: The Netherlands

View user's profile Send private message

PostPosted: Fri Aug 07, 2009 5:13 am     Reply with quote

Maybe I've already solved this problem with adding the following to my program:

Code:

#use standard_io(b)
#bit GPWUF = 3.7


and in the main loop:

Code:

if(GPWUF == 1)
   {
   uitgang = 0;
   }
Display posts from previous:   
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group