Datasheet

Jon Waddington
92
'rc.flush
e := in.newkey
if e <> $0D
text.out(e)
name[i] := e
i++
in.stop
PRI rcname_in(i) | j, t, x
code := 0
t := i
repeat j from i to i+9
name[j]~
i := t
text.out($00)
showdate(0, 0)
showtime(35, 0)
text.str(string(13," Add Device (Remote)",13,13," Name: "))
x := 12
repeat until ((code == enter) OR (i == t+9))
code := wait
if (code =< 9)
text.xy(x, 4)
text.dec(code)
name[i] := code + 48
i++
x++
PRI room_in(j)
text.out($00)
showdate(0, 0)
showtime(35, 0)
text.str(string(13," Add Device",13,13," Room: > Bedroom",13," Living Room",13,"
Dining Room",13," Kitchen"))
code := 0
sel := room[j]
repeat until ((code == enter))
case sel
0 : text.str(string($0A,13,$0B,4,"> "))
text.str(string($0A,13,$0B,5," "))
text.str(string($0A,13,$0B,6," "))
text.str(string($0A,13,$0B,7," "))
room[j] := sel
1 : text.str(string($0A,13,$0B,4," "))
text.str(string($0A,13,$0B,5,"> "))
text.str(string($0A,13,$0B,6," "))
text.str(string($0A,13,$0B,7," "))
room[j] := sel
2 : text.str(string($0A,13,$0B,4," "))
text.str(string($0A,13,$0B,5," "))
text.str(string($0A,13,$0B,6,"> "))
text.str(string($0A,13,$0B,7," "))
room[j] := sel
3 : text.str(string($0A,13,$0B,4," "))
text.str(string($0A,13,$0B,5," "))