ROS Resources: Documentation | Support | Discussion Forum | Service Status | Q&A

ROS 2 on embedded platform

I have been following ROS 2 development since seeing the ROScon 2015 on ROS 2 on embedded platforms.
I purchased a NUCLEO-F767ZI and this has a newer RTOS mbed-OS 5.0 and I have been able to get broadcast UDP working with two tasks. I have been looking at a lot of the older code on github and I asked this question in the google group. Is there any new work with getting ROS 2 on embedded platforms? I would love to create a C++11 class that would be usable for all mbed-os 5.0 devices. Make it as portable as possible. Any tips on where to get started?


1 Like

No one at OSRF has had time lately to work on embedded platforms recently, but we are still really interested in them.

I’m not 100% certain what OS primitives mbed-OS gives you, but you might consider trying to get one of the DDS/RTPS implementations to compile for it, though it might not meet your needs. The other option would be to try and write the RTPS protocol yourself, potentially borrowing code from @codebot’s FreeRTPS project as needed:

The RTPS wire format is described in the “DDSI-RTPS” document:

Once you have an RTPS (or DDS) implementation going, you need to use it to implement the “rmw” (ROS Middleware Interface), see:

After that you just need to be able to compile the rcl and then optionally the rclcpp libraries on top. There has been some discussions lately with how to build these parts of the stack into static libraries, which I imagine you’d need to do:

And finally, we’re using C++14 now, so if that’s something you cannot handle with the mbed-os then, you might want to chime in here:

1 Like

Thanks for the feedback. I have been manually switching the mbed-os to C++14 and have not run into any issues with gcc so I don’t think that will be a problem. Thanks for the steps, now I have something to work through.


I had a look at the different ros2_embedded_* variants a while back. IMHO nuttx seems much more promising compared to mbed(-OS) as it is POSIX compliant, not geared towards IoT, and even tries to be compatible with many Linux APIs. Different STM32 variants are well supported by nuttx already. However, you might need to create a board config for your eval board.

1 Like