Multifunction Module with DIO, D/A, and Totalizer 10
34980A User’s Guide 199
34952A SCPI Programming Examples
The programming examples below provide you with SCPI command
examples to use for actions specific to the general purpose switch modules.
The slot and channel addressing scheme used in these examples follow the
form sccc where s is the mainframe slot number (1 through 8) and ccc is the
channel number. For information on specific configurations, refer to the
simplified schematic on page 201.
For complete information on the SCPI commands used to program the
34980A, refer to the Agilent 34980A Programmer’s Reference contained on
the 34980A Product Reference CD. For example programs, also refer to the
34980A Product Reference CD.
Digital Input/Output
Example: Configuring a DIO channel The following program segment
configures channel 1 on the DAC module in slot 3 as an output and then
reads the output value (the channel is not reconfigured as an input). Then,
the channel is reconfigured as an input and the value is read again.
The second command below returns 64 as it is physically
reading the output data.
SOURce:DIGital:DATA:BYTE 64,(@3001)
SENSe:DIGital:DATA:BIT? 0,(@3001)
The second command below returns whatever is being input
externally.
CONFigure:DIGital:STATe INPut,(@3001)
SENSe:DIGital:DATA:BIT? 0,(@3001)
Totalizer
Example: Reading totalizer channel count The following command reads the
count on totalizer channel 5 on the Multifunction module in slot 3.
SENSe:TOTalize:DATA? (@3005)
Example: Configuring the totalizer reset mode To configure the totalizer reset
mode, send either of the following commands.
The following command configures totalizer channel 5 on the Multifunction
module in slot 3 to be read without resetting its count.
SENSe:TOTalize:TYPE READ,(@3005)