Skip to main content
Visitor II
October 21, 2003
Question

Constants in EEPROM ST7Flite0

  • October 21, 2003
  • 3 replies
  • 735 views
Posted on October 21, 2003 at 07:06

Constants in EEPROM ST7Flite0

    This topic has been closed for replies.

    3 replies

    Visitor II
    October 11, 2003
    Posted on October 11, 2003 at 15:36

    How can I define constants with indart / assembler in the EEPROM.

    Thanks and regards

    hansjusch
    Visitor II
    October 13, 2003
    Posted on October 13, 2003 at 04:52

    With Cosmic compiler:

    You can use @eeprom to declare variables in EEPROM

    @eeprom char var1;

    or you can use #pragma to declare all your variables in EEPROM

    The compiler uses a runtime library for eeprom variable operations

    With Metrowerks compiler:

    You can define a different data segment for EEPROM variables and constants and then define this segment in .prm file

    in source file use

    #pragma DATA_SEG EEPROM_DATA

    unsigned char var1;

    in .prm file use

    PLACEMENTS

    EEPROM_DATA INTO EEPROM

    refer to compiler manual for read write operations as they may require some EEPROM register settings.

    Hope this Helps,

    Best Regards,

    PraveenG
    Visitor II
    October 21, 2003
    Posted on October 21, 2003 at 07:06

    Dear PraveenG

    Thanks for Your answer.

    My concern are constants (like look- up tables or character- strings) directly programmed in the EEPROM with InDart / Assembler.

    Kind regards

    hansjusch