
6-13
6 No-protocol Mode
CJ-series Serial Communications Units Operation Manual for NJ-series CPU Unit(W494)
6-
3 Usin
g Serial P
o
rt
I/O Ins
truct
ion
s
6
6-3-2 Instr
u
ction Ex
ecution Metho
ds
The default settings are Baud Rate: 9,600 bps, Start Bits: 1 bit, Data Length: 7 bits, Parity: Even parity
and Stop Bits: 2 bits.
z
Send Data Setting
Break the character string '@READ' into individual characters and store the character codes as array
elements in SendDat[].
In other words, BYTE#16#40(@) is stored in SendDat[0] and BYTE#16#52(R) in SendDat[1]. This pro-
cessing uses the StringToAry instruction.
z
LD
System-defined variable
User-defined variables (To be defined before or when creating a program)
Device variables for CJ-series Unit (To be created on the I/O Map View
window after the unit configuration is created)
Name
Data
type
Factory
setting
Comments
Details
_Port_isAvailable
BOOL
---
Network Communications
Instruction Enabled Flag
This flag is TRUE when there
are internal logical ports
available, FALSE when there
is no internal logical port
available.
Name
Data type
Factory setting
Allo-
cated
address
(AT)
Details
OperatingEnd
BOOL
False
---
Process completed
Trigger
BOOL
False
---
Execution conditions
Operating
BOOL
False
---
Processing
InPort
_sPORT
(UnitNo:=_CBU_No0
0, PhysicPortNo:=0)
---
Port specification
SendDat
ARRAY[0..4] OF
BYTE
[5(16#0)]
---
Send data
RS_instance
RS
---
---
---
SerialSend_instance
SerialSend
---
---
---
Name
Data
type
Factory
setting
Allocated address
(AT)
Comments
Details
Barcode_P2_NopS
erialSendExecSta
BOOL
---
IOBus://rack#0/slot#
0/P2_NopSta/P2_N
opSerialSendExec-
Sta
Port 2:
SerialSend Execut-
ing Flag
This flag is TRUE
while execution of
the instruction is in
progress.
BYTE data type array
SendDat[0]
BYTE#16#40
STRING data type
StringToAry
SendDat[1]
BYTE#16#52
'@READ'
SendDat[2]
BYTE#16#45
SendDat[3]
BYTE#16#41
SendDat[4]
BYTE#16#44
Содержание CJ1W-SCU22
Страница 192: ...4 Using Protocol Macros 4 56 CJ series Serial Communications Units Operation Manual for NJ series CPU Unit W494...
Страница 250: ...6 No protocol Mode 6 22 CJ series Serial Communications Units Operation Manual for NJ series CPU Unit W494...
Страница 460: ...A Standard System Protocol R 126 CJ series Serial Communications Units Operation Manual for NJ series CPU Unit W494...
Страница 473: ...Index 1 CJ series Serial Communications Units Operation Manual for NJ series CPU Unit W494 I Index...