This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

how to locate variables @ fixed locations

hi all!

i'd like to locate a variable (e.g. version number) at a fixed location in ROM, so the firmware can check the userware's version @ startup!

userware:
int version = 1; // locate this @ 0x1000 - but how ?!

firmware:
if (*((int*)0x1000) != 1)
{
DisplayErrorMessage();
}

how can I achieve this using C166/L166 ?!

thanks in advance for any help...

Matthias

Parents
  • Ah, yet another request from someone who wants to use the _at_ keyword with an initialiser.

    Matthias, this has been discussed many times on the forum. It can be done but not easily. Search for the _at_ keyword.

    Stefan

Reply
  • Ah, yet another request from someone who wants to use the _at_ keyword with an initialiser.

    Matthias, this has been discussed many times on the forum. It can be done but not easily. Search for the _at_ keyword.

    Stefan

Children
No data