Hello,
I use this code to read 32 bits double variable from EEPROM, i call LoadSettings at startup, but I always get this error 'Out of bounds error. Array length = 10, Index = 10'
any ideas?
Thanks
I use this code to read 32 bits double variable from EEPROM, i call LoadSettings at startup, but I always get this error 'Out of bounds error. Array length = 10, Index = 10'
any ideas?
Thanks
B4X:
Private Sub AppStart
Delay(1000)
LoadSettings
B4X:
Private const MEM_CALIBRATION_FACTOR As UInt = 0x0033
private Sub LoadSettings()
Dim tmp4Bytes(4) As Byte
Memory.ReadBytes2(MEM_CALIBRATION_FACTOR,4,tmp4Bytes)
Dim RAF As RandomAccessFile
RAF.Initialize(tmp4Bytes,False)
CalibrationFactor = RAF.ReadDouble32(RAF.CurrentPosition)