LumaSense Technologies M340 User Manual
Page 22
Advertising

M340 Manual
Appendix A: PC Communications sample 22
NEXT y
'-------get blackbody temperature readings
PRINT #1, reading$ ' send get reading command string to controller
INPUT #1, getread$ ' ignore first controller response (echo)
INPUT #1, getread$ ' grab controller temperature response
pv = VAL(RIGHT$(getread$, readlen)) 'convert ascii string to a number
'-------display the process variable (blackbody temperature)
LOCATE 7, 15
COLOR 4 + 8
PRINT pv
'-------escape loop to end program
mg$ = INKEY$
IF mg$ = " " THEN CLOSE : END
'--------wait some time
FOR z = 0 TO 200000
NEXT z
NEXT sp 'go to the next setpoint value and repeat
'----------done
LOCATE 23, 5
PRINT "TEST IS COMPLETE. "
Advertising