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

Interupt functions #include!

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



Joined: 16 Jun 2004
Posts: 5

View user's profile Send private message Send e-mail

Interupt functions #include!
PostPosted: Wed Jan 05, 2005 6:05 am     Reply with quote

Hai
I tried to include my interrrupt function as a seperate file and used # include before main(). Not working.I am using CCS from MPLAB with plug in. Any idea?
Picstudent
Guest








PostPosted: Wed Jan 05, 2005 12:18 pm     Reply with quote

Please let us look at your code and tell us more specifically what is not working.

Happy New Year!
Nick
jds-pic



Joined: 17 Sep 2003
Posts: 205

View user's profile Send private message

PostPosted: Wed Jan 05, 2005 4:06 pm     Reply with quote

also see
http://www.ccsinfo.com/forum/viewtopic.php?t=21424

jds-pic
picstudent



Joined: 16 Jun 2004
Posts: 5

View user's profile Send private message Send e-mail

PostPosted: Wed Jan 05, 2005 10:01 pm     Reply with quote

Hai
I have timer0 interrupt function written just above the main () function.

like

#int_timer0
inter()
{
............
}

main()
{
........
}

It is working alright. Simulation and target is also Ok.

but Now I have written that timer0 interrupt function in a seperate file
called interupt.c and included
like

#include <interupt.c>

main()
{
.....
}

Now no error during compilation,But on simulation interupt is not reaching that c file
Breakepoints cannot be fixed there on that interupt file also.

hope I am clear now

Picstudent
kender



Joined: 09 Aug 2004
Posts: 768
Location: Silicon Valley

View user's profile Send private message Send e-mail Visit poster's website Yahoo Messenger

PostPosted: Thu Jan 06, 2005 11:52 am     Reply with quote

Hi Picstudent,

When I was doing what you have described, my project would not compile. So, to avoid this problem, I would put your ISR (both declaration and code) into an <interrupt.h> file.

Also, take a look at this discussion:
http://www.ccsinfo.com/forum/viewtopic.php?t=21424

Good luck,
Nick[/code]
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