Hi Raphael, > Hi Vaclav, > > > I'd like to move some strings like CONNECT, PASSWORD, USERID etc. > > from code to eeprom to spare memory. How can I statically initialize > > EEPROM ? I tried something like: > > > > unsigned char at 0x2100 EEPROM_CONNECT[] = "CONNECT"; > > > > but SDCC does not recognize that this should be directly stored in > > EEPROM... > > Do you mean __code memory? Then try either > __code unsigned char EEPROM_CONNECT[] = "CONNECT"; > or > __code unsigned char __at(0x2100) EEPROM_CONNECT = "CONNECT"; >
I forgot to mention that I use PIC14 port. I had on mind to move the strings into data EEPROM which is 8-bit. With __code I get 16-bit "retlw xx" instruction while I want just to store 0x43. In HEX file I see :0E42000043344F344E344E344534433454343A and I want something like :08420000434F4E4E45 ... etc. Vaclav ------------------------------------------------------------------------- This SF.net email is sponsored by: Splunk Inc. Still grepping through log files to find problems? Stop. Now Search log events and configuration files using AJAX and a browser. Download your FREE copy of Splunk now >> http://get.splunk.com/ _______________________________________________ Sdcc-user mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/sdcc-user
