How does the CANOpen protocol guarantee that communication does not drop frames?

How to make fieldbus communication more stable and reliable, and not to lose, has always been a problem that engineers are difficult to solve. This article will use the international standard communication protocol to show how to build a handshake communication.

Service data object (SDO)

SDO is mainly used for parameter configuration of CANopen master to slave nodes. Service acknowledgment is the biggest feature of SDO, generating a response for each message to ensure the accuracy of data transmission. As shown in Figure 1, this is like a courier. After receiving the receipt, the sender will send a confirmed receipt to the sender to complete the delivery.

How does the CANOpen protocol guarantee that communication does not drop frames?

Figure 1 SDO and express delivery

In a CANopen system, the CANopen slave node is usually the SDO server and the CANopen master node is the client (called CS communication). The SDO client can access the object dictionary on the SDO server through indexes and sub-indexes. In this way, the CANopen master node can access the parameters of any object dictionary entries of the slave node, and the SDO can also transmit data of any length (divided into multiple messages for transmission when the data length exceeds 4 bytes).

Communication principle (communicaTIon principle)

The communication principle of SDO is very simple. The sender (client) sends a message with a CAN-ID of 600h+Node-ID, where the Node-ID is the node address of the receiver (server), and the data length is 8 bytes.

After the receiver (server) successfully receives, it responds with a message with a CAN-ID of 580h+Node-ID. The Node-ID here is still the node address of the receiver (server), and the data length is 8 bytes. as shown in picture 2.

How does the CANOpen protocol guarantee that communication does not drop frames?

Figure 2 SDO communication principle

Fast SDO protocol (Expedited SDO protocol)

The most common SDO protocol most commonly used is fast SDO. The so-called fast is that it is done once and for all. The premise is that the value read and written cannot be greater than 32 bits. As shown in Figure 3, it is a schematic diagram of the fast SDO protocol. The command directly contains the index, subindex, and data to be read and written. Can be described as a direct hit.

The difficulty of fast SDO lies in the memory of the CS command character, which requires the reader to collect this schematic.

How does the CANOpen protocol guarantee that communication does not drop frames?

Figure 3 Fast SDO schematic

With the fast SDO, the values ​​in the object dictionary of the CANopen node can be directly read and modified, so in addition to the parameter configuration, it is often used as a key data transmission. For example, when CANopen controls the motor's motor rotation angle, it uses SDO to transmit, ensuring reliable arrival.

Normal SDO protocol (Normal SDO protocol)

Fast SDO transmissions cannot be used when the value to be transmitted exceeds 32 bits. A normal SDO must be used for framing transmission. It is rarely used in applications, generally used for program firmware upgrade of CANopen nodes, or as a gateway conversion MVB bus and other data up to 256-bit applications.

The difficulty of the ordinary SDO protocol lies in the change of the packetization logic and the CS command character. Still difficult to remember, the reader needs to collect the following schematics.

Of course, the CAN frame ID of the normal SDO is the same as that of the fast SDO, and the CAN-ID of the message sent by the sender (client) is 600h+Node-ID. After the receiver (server) successfully receives the response, the CAN-ID is 580h+Node. -ID message.

The download protocol download protocol is shown in Figure 4.

How does the CANOpen protocol guarantee that communication does not drop frames?

Figure 4 Common SDO Download Protocol

Upload protocol upload protocol as shown in Figure 5.

How does the CANOpen protocol guarantee that communication does not drop frames?

Figure 5 Ordinary SDO upload protocol

Gas Generator

Gas Generator,4 Cycle 16 Cylinders,4 Cycle 16 Cylinders Cummins Generators,4 Cycle 16 Cylinders Generators

XCMG E-Commerce Inc. , https://www.xcmg-generator.com

This entry was posted in on