EasyManua.ls Logo

FATEK FBs-CB5 - Page 179

FATEK FBs-CB5
348 pages
Print Icon
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
Advanced Function Instruction
7-15
FUN 40 D P
BITRD
BIT READ
FUN 40 D P
BITRD
S : Source data to be read
N : The bit number of the S data to be read out.
S, N may combine with V, Z, P0~P9 to serve
indirect address application
WX WY WM WS TMR CTR HR IR OR SR ROR DR K XRRange
Ope-
rand
WX0
∣
WX240
WY0
∣
WY240
WM0
∣
WM1896
WS0
∣
WS984
T0
∣
T255
C0
∣
C255
R0
∣
R3839
R3840
∣
R3903
R3904
∣
R3967
R3968
∣
R4167
R5000
∣
R8071
D0
∣
D4095
16/32-bit
+/- number
V、Z
P0~P9
S ○ ○ ○ ○ ○ ○ ○ ○ ○ ○ ○ ○ ○ ○
N ○ ○ ○ ○ ○ ○ ○ ○ ○ ○ ○ ○ 0~31 ○
z When read control "EN" = 1 or "EN↑" ( P instruction) changes from 0 to 1, take the Nth bit of the S data
out , and put it to the output bit "OTB".
z When read control "EN" = 0 or "EN↑" ( P instruction) is not change from 0 to 1, The output “OTB” can be
selected to keep at the last state( if M1919=0 ) or set to zero ( if M1919=1 ).
z When the operand is 16 bit, the effective range for N is 0~15. For 32 bit operand ( D instruction) it is 0~31.
N beyond this range will set the N value error flag "ERR" to 1, and do not carry out this instruction.
X0
S :
Y0
EN
40P.BITRD
N :
7
WX 0
OTB
ERR
z The instruction at left reads the 7th bit (X7) status from
WX0 (X0~X15) and output to Y0. The results are as
follows:
X15 X7 X0
S WX0 1 10011101001100 1
N=7──────────
Ø
X0=
Y0
1