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

Does the compiler disable Interrupts during read_eeprom()

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



Joined: 21 Jul 2006
Posts: 21

View user's profile Send private message

Does the compiler disable Interrupts during read_eeprom()
PostPosted: Fri Nov 24, 2006 2:18 am     Reply with quote

I have a 16f877 based project.I have two question:

1.Does the compiler disable Interrupts during read_eeprom() and write_eeprom()?
2. If not, Do I need to disable Interrupts when using read_eeprom() and write_eeprom() for data read/write safety?

Thanks in advance!
davekelly



Joined: 04 Oct 2006
Posts: 53
Location: Berkshire, England

View user's profile Send private message

PostPosted: Fri Nov 24, 2006 2:56 am     Reply with quote

Interrupts are disabled for both read_eeprom() and write_eeprom() automatically.
rwyoung



Joined: 12 Nov 2003
Posts: 563
Location: Lawrence, KS USA

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

Re: Does the compiler disable Interrupts during read_eeprom
PostPosted: Sat Nov 25, 2006 10:54 am     Reply with quote

suncq wrote:
I have a 16f877 based project.I have two question:

1.Does the compiler disable Interrupts during read_eeprom() and write_eeprom()?
2. If not, Do I need to disable Interrupts when using read_eeprom() and write_eeprom() for data read/write safety?

Thanks in advance!


davekelly answered your direct question but as a followup, you can learn EXACTLY what the compiler is doing by looking at the resulting LST file. You can see the assembly code in all its glory (or gore?).

Learning to read and understand what the various assembly commands do as well as having the memory map for your particular PIC handy go a long way in figuring out what may on the surface seem to be a very mysterious problem.

You don't have to be proficient in PIC assembly language, just know enough to read it. Cool
_________________
Rob Young
The Screw-Up Fairy may just visit you but he has crashed on my couch for the last month!
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