AnsweredAssumed Answered

QD4 EEPROM location read

Question asked by David Grimes on Nov 5, 2013
Latest reply on Dec 17, 2013 by David Grimes

I must be overlooking something simple, but I can't see it.

 

Using the Flash.zip routines Bigmac posted years ago, with a QD4 and CW10.X my PRM file is modified like:

SSTACK_SEG = NO_INIT 0x00C0 TO 0x00FF;

EEPROM_SEG = READ_ONLY 0xF800 TO 0xF9FF;

ROM1 = READ_ONLY 0xFFC0 TO 0xFFCF RELOCATE_TO 0x00C0;

 

with

SSTACK INTO SSTACK_SEG;

EEPROM INTO EEPROM_SEG;

FLASH_ROUTINE INTO ROM1;

 

In the main.c I am locating my variable in the EEPROM space:

#pragma CONST_SEG EEPROM

const byte telltale;

#pragma CONST_SEG DEFAULT

 

During use, I flash this location when:

if (maxrpm > telltale)

Flash_Program(0xF800, maxrpm)

 

and wanted read this back after a power cycle:

 

telltale = (char*)0xF800;

 

But it won't compile after I added the read back, how should I access this location?

Outcomes