Ask Your Question
0

Can I just use socketcan_bridge and socketcan_interface ROS packages to communicate with motor controllers using ROS?

asked 2019-08-23 12:02:28 -0500

Nochika gravatar image

Hi,

Can I just use socketcan_bridge and socketcan_interface ROS packages, basically the CAN layer, to communicate with motor controllers using ROS? Or do I have to use a CAN protocol like CANopen? In the case that the motor controller I'm planning to use uses a different CAN protocol, like SAE J1939, or different CANopen profile than 402 which is the one that ros_canopen package implements.

Best,

edit retag flag offensive close merge delete

1 Answer

Sort by » oldest newest most voted
0

answered 2019-09-02 06:36:52 -0500

Mathias Lüdtke gravatar image

Can I just use socketcan_bridge and socketcan_interface ROS packages, basically the CAN layer, to communicate with motor controllers using ROS?

While it is possible to use raw CAN messaging via socketcan_bridge, I would not recommend it. ROS messaging is not deterministic and this might result in timing-related problem during control.

As an alternative you could implement your own control (ROS) node, which uses socketcan_interface for low-level communication.

Or do I have to use a CAN protocol like CANopen?

You don't have to used CANopen, but it is widely adopted. canopen_master offers C++ classes for building your own CANopen master node.

canopen_chain_node even offers a ROS-based implementation for interfacing with CANopen nodes that is meant to be subclassed to support higher-level profiles (like canopen_402).

In the case that the motor controller I'm planning to use uses a different CAN protocol, like SAE J1939, or different CANopen profile than 402 which is the one that ros_canopen package implements.

canopen_motor_node uses canopen_402 by default, but you create your own CANopen-based motor plugin (canopen::MotorBase)

However, for SAE J1939 (not CANopen-based) you would need to write your custom implementation.

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

2 followers

Stats

Asked: 2019-08-23 12:02:28 -0500

Seen: 18 times

Last updated: Sep 02