Communicate with CM550 over c++

I purchased CM550 to control a bunch of servo motors, and I am not sure how should I use the table in CM-550 section 3.1.

is there any resource to help me read and write to CM550 over c++ ? I don’t want to use the task code or its gui.
thanks

@newGUy
The CM-550 itself can be programmed via the TASK V3 tool as you already found out.

With TASK V3, you can program in TASK code (semi-icon based editing) like below:

This TASK code is actually converted into C/C++ code behind the scenes and compiled into binary code before loading it into the CM-550 and executed.

The CM-550 also has an embedded MicroPython Engine, so TASK V.3 can also be used to program in MicroPython, like shown below:

Lines 13 and 14 are statements that access those items shown in the Control Table of the CM-550 whereas DXL(200) corresponds to the CM-550 itself. Regular actuators are usually ID’d from 1 and up.

This MicroPython Enterpreting Engine is pretty good, the MicroPython code runs practically as fast as the compiled C code downloaded via a TASK program.

If you are experienced in C/C++ programming already, you are better off getting an OpenRB-150 and use ARDUINO, and you won’t need to use the CM-550 at all.

The ROBOTIS ecosystem is rather involved and built around the concept of a Dynamixel, you can read my post about DXL here (https://www.cntrobotics.com/robotis-evolving-dynamixel-concept).

I also wrote a specific book about the CM-550 and Engineer Kits 1 & 2:

I also recently published another book for Using Arduino with Robotis Hardware/Software:

I would like to suggest that you go through the free Kindle samples for those two books to decide which way to go with the hardware that you already have (and plan to purchase next) :grinning:

1 Like

Thanks for your thorough response! it is a pitty that there can’t be any direct access to CM550 with C/C++. Is there any specific reason for the developers to do so? I mean in this way, its integration with ROS would not be possible.

Where do you run ROS from? PC or SBC?

This person had to run Matlab from the PC, so he had to use Dynamixel SDK directly, and there is a way to access the CM-550 directly via UART or USB port. It involves the use of the Dynamixel concept at a more advanced level:

If you can describe what you want to do, I can retarget my suggestions more to your needs at a high system level, because I have never used ROS or MATLAB!

I run ROS on a PC.

I need to communicate with CM550 directly with C++, because I can make that C++ code into a ROS node, and merge it to the rest of my system.

I think if you guide me on how to send/receive from CM550 from USB in C or C++, I would really appreciate it,
thanks

Have you ever used Dynamixel SDK? ROBOTIS GitHub has a Dynamixel SDK that works with ROS 1 or ROS 2

ROBOTIS (OpenSourceTeam) also has tutorials videos at

ROBOTIS e-manual also has all the documentations at

That previous MATLAB user posting may be of help, because that person needed to access the regular DXLs (at half-duplex via U2D2) and also the CM-550 (at full duplex via micro USB Port) but separately. Maybe it will be similar for ROS on PC. The CM-550 is just another DXL with ID=200 in the ROBOTIS DXL Network.

@willson or @Jonathon may be of further help as I don’t use ROS so I can’t help much further. Sorry!

1 Like

@roboteer’s suggestion is probably the best information that can be provided on controlling the CM550 in this way, other than using Python.

ROBOTIS doesn’t offer a first party solution for C code on the CM550, but it may be possible to utilize the CM550’s microPython support by creating a microPython library using your own C code.

However, my personal recommendation would be to consider switching to the OpenRB150. I think it would be much easier to implement this functionality by using ROBOTIS’ ROS2Arduino library, rather than trying to implement your own solution from scratch for the CM550.

1 Like

Thanks to both @roboteer and @Jonathon , I didn’t expect so much support! I already bought CM550 so probably I will find a way close to your suggestions.