26
:BYTE <NDN or NRf>, <clist>
Set digital output byte patterns
:BYTE? <clist>
Query output byte patterns
Use to set (or query) an 8-bit digital output byte pattern for the specified I/O channel(s). Channels 11, 12, 13, and 14 can be set
as 8-bit output patterns.
NOTE
Only channels 11, 12, 13, and 14 are valid with the :BYTE command. Using any other channel
number(s) with the command generates error -221 (settings conflict).
The value to set the 8-bit output pattern can be sent in the decimal, binary, hexadecimal, or octal format.
Example: Set output bit pattern “100101” for channel 13 (Bits B5, B2 and B0 set high):
OUTP:DIG:STAT 1,(112)
' Set channel 12 as output port.
OUTP:DIG:BYTE #B100101,(@121)
' Set pattern; binary format.
In order to use one of the other formats, convert the binary value to its hexadecimal, octal, or decimal equivalent and send the
command as follows:
OUTP:DIG:BYTE #H25,(@121)
' Set pattern; hexadecimal format.
OUTP:DIG:BYTE #Q45,(@121)
' Set pattern; octal format.
OUTP:DIG:BYTE 37,(@121)
' Set pattern; decimal format.
:BYTE? command — For non-decimal formats, one of the following headers will accompany the returned value to identify
which format is selected:
#B = Header for binary values
#H = Header for hexadecimal values
#Q = Header for octal values
The :FORMat command is used to select the format for returned values.
:WORD <NDN or NRf>, <clist>
Set digital output word patterns
:WORD? <clist>
Query output word patterns
Use to set (or query) a 16-bit digital output word pattern. Channels 11 and 12 are combined to form one 16-bit pattern, and
channels 13 and 14 are combined to form a second 16-bit pattern.
NOTE
Only channels 11 and 13 are valid with the :WORD command. Using any other channel number(s)
with the command generates error -221 (settings conflict).
When you write a word output pattern to channel 11, the bits for both channels 11 and 12 will set. As shown in
,
channel 11 is used for bits B0 through B7, and channel 12 is used for bits B8 through B15. In a similar manner, when you write
a word output pattern to channel 13, the bits of channels 13 and 14 will set.
NOTE
When setting a word bit pattern, both channels (11 and 12, or 13 and 14) must be configured as
output ports. Otherwise, error -221 (settings conflict) will occur when the :WORD command is
sent.
The value to set the 16-bit output pattern can be sent in the decimal, binary, hexadecimal, or octal format.
Example: Write 16-bit output bit pattern “00000001 00000111” to channel 11 (Bits B8, B2, B1 and B0 set high):
OUTP:DIG:STAT 1,(111,112)
' Set I/O channels 11 and 12 as outputs ports.
OUTP:DIG:WORD #B100000111,(@111)
' Set pattern; binary format.
Notice that leading zeroes for the binary word need not be included in the command.
Содержание 7707
Страница 55: ...52 Specifications 7707 Multiplexer Digital I O Module...
Страница 58: ......