CAN-Bus Interface on OpenCR 1.0 (TurtleBot3)

Hi and a happy New Year to all of you…

on a side project I am working on connecting my TurtleBot3 to the CAN bus.

The OpenCR 1.0 board has a CAN port…

image

… and the Arduino port includes a CAN library, but I have no idea how to use it (especially if it provides a transceiver or only a controller) and there is no mentioning of it in the eManual.

Has anyone ideas?

Thanks in advance and greetings

Kai

1 Like

You might be required to to convert the DYNAMIXEL protocol to CAN protocol and vice versa. Unfortunately, I’ve never used the CAN port, so that I could not give you a big help :frowning: However, I found that ROBOTIS e-Manual provides a arduino example called " CAN2DYNAMIXEL which converts the DYNAMIXEL Protocol to CAN protocol through some interface which converts the USB to CAN

Although this is based on Arduino, it would be worthy of referencing.

@Yogurt_Man thank for your your reply. I saw the CAN2DYNAMIXEL example and it inspired me to try a different approach on the Rotortug (only on my testbed) with two Arduino MKR boards + CAN-Shields + Dynamixel Shield (I red-boxed both the MKR’s and the CAN connection in the picture):

What I have in mind for the TurtleBot3 is a bit different, since the OpenCR board there should finally run the Arduino port of micro-ROS and connect to other MCU’s via CAN. But before diving into micro-ROS I would like to kown the board hardware better… :wink:

Using CAN to connect different MCU’s, SOC’s (like Raspi’s) and even PC’s could be a real game changer for my project. The MCU (STM32F103CB) of the OpenCM 9.04 does have a CAN controller, but that’s not mentioned in the eManual, too (maybe it’s not even HAL-connected to a board pin).

Well I am a bit down that it wasn’t an big help.

… and the Arduino port includes a CAN library, but I have no idea how to use it (especially if it provides a transceiver or only a controller) and there is no mentioning of it in the eManual .

You may already notice there is the CAN example in OpenCR example. But I just wanna share it in case,

If you would like to use the CAN port with TurtleBot3, Seems that you need to modify the TurtleBot3 core and put the CAN library in the core.

I will google whether there is any case who made the CAN protocol successful in ROS.

1 Like

…thanks for pointing me in the right direction, that’s exactly what I was looking for! :slight_smile:

1 Like

@WaldoPepper I had a similar question about CAN bus support on the OpenCR board and thought I would share what I found regarding the hardware, in case it helps you or anyone else in the future.

There is a schematic for the OpenCR board available at GitHub - ROBOTIS-GIT/OpenCR-Hardware: BOM, Circuit and PCB Gerber of OpenCR
From this, it shows that the CAN_TX/CAN_RX pins on the MCU are routed through a TJF1051 high-speed CAN transceiver chip.

So other than loading up the correct Arduino code as described by Yogurt_Man above, it looks like you don’t need to do anything else to get CAN working.

1 Like

Welcome to community :slight_smile: