Chapter 10 CANopen Function and Operation 10.4 Sending SDO, NMT and Reading Emergency Message through the Ladder Diagram You can edit the request message mapping area to affect the transmission of SDO, NMT and Emergency area, response message mapping area, and PLC device. messages. The following table shows the corresponding relations between the request message mapping The CANopen master can only send one SDO, NMT, or Emergency request message to the same device at a time. Clear the request message mapping area to zero when sending SDO, NMT, or Emergency request message through the WPL program.
10.4.1 Data Structure of SDO Request Message Sending SDO through the ladder diagram reads or writes the slave parameter. 1. The data format of the SDO request message: ReqID: the request ID. Whenever an SDO request message is sent out, the message is given a ReqID for CANopen master to identify. When reading/writing another SDO message, the original ID number must be changed. In other words, reading/writing SDO is triggered by changing of the value of “ReqID”. The ReqID range is between 00–FF (Hex). Size: the length of the message data. The counting starts from D6253 with a byte as the unit.
When reading, it is fixed to four and when writing, it is four plus the byte number of data types of index and subindex and the maximum value is eight. But when writing, if the data type of the index and subindex is word, the data length is six. The data length is file if the data type is byte. Node ID: the node address for the target equipment on a CANopen network. Type: 01 indicates the read access; 02 indicates the write access. The following table shows the data format of the SDO response message.
10 10-19 PLC device Mapping area Mapping length D25000-D25031 SDO request message, NMT service message and Emergency request message 64 bytes D24000-D24031 SDO response message and Emergency response message 64 bytes Request message PLC device High byte Low byte D25000 Message Header ReqID Command (Fixed to 01) D25001 Reserved Size D25002 Type Node ID D25003 Message Data High byte of main index Low byte of main index D25004 Reserved Sub-index D25005 Datum 1 Datum 0 D25006 Datum 3 Datum 2 D25007 - D25031 Reserved PLC device Response message High byte Low byte D24000 Message Header ResID Status code D24001 Reserved Size D24002 Type Node ID D24003 Message Data High byte of main index Low byte of main index