11 - 7 11 - 7
MELSEC-Q
11 INSTRUCTIONS AND FUNCTIONS
B@
Variable
Bit@
• Reads and writes bit information of the expansion relay (EM), general-purpose input (X),
and general-purpose output (Y).
B@ ( <device> , <device number> )
device
• • • •
Specify the device to read and write.
Syntax
device number
• • • •
Specify the device number to read and write.
A%=B@ (EM, 100)
• • • •
Reads the bit information of the expansion relay
EM100 to A%.
A%=B@ (Y, &H1B)
• • • •
Reads the bit information of the general-purpose
output Y001B to A%.
B@ (EM, 200) =A%
• • • •
Write the bit information to the expansion relay
EM200.
Examples
B@ (X, &HA) = A%
• • • •
Write the bit information to the general-purpose input
X000A.
Description
• The B@ variable reads and writes the bit information of the device.
• Specify one of the following devices for <device>:
Expansion relay • • • • EM
General-purpose input • • • • X
General-purpose output • • • • Y
• Specify the following device number for <device number>:
EM • • • • 0 to 1023
X, Y • • • • &H0 to &H1F
• The read data is 1 when ON and 0 when OFF.
• For the write data, bit 0 of the specified value or of the value that is stored in the specified
variable is valid.
b15
b8b7
b0
to
to
The corresponding device
is turned ON when "1."
The corresponding device
is turned OFF when "0."
• Set the data by an integer constant or an integer variable when writing.
• Only write operation can be used when general-purpose input X is specified.
• Only read operation can be used when general-purpose output Y is specified.
REMARK
See the W@ function.
Содержание A1SD51S
Страница 183: ...11 13 11 13 MELSEC Q 11 INSTRUCTIONS AND FUNCTIONS RUN Before swap A 0 H924 A 1 H1159 After swap A 0 H1159 A 1 H924 OK...
Страница 331: ...11 161 11 161 MELSEC Q 11 INSTRUCTIONS AND FUNCTIONS REMARK See the CON ON OFF STOP and ZOPEN functions and Section 7 4...
Страница 557: ...11 387 11 387 MELSEC Q 11 INSTRUCTIONS AND FUNCTIONS REMARK See the CHR SPACE and SPC functions...
Страница 629: ...11 459 11 459 MELSEC Q 11 INSTRUCTIONS AND FUNCTIONS REMARK See the ZOPEN ZSEND and ZCNTL instructions and Section 7 3 4...
Страница 645: ...11 475 11 475 MELSEC Q 11 INSTRUCTIONS AND FUNCTIONS REMARK See the ZEVENT ZSIGNAL and DEF ZEVENT instructions...