aitest.tmb for the IC51 Shows how to test the value of an analog input. Exit if key pressed. ------------------------------- NEW 1 A=KEY 2 IF A<>0 100 --- select input #1 3 SELAI 1 --- read the input 10 READAI --- convert value to voltage 11 BAVOLTS --- display voltage 15 PRINT A 16 PRINT "." 17 PRINT B 18 PRINT C 19 PRINT D --- value to test for in A and B 20 BA=1000 --- read input/test for setpoint 21 IF AI= setpoint 22 PRINT "*" --- NEW LINE 30 PRINT 13 31 PRINT 10 --- WAIT A BIT 32 DELAY 1 --- REPEAT 33 GOTO 1