EasyManuals Logo

Xinje XD Series User Manual

Xinje XD Series
456 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #257 background imageLoading...
Page #257 background image
256
(1) Take 06H function code as example (single register write), and introduce data format.
E.g.: upper computer write data to PLC H0002 (D2).
RTU mode:
Asking format
Response format
ID
01H
ID
01H
Function code
06H
Function code
06H
Register ID
00H
Register ID
00H
02H
02H
Data content
13H
Data contents
13H
88H
88H
CRC CHECK High
25H
CRC CHECK High
25H
CRC CHECK Low
5CH
CRC CHECK Low
5CH
Explanation
1. Address is PLC station no.
2. Function code is Modbus-RTU protocol read/write code.
3. Register address is the PLC modbus address, please see chapter 6-2-3.
4. Data content is the value in D2.
5. CRC CHECK High / CRC CHECK Low is high and low bit of CRC check value.
If 2 pieces of Xinje XD3 series PLC communicate with the other one, write K5000 to D2.
M 0
R E G W K 1 H 0 0 0 2 K 5 0 0 0 K 2
M0 is trigger condition (Rising edge). If communication fails, the instruction will try twice. If
the third time communication fails, then communication ends.
The relationship between REGW and Modbus RTU protocol (other instructions are the same)
REGW
Function code 06H
K1
Station no.
H0002
Modbus address
K5000
Data contents 1388H
K2
PLC serial port
The complete communication datum are: 01H 06H 00H 02H 13H 88H (system take CRC
checking automatically)
If monitor the serial port2 data by serial port debugging tool, the datum are: 01 06 00 02 13
88 25 5C
Note: The instruction doesn’t distinguish decimal, hex, binary, octal etc. For example,
B10000, K16 and H10 are the same value, so the following instructions are the same.
REGW K1 B111110100 D1 K2
REGW K1 K500 D1 K2
REGW K1 H1F4 D1 K2
(2) Function code 01H/02H: read coil/read input coil
Eg. Read coil address 6000H (Y0). At this time, Y0 and Y1 are ON.
RTU mode:
Asking format
Response format
Address
01H
Address
01H
tudonghoatoancau.com

Table of Contents

Other manuals for Xinje XD Series

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the Xinje XD Series and is the answer not in the manual?

Xinje XD Series Specifications

General IconGeneral
Input Voltage24V DC
Storage Temperature-20°C to 70°C
Protection ClassIP20
TypePLC
SeriesXD
Programming LanguageLadder Logic, Instruction List
Communication InterfaceRS232, RS485
Power Supply24V DC
Digital InputsAvailable (number varies by model)
Digital OutputsAvailable (number varies by model)
Analog InputsAvailable (number varies by model)
Analog OutputsAvailable (number varies by model)
Output TypeRelay, Transistor
Number of InputsVaries by model (see Digital Inputs and Analog Inputs)
Number of OutputsVaries by model (see Digital Outputs and Analog Outputs)
Operating Temperature0°C to 50°C
Humidity5% to 95% (non-condensing)