eeros_architecture:control_system:available_blocks:canopenreceive
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revision | |||
eeros_architecture:control_system:available_blocks:canopenreceive [2024/05/30 17:29] – ursgraf | eeros_architecture:control_system:available_blocks:canopenreceive [2024/05/30 17:37] (current) – ursgraf | ||
---|---|---|---|
Line 8: | Line 8: | ||
Each drive has its own node id and its specific input index (0 to N-1). After the block has been created you have to configure the PDOs which are sent to each drive. While doing this you must specify which of the signal inputs (floating point or fixed point) get included into which PDO. Both signals can be vectors. The method | Each drive has its own node id and its specific input index (0 to N-1). After the block has been created you have to configure the PDOs which are sent to each drive. While doing this you must specify which of the signal inputs (floating point or fixed point) get included into which PDO. Both signals can be vectors. The method | ||
<code cpp> | <code cpp> | ||
- | configureRPDO(uint8_t nodeId, uint8_t | + | configureTPDO(uint8_t nodeId, uint8_t |
</ | </ | ||
- | includes a vector of all CANopen objects which are mapped into this RPDO together with a corresponding vector of indices. These indices determine which signal is taken for this RPDO. To give an example: idx=1 takes the floating point signal at index 0, idx=2 takes the floating point signal at index 1, idx=0 takes the control | + | includes a vector of all CANopen objects which are mapped into this TPDO together with a corresponding vector of indices. These indices determine which signal is written to the output |
- | How could this be used? Let us assume, that the drive with node id = 37 should receive a RPDO1 with control | + | How could this be used? Let us assume, that the drive with node id = 37 sends TPDO1 with status |
<code cpp> | <code cpp> | ||
- | configureRPDO(37, RPDO1, {controlObj, velModeSetValObj}, {0,1}); | + | configureTPDO(37, TPDO1, {statusObj, posActValObj}, {0,1}); |
- | configureRPDO(37, RPDO2, {digOutStateObj}, {-1}); | + | configureTPDO(37, TPDO2, {digInStateObj, |
</ | </ | ||
- | The control | + | The status |
<code cpp> | <code cpp> | ||
- | setCtrl(uint8_t index, uint16_t ctrl>); | + | getStatus(uint8_t index); |
</ | </ | ||
- | The floating point input signals expect | + | The floating point output |
<code cpp> | <code cpp> | ||
setScale(Matrix< | setScale(Matrix< |
eeros_architecture/control_system/available_blocks/canopenreceive.1717082944.txt.gz · Last modified: 2024/05/30 17:29 by ursgraf