-
Notifications
You must be signed in to change notification settings - Fork 2
Structure of Ethernet Frame
- Transport Layer : UDP/IP, TCP/IP
- Half-Duplex (UDP/IP, TCP/IP)
- Service Port : 10262(UDP/IP), 10260(TCP/IP) To use this service, which uses the protocol built in the module of the CIMON PLC, TCP port 10260 and UDP port 10262 are to be used. This service is used to download and upload a PLC program, and to control a PLC. And it is used to read the information and the data in a PLC from a PC and other devices, and to write the information and the data in a PLC to a PC and other devices. Though the exclusive service, the communication between a PC and an Ethernet module is available.
| ID | Frame No. | Cmd | Res. | Length | Data | Check Sum |
|---|---|---|---|---|---|---|
| 9 Bytes | 1 Byte | 1 Byte | 1 Byte | 2 Bytes | 1456 Bytes | 2 Bytes |
| Item | Size (Byte) | Description |
|---|---|---|
| ID | 9 | Company ID string “ KDT_PLC_M ”. |
| Frame No. | 1 | Frame Number |
| Cmd | 1 | Command based on following table |
| Res. | 1 | Reserved Device |
| Length | 2 | Length of Data Field |
| Data | 1456 | Data Device |
| Check Sum | 2 | Accuracy Check of Data |
This is a 9-byte string like “ KDT_PLC_M ”.
This, 1-byte data with the range from 0 to 127, is the number of the frame controlled by Master party. The start of this number can be any one within the range. But, when a new frame is sent, the number should be the value that ‘1’ is increased to the number given to the previous frame. If the frame of the same number is received in Slave party in the state that the response frame to the previous frame is not sent, the frame will be disregarded. If the response frame to the previous frame is sent and the frame of the same number is received, Slave party will respond normally.
In Master, 1-byte command as the following table can be used and the format of ‘Data’ field is selected according to each command.
| Cmd Code | Function | Remarks |
|---|---|---|
| 0x52 | Word Block Read | Reads data by the word. |
| 0x57 | Word Block Write | Writes data by the word. |
| 0x72 | Bit Block Read | Reads data by the bit. |
| 0x77 | Bit Block Write | Writes data by the bit. |
Reserved. (1 Byte, 0x00) – Reserved device
This is the 2-byte value indicating the size of ‘Data’ field. (Hexadecimal Figure)
This is used to check the accuracy of data. After the data are received one by one and are summed, they are compared with the last coming checksum to check whether an error occurs. This is 2-byte value. After the entire frame is binary-summed by the byte, the lower 2-byte in the result value is used.
| ID | Frame No. | Cmd | Res. | Length | Data | Check Sum |
|---|---|---|---|---|---|---|
| 9 Bytes | 1 Byte | 1 Byte | 1 Byte | 2 Bytes | 1456 Bytes | 2 Bytes |
This is a 9-byte string like “ KDT_PLC_S ”.
This is 1-byte data. The value that 128 are added to the number of the command frame received from the Master is used. As the Master receiving response frame expects the number of the response frame from the frame number used to command frame, it can be checked whether a frame is normal, using this Frame No
In Slave, 1-byte command as the following table can be used and the format of ‘Data’ field is selected according to each command.
| Cmd Code | Function | Remarks |
|---|---|---|
| 0x52 | Word Block Data | |
| 0x72 | Bit Block Data | |
| 0x41 | ACK Response |
Reserved. (1 Byte, 0x00) – Reserved Device
This is the 2-byte value indicating the size of ‘Data’ field. (Hexadecimal Figure)
This is used to check the accuracy of data. After data are received one by one and are summed, they are compared with the last coming check-sum to check whether an error occurs. This is 2-byte value. After the entire frame is binary-summed by the byte, the lower 2-byte in the result value is used.