Chapter 8
SCPI
SCPI and RAPID!
4460 GSM System Option and 4468 EDGE System Option
Version 12.20
341
‘Setting the mask for the program’s service register: rising an event on an entry
’ of a message. Bits to set: event (bit 6 = 64) and program.message (bit 0 = 1)
PRINT #0,”:PROG:SRE 65”
DO
‘ Read out programm message queue
PRINT #0,”:PROG:MESS?”
INPUT #0,message$
‘Check message string for key letters
result$ = MID$(message$,1,2)
SELECT CASE result$
CASE “TX”
result$ = DoTXAlign(Message$)
CASE “RX”
result$ = DoRXAlign(Message$)
CASE “SP”
result$ = DoSPAlign(Message$)
CASE “AN”
result$ = DoAFANAlign(Message$)
CASE ELSE
result$=””
END SELECT
IF result$=”” THEN PRINT #0,”:SYST:MESS “;result$
LOOP
Example of a GPIB protocol
to/
from
4400
Data
Comment
to
:PROG:NAME MSG-
DEMO.RBS
Load program
to
:PROG:STAT RUN
Start program on 4400
to
:PROG:MESS
”TX, 1, 62, 124,
–105”
Start (user-programmed) TX cali-
bration process on 4400
from
SRQ
4400 raises service request after
calibration
to
serial poll
Controller identifies SRQ device
from
SYST:MESS?
Controller queries system message
to
“TX Calibration
OK”
4400 confirms successful TX cali-
bration
from
:PROG:MESS
”RX, 1, 62, 124,
15”
Start (user-programmed) RX cali-
bration process on 4400