Henrick,
I got your idea to work using a modification to your code. I need do do more testing, but it seems solid. The modified code is as follows:
Code:
i VAR BYTE
Value VAR WORD
Array VAR BYTE[5]
Main:
gosub ClearArray
HSEROUT [" Enter New Motor Runtime x 10",13,10]'enter new Value if needed
HSERIN [STR array\7\13]
IF array[0] = 10 or array[0] = 13 OR array[0] = 0 THEN
arraywrite array,[dec Value] 'this is the old value
endif
ArrayRead array,[DEC Value] 'this is the new value
Goto report
ClearArray:
For i = 0 to 4
array[i] = 0
NEXT
RETURN
report:
write 0,Value.byte1 'write new value to eeprom
write 1,Value.byte0
HSEROUT [ " ",dec Value/10,46,DEC Value dig 0," Seconds",13,10,10]
Bookmarks