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

No compiler error using #ROM beyond Data EEROM space

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



Joined: 13 May 2013
Posts: 51
Location: Arizona

View user's profile Send private message Visit poster's website

No compiler error using #ROM beyond Data EEROM space
PostPosted: Sat Jun 29, 2019 2:23 pm     Reply with quote

Compiler = PICC 5.085
Device = 16F1788 with 256 bytes of EEROM

Interest is to preload EEROM space with data;

Code:

#DEFINE EEMEMSTART getenv("EEPROM_ADDRESS")
#DEFINE EESTATMEM EEMEMSTART+300
#ROM EESTATMEM={0xF,0xF}

------
Start address of Data EEROM (0xF000) + 300
is obviously more than 256 bytes
therefore a compiler error should be reported
when I attempt to compile 2 bytes at 0xF12C

...but it doesn't.

Any comments on this?

Confused
temtronic



Joined: 01 Jul 2010
Posts: 9241
Location: Greensville,Ontario

View user's profile Send private message

PostPosted: Sun Jun 30, 2019 4:39 am     Reply with quote

I'll take a 'stab' at it....
I downloaded the datasheet and the 256 bytes of EEPROM are accessed differently than 'regular' memory according to section 3.0 'memory organization. To access the 256 bytes of DATA EEPROM, you need to see section 12.
The address you post 0xF000 is within the 'normal' memory map (see figure 3.8). It's the Program Flash memory section. As such it's a valid address.
Only had 1 coffee so far, so I might be wrong..
PCM programmer



Joined: 06 Sep 2003
Posts: 21708

View user's profile Send private message

PostPosted: Sun Jun 30, 2019 11:39 am     Reply with quote

If you want an error message over this, email CCS and ask them to
put it in. But be aware that there will be some bugs introduced, at least
initially, if they do this. Some PICs will throw an error if you do correctly.
Then you'll have to report it, and wait for the next revision or maybe
get a temporary DLL fix.

I don't think it's worth it. Just read the data sheet carefully.
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