Defines a object data structure in eeprom (Syntax 1) or a expression (Syntax 2+3) accessing the whole eeprom-memory. Ensure that you don't violete the structure boundary because this will overwrite the succeeding data. Syntax 1:

  • eeprom Identifier
    • Data
  • endeeprom

Syntax 2:

Syntax 3:

  • Result = eeprom.Method/Property

^Method (read only)^^^

Name Description Return Type
.ByteValue(offset)Read Byte byte
.WordValue(offset)Read Word word
.IntegerValue(offset)Read Integer integer
.LongValue(offset)Read Long long
.SingleValue(offset)Read Single single
.StringValue(offset,bytes)Read String of certain length string
.PString(offset)Read Pascal-String (Start-Byte is the length) string
.CString(offset)Read C-String (Null terminated) string
.AddrAddress of data structure in Flash word
.SizeOfRead Size in Byte of the object byte
  • offset: Byte-Position within the structure starting at zero.
  • bytes: Number of Byte to read.

data storage

The directives for the storage of data within a data object.

  • .db - 8 Bit values incl. strings
  • .dw - 16 Bit values
  • .dt - 24 Bit values
  • .dl - 32 Bit values

Accessing areas outside the object boundary is possible and not checked.


dim a as byte
dim s as string
a=table1.ByteValue(4) ' Read Byte of tabele1+4, reszlt: 5
s=table1.CString(12)  ' Read C-String, result: "Hello"
table1.ByteValue(1)=7 ' Write Byte
table1.CString(0)="I am an eeprom-String"  'Write string
a=eeprom.ByteValue(4)   ' Read a Byte from eeprom memory
eeprom.ByteValue(4)     ' Write a Byte from eeprom memory
' Define Data Structure in eeprom
' Note:
' The compiler stores the eeprom-values and strings in the file *.eep.
' They must also be uploaded to the controller.
eeprom table1
  .db 1,2,3,4,5
  .dw &h4af1,&hcc55,12345
  .db "Hello",0