IL•1F CANopen DS301 | 3 Basics |
Reading data The client starts a read request by sending the index and subindex that point to the object or the object value whose value it wants to read.
The server confirms the request by sending the desired data. The SDO response contains the same index and subindex. The length of the re- sponse data is specified in the command code "ccd".
Client |
|
|
|
|
|
|
|
|
|
|
| Server |
read request |
|
|
| 0 |
| 1 | 2 | 3 | 4 | 5 | 6 | 7 |
|
|
|
|
| ||||||||
| ccd | Idx2 Idx1 Sidx |
| data |
|
| ||||||
| ccd= 40h |
|
|
|
|
|
|
|
| |||
| 0 | 1 |
| 2 |
| 3 | 4 | 5 | 6 | 7 |
| read response |
|
|
|
|
| ||||||||
ccd | Idx | 2 | Idx | 1 | Sidx |
| data |
|
|
| ||
|
|
|
|
|
|
|
|
|
|
| ||
ccd= 43h |
|
|
|
|
|
| data |
|
|
| ||
ccd= 47h |
|
|
|
|
|
| data |
|
|
|
| |
ccd= 4Bh |
|
|
|
|
| data |
|
|
|
| ||
ccd= 4Fh |
|
|
|
|
| data |
|
|
|
|
|
Figure 3.14 Reading a parameter value
Unused bytes in the data field are shown with a slash in the graphic. The content of these data fields is not defined.
ccd coding The table below shows the command code for transmitting a read value. It depends on the message type and the transmitted data length.
Message type | Data length used |
|
| ||
| 4 | 3 | 2 | 1 byte |
|
| bytes | bytes | bytes |
|
|
|
|
|
|
|
|
read request | 40h | 40h | 40h | 40h | Request read value |
Read response | 43h | 47h | 4Bh | 4Fh | Return read value |
Error response | 80h | 80h | 80h | 80h | Error |
Table 3.6 Command code for transmitting a read value
0198441113586, V2.01, 11.2008
Fieldbus interface | 29 |