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 this SYM file show a RAM corruption ??

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



Joined: 08 Sep 2003
Posts: 492
Location: India

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

Does this SYM file show a RAM corruption ??
PostPosted: Sat Dec 23, 2006 12:51 pm     Reply with quote

Hi,

MCU: 16F877A
PCM 3.228

Does the following extract of .SYM file show something wrong with the RAM addresses ??

0B6 get_command.cCommand
0B6 @delay_us1.P1
0B6-0B9 interpreter.nAddrs1
0B6-0B9 processloop.nAddrs1
0B6 process_command.cCommand
0B6 process_input.@SCRATCH
0B6 execute_procedure.@SCRATCH
0B7 write_eeprom16byte.nAddress
0B7 read_eeprom_32byte.nAddress
0B7 read_eeprom16byte.nAddress
0B7 @delay_ms1.P1
0B7 get_command.@SCRATCH

are some of the locations being shared ??

thanks
arunb
PCM programmer



Joined: 06 Sep 2003
Posts: 21708

View user's profile Send private message

PostPosted: Sat Dec 23, 2006 1:38 pm     Reply with quote

CCS reuses the RAM locations for local variables in sub-routines.
The local variables only have to exist while the sub-routine is active.
Once the program control has returned from the sub-routine, the
RAM location can be used for the next sub-routine. This memory
allocation is determined by the compiler when it compiles your code.

However, if you declare a variable in a sub-routine to be 'static',
then the compiler will not re-use it.
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