HI Charles,
The @ ReadConfig?BB macro uses a BYTE variable as an offset from 300000h (CONFIG space). It can't read the ID locations (200000).
You can read them with the ?CB macro ...
Code:
@ ReadConfig?CB 200000h, _User1
--OR--
@ ReadConfig?CB _IDLOC0, _User1
Or you could add this macro to the RTconfig include, which will let you use an offset from the first ID loc...
Code:
ReadID?BB macro Breg, Bout
movlw upper(_IDLOC0)
movwf TBLPTRU, A
movlw high(_IDLOC0)
movwf TBLPTRH, A
movff Breg, TBLPTRL
TBLRD* ; read the ID byte
movff TABLAT, Bout
endm
Then you could ...
Code:
FOR X = 7 to 0 STEP -1
@ ReadID?BB _X, _User1
LCDOUT HEX2 User1
NEXT X
Bookmarks