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

PCD #rom() syntax changed

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



Joined: 27 Aug 2008
Posts: 2337
Location: Germany

View user's profile Send private message

PCD #rom() syntax changed
PostPosted: Mon Nov 28, 2011 3:28 am     Reply with quote

Hello,

by failure of a previous working application, I became aware of an undocumented change to the #rom syntax of PCD.

While the below code was O.K. to place data into the lower 16 bit of two consecutive 24 bit instruction words up to V4.121
Code:
#rom APP_BASE+4 = {0x1234,0,HEXVERSION,0}

it needed to be changed to the below syntax with V4.124 and later
Code:
#rom APP_BASE+4 = {0x1234,HEXVERSION}


The #rom syntax for EEPROM initialization of respective PIC24 has been kept.
Ttelmah



Joined: 11 Mar 2010
Posts: 19498

View user's profile Send private message

PostPosted: Mon Nov 28, 2011 4:27 am     Reply with quote

Try:
Code:

#rom int16 APP_BASE+4 = {0x1234,0,HEXVERSION,0}


I'd guess that what has happened, is that they have switched the default 'cell size' for the program memory, to an instruction word, instead of int16. Explicitly defining the size might well generate the old behaviour (if needed).
Haven't got PCD with me, so can't check if this does work though.

Best Wishes
FvM



Joined: 27 Aug 2008
Posts: 2337
Location: Germany

View user's profile Send private message

PostPosted: Mon Nov 28, 2011 8:56 am     Reply with quote

Yes, exactly. In contrast specifying int32 type makes the new syntax (without zero fill) work with the older compiler versions as well.

Many thanks
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