STORE - BASIC Stamp Command Reference
Page 324
•
BASIC Stamp Programming Manual 2.0b
•
www.parallaxinc.com
' -------------------------- Main Routines --------------------------
Main:
GOSUB DisplaySlotsAndReadData
PAUSE 2000
STORE 1 'Switch to READ/WRITE slot 1
GOSUB DisplaySlotsAndReadData
PAUSE 2000
RUN 1 'Switch to program 1
' --------------------------- Subroutines ---------------------------
DisplaySlotsAndReadData:
GET 127, Value
DEBUG CR, "Prog Slot: ", DEC1 Value.LOWNIB
DEBUG " R/W Slot: ", DEC1 Value.HIGHNIB, CR, CR
FOR Idx = 0 TO 4
READ Idx, Value
DEBUG "Location: ", DEC Idx, " Value: ", DEC3 Value, CR
NEXT
RETURN
Demo Program (STORE1.bsp)
DATA @0, 6, 7, 8, 9, 10
Idx VAR WORD
Value VAR BYTE
' -------------------------- Main Routines --------------------------
Main:
GOSUB DisplaySlotsAndReadData
PAUSE 2000
STORE 0 'Switch to READ/WRITE slot 0
GOSUB DisplaySlotsAndReadData
PAUSE 2000
RUN 2 'Switch to program 2
' --------------------------- Subroutines ---------------------------
DisplaySlotsAndReadData:
GET 127, Value
DEBUG CR, "Prog Slot: ", DEC1 Value.LOWNIB
DEBUG " R/W Slot: ", DEC1 Value.HIGHNIB, CR, CR
FOR Idx = 0 TO 4
READ Idx, Value
DEBUG "Location: ", DEC Idx, " Value: ", DEC3 Value, CR
NEXT
RETURN
p
2
Summary of Contents for BASIC Stamp 1
Page 1: ...BASIC Stamp Programming Manual Version 2 0c...
Page 34: ...Quick Start Guide Page 32 BASIC Stamp Programming Manual 2 0b www parallaxinc com...
Page 340: ...ASCII Chart Page 338 BASIC Stamp Programming Manual 2 0b www parallaxinc com...
Page 342: ...Reserved Words Page 340 BASIC Stamp Programming Manual 2 0b www parallaxinc com...
Page 346: ...Conversion Formatters Page 344 BASIC Stamp Programming Manual 2 0b www parallaxinc com...