You are on page 1of 38

C2

CÁC LỆNH LOGIC BIT

TS NGUYỄN ĐỨC THÀNH 1


QUI ĐỊNH ĐỊA CHỈ

TS NGUYỄN ĐỨC THÀNH 2


QUI ĐỊNH ĐỊA CHỈ

TS NGUYỄN ĐỨC THÀNH 3


QUI ĐỊNH ĐỊA CHỈ

TS NGUYỄN ĐỨC THÀNH 4


QUI ĐỊNH ĐỊA CHỈ

TS NGUYỄN ĐỨC THÀNH 5


LAD BIT LOGIC S7-300/400

TS NGUYỄN ĐỨC THÀNH 6


STL BIT LOGIC S7-300/400

TS NGUYỄN ĐỨC THÀNH 7


STATUS WORD

TS NGUYỄN ĐỨC THÀNH 8


STATUS WORD

TS NGUYỄN ĐỨC THÀNH 9


STATUS WORD

TS NGUYỄN ĐỨC THÀNH 10


ĐỌC BIT

TS NGUYỄN ĐỨC THÀNH 11


AND OR

TS NGUYỄN ĐỨC THÀNH 12


Exclusive OR (XOR)

TS NGUYỄN ĐỨC THÀNH 13


SET RESET

TS NGUYỄN ĐỨC THÀNH 14


SET RESET FLIPFLOP

TS NGUYỄN ĐỨC THÀNH 15


NOT, MIDLINE OUTPUT (STEP7 S7-
300/400)

TS NGUYỄN ĐỨC THÀNH 16


EDGE DETECT STEP7 (S7-300/S7-400)

TS NGUYỄN ĐỨC THÀNH 17


POSITIVE EDGE DETECT TIA PORTAL
(S7-300/400)
• You can use the "Scan operand for positive signal edge"
instruction to determine if there is a "0" to "1" change in
the signal state of a specified operand (<Operand1>). The
instruction compares the current signal state of
<Operand1> with the signal state of the previous scan that
is saved in an edge memory bit (<Operand2>). If the
instruction detects a change in the result of logic operation
(RLO) from "0" to "1", there is a positive, rising edge.
• If a positive edge is detected, the output of the instruction
has the signal state "1". In all other cases, the signal state at
the output of the instruction is "0".
• Specify the operand to be queried (<Operand1>) in the
operand placeholder above the instruction. Specify the
edge memory bit (<Operand2>) in the operand placeholder
below the instruction.
TS NGUYỄN ĐỨC THÀNH 18
POSITIVE EDGE DETECT TIA PORTAL
(S7-300/400)

TS NGUYỄN ĐỨC THÀNH 19


NEGATIVE EDGE DETECT TIA PORTAL
(S7-300/400)
• You can use the "Scan operand for negative signal edge" instruction
to determine if there is a "1" to "0" change in the signal state of a
specified operand (<Operand1>). The instruction compares the
current signal state of <Operand1> with the signal state of the
previous scan that is saved in an edge memory bit <Operand2>. If
the instruction detects a change in the result of logic operation
(RLO) from "1" to "0", there is a negative, falling edge.
• If a negative signal edge is detected, the output of the instruction
has the signal state "1". In all other cases, the signal state at the
output of the instruction is "0".
• Specify the operand to be queried (<Operand1>) in the operand
placeholder above the instruction. Specify the edge memory bit
(<Operand2>) in the operand placeholder below the instruction

TS NGUYỄN ĐỨC THÀNH 20


NEGATIVE EDGE DETECT TIA PORTAL

TS NGUYỄN ĐỨC THÀNH 21


P_TRIG TIA PORTAL

TS NGUYỄN ĐỨC THÀNH 22


N_TRIG TIA PORTAL

TS NGUYỄN ĐỨC THÀNH 23


A(: AND logic operation with branch
S7-300/400

TS NGUYỄN ĐỨC THÀNH 24


AN(: Negated AND logic operation with
branch S7-300/400

TS NGUYỄN ĐỨC THÀNH 25


): Close branch
S7-300/400

TS NGUYỄN ĐỨC THÀNH 26


O(: OR logic operation with branch
S7-300/400

TS NGUYỄN ĐỨC THÀNH 27


O(: OR logic operation with branch
S7-300/400

TS NGUYỄN ĐỨC THÀNH 28


ON(: Negated OR logic operation with
branch
S7-300/400

TS NGUYỄN ĐỨC THÀNH 29


ON(: Negated OR logic operation with
branch S7-300/400

TS NGUYỄN ĐỨC THÀNH 30


SET: Set RLO to 1
CLR: Reset RLO to 0
S7-300/400

TS NGUYỄN ĐỨC THÀNH 31


LAD BIT LOGIC S7-1200/1500

TS NGUYỄN ĐỨC THÀNH 32


SET_BF SET BIT FIELD, RESET_BF

TS NGUYỄN ĐỨC THÀNH 33


TS NGUYỄN ĐỨC THÀNH 34
TS NGUYỄN ĐỨC THÀNH 35
TS NGUYỄN ĐỨC THÀNH 36
TS NGUYỄN ĐỨC THÀNH 37
TS NGUYỄN ĐỨC THÀNH 38

You might also like