CANopen communication
Process data transfer (PDO transfer)
Example of a process data telegram
5
42
KHB 13.0003-EN 2.0
5.3.5
Example of a process data telegram
The following objects are to be transferred together in a PDO:
ƒ
Status word, index 6041_00
h
ƒ
Modes_of_operation_display, index 6061_00
h
(operating mode)
The first transmit PDO (TPDO 1) is to be used. 187
h
is to be used as PDO identifier.
1. Delete the number of objects.
Description
Name
Value
To enable the change of the object mapping, the number of
objects has to be set to zero.
number_of_mapped_objects
0
2. Parameterise the objects which are to be mapped.
Description
Name
Value
The objects listed above have to be composed to form a 32-bit
value each:
Index = 6041
h
, subindex = 00
h
, length = 10
h
(UINT16)
first_mapped_object
60410010
h
Index = 6061
h
, subindex = 00
h
, length = 08
h
(INT8)
second_mapped_object
60610008
h
3. Parameterise the number of objects.
Description
Name
Value
The PDO has to contain 2 objects
number_of_mapped_objects
2
h
4. Parameterise the transmission mode.
Description
Name
Value
The PDO is to be sent when data is changed.
transmission_type
FF
h
The PDO is to be sent not more often than every 10 ms
(100 × 100
μ
s).
inhibit_time
64
h
5. Parameterise the identifier.
Description
Name
Value
The PDO has to be sent with the identifier 187
h
. If the PDO is
active, it first has to be deactivated.
Read out the identifier:
cob_id_used_by_pdo
00000181
h
Set bit 31 (deactivate PDO):
cob_id_used_by_pdo
80000181
h
Write new identifier:
cob_id_used_by_pdo
80000187
h
Activate PDO by deleting bit 31:
cob_id_used_by_pdo
00000187
h
Note!
The parameterisation of the PDO can only be changed if the network state
(NMT) is not
operational
.