Agilent Technologies Serials 2934A-01825 to 01829 3023A-01925 Video Gaming Accessories User Manual


 
Programming the Agilent 603xA Power Supplies Using Basic
124
80 SUB Err_trap
90 OFF KEY
100 COM /Ps/ @Ps
110 OUTPUT @Ps:”ERR?”
120 ENTER@Ps;Err
130 OUTPUT 2 USING "#.k":CHR$;(255)&CHR$(75)
140 IF Err THEN
150 PRINT “ POWER SUPPLY PROGRAMMING ERROR:”
160 END IF
170 SELECT Err
180 CASE 0
190 PRINT "NO ERROR HAS OCCURRED”
200 SUBEXIT
210 CASE 1
220 PRINT 'CHARACTER NOT RECOGNIZED”
230 CASE 2
240 PRINT “IMPROPER NUMBER”
250 CASE 3
260 PRINT “UNRECOGNIZED ALPHA CHARACTER”
270 CASE 4
280 PRINT “SYNTAX ERROR”
290 CASE 5
300 PRINT “NUMBER OUT OF RANGE”
310 CASE 6
320 PRINT “ATTEMPT TO PROGRAM ABOVE SOFT LIMIT”
330 CASE 7
340 PRINT “LIMIT CANNOT BE SET < OPERATING POINT”
350 CASE 8
360 PRINT “DATA REQUESTED W/O QUERY”
370 END SELECT
380 PRINT “ RE-ENTER STATEMENT AND TRY AGAIN”
390 SUBEND
Explanation:
10: Assign I/O path name to power supply
20: Declare common block for I/O path name
30: Define interrupt on softkey depression branch to error routine
40: Idle on softkey definition
80: Define subprogram ERR TRAP
100: Bring in common block for I/O path name
110-120: Enter error code from power supply
130: Clear computer CRT
140-150: If an error occurred, print message
170-420: Print out message based on error code returned from power supply. If no error, print
message saying no error occurred.