ros-industrial / ros2_canopen

CANopen driver framework for ROS2
https://ros-industrial.github.io/ros2_canopen/manual/rolling/
143 stars 63 forks source link

COData only allows UINT #218

Closed VerlooyNick closed 10 months ago

VerlooyNick commented 11 months ago

I'm using the proxy driver to operate a Nanotec PD4-C BLDC motor. The motor's PDO velocity target accepts signed integers to allow for negative speeds.

The COdata only accepts unsigned integers as data. Is there a specific reason for this?

hellantos commented 11 months ago

Hi,

The CANopen Stack is aware of the dataype the target sdo has. The data is exactly only data. It will be interpreted as an int32, int16, int8 or uint8, uint16, unit32 depending on the entry in the dcf/eds file.