Lakeshore 330 User Manual page 66

Autotuning temperature controller
Table of Contents

Advertisement

Lake Shore Model 330 Autotuning Temperature Controller User's Manual
'************************************************************************
'*
'*
This routine will load a curve. Get here by entering "CURVE" above. *
'*
NOTE: SPACING OF THE DATA STRING IS VERY CRITICAL.
'*
For this example the string data must be on a single line
'*
of an ASCII file using the same format as the attached sample.*
'************************************************************************
LOAD: CURVE$ = SPACE$(2000)
DELAY = 2000
PRINT
PRINT "DOWN LOAD A CURVE"
PRINT
INPUT "ENTER DRIVE AND FILE NAME: "; FILE$
OPEN FILE$ FOR INPUT AS #2
LINE INPUT #2, CURVE$
CLOSE #2
PRINT
'Get curve number from KB
INPUT "ENTER DESTINATION CURVE NUMBER (11 to 31): "; CURNUM$
IF MID$(CURVE$, 1, 1) = "X" THEN
CURVE$ = MID$(CURVE$, 5)
CURVE$ = "CURV" + CURNUM$ + CURVE$ 'Add 300 series file header
ELSE
CURVE$ = "CURV" + CURNUM$ + "," + CURVE$
END IF
PRINT
PRINT "COMMANDS SENT TO 320"
PRINT
CMD$ = LEFT$(CURVE$, 53)
PRINT CMD$
CMD$ = CMD$ + TERM$
PRINT #1, CMD$
FOR Z = 1 TO DELAY: NEXT Z
CHRCOUNT = 54
POINTCOUNT = 3
WHILE LEN(CURVE$) >= CHRCOUNT + 14
CMD$ = MID$(CURVE$, CHRCOUNT, 14) 'Take out next point
CHRCOUNT = CHRCOUNT + 14
PRINT POINTCOUNT, SPACE$(11); CMD$ 'Send next point to screen
POINTCOUNT = POINTCOUNT + 1
CMD$ = "ECUR " + CURNUM$ + CMD$ + TERM$ 'Build next command
PRINT #1, CMD$
FOR I = 1 TO DELAY: NEXT I
WEND
PRINT
PRINT "ENTER CURV?" + CURNUM$ + " TO RETURN CURVE FROM INSTRUMENT"
PRINT
GOTO LOOP1
4-24
CURVE LOADING PROGRAM
'Preset variable lengths
'Delay timer
'Open ASCII disk file
'Read disk file into string
'Close disk file
'Test for DRC curve format
'Strip off DRC file header
'Screen prints to show what is sent
'Pick out header and first two points
'Send first command string to screen
'Add terminators
'Send curve create cmd to 321/320/330
'Delay
'Character count for next curve point
'Curve data point counter
'Check for end of string
'Advance count to next point
'Send to instrument
'Delay
'Curve load complete
*
*
*
'Get file name from KB
'Add file header
Remote Operation

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents