0
$\begingroup$

Rosanswers logo

Hello all,

I am currently in the process of working on a custom robot with custom joints. We have electric motors with an encoder and a low level driver that we can communicate with via CAN. I'm wondering how do we get ros_control and eventually MoveIt to control the robot completely. I was looking for tutorials on the wiki page, and didn't find anything of real use. I've used ros_control with Universal Robots, but never for a custom system. Does anyone have any general information on how to go about this?

I will update with the actually CAN controller when the electrical engineer on the project selects it. I'm just trying to look ahead.


Originally posted by atomoclast on ROS Answers with karma: 151 on 2016-10-21

Post score: 0


Original comments

Comment by guidout on 2023-05-14:
hi, did you find a good solution or example on how to use CAN in a hardware interface?

$\endgroup$

2 Answers 2

0
$\begingroup$

Rosanswers logo

Provided you are actually using CANopen, you could look at the ros_canopen packages. The canopen_motor_node abstracts CiA 402 devices, by exposing ros_control compatible hardware interfaces (based on what the configured devices support). There are other OSS implementations for ROS and CANopen, but I don't know of any that come with plug-and-play ros_control support.

After you have the ros_control interface configured, things will be similar to how you used the ur_modern_driver (or at least: I'm assuming that's what you meant when you wrote "used ros_control with Universal Robots").

I was looking for tutorials on the wiki page, and didn't find anything of real use.

That doens't surprise me too much, as "I'm creating a custom robot and interfacing with my actuators and sensors using CAN" is apparently not common enough that it warrant(s)(ed) a dedicated tutorial (yet).

It would be nice to add one though.


Originally posted by gvdhoorn with karma: 86574 on 2016-10-21

This answer was NOT ACCEPTED on the original site

Post score: 1

$\endgroup$
0
$\begingroup$

Rosanswers logo

We are also currently working with field robots that use J1939 CAN hydraulic valve controllers. We use CAN communication cards that are compatible with SocketCAN. This makes it extremely easy to send CAN messages from a C++ API. CANopen is limited to industrial robots, which may/may not be what you're using. But if CANopen isn't a possibility, SocketCAN is your next best option. There is USB2CAN from 8devices which is $60, as well as mini PCI-E cards from Innodisk, both of which we have tested and are currently using. The write method of your hardware_interface simply writes a CAN message onto the bus.


Originally posted by ufr3c_tjc with karma: 885 on 2017-02-26

This answer was NOT ACCEPTED on the original site

Post score: 1


Original comments

Comment by andrestoga on 2019-08-22:
but SocketCAN is not a CAN protocol. It's just an API library.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.