ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question
2

Standard way to use ROS with Real-time OS

asked 2015-09-05 20:51:44 -0500

moyashi gravatar image

Hi there,

I'm trying to use ROS with hard real time system.
What is the standard way to do it ?
Is there good instruction to do it ?

I looked over web and I thought xenomai would work fine ...
But I'm not sure that's true.

Also, I could find a solution like "sudo apt-get install linux-realtime". But apparently it doesn't work, because it's for Ubuntu 12.04 or older and I'm using Ubuntu 14.04 and ROS Indigo.

Perhaps, some people might think that it's weird to use ROS with hard real time system.
Of course, I don't use ros message and service in control loop.
The point is that I need hard real time system for other purpose
and don't like to break the system which has already installed ROS.
I'd like coexistence of them.(I hope real time kernel doesn't affect ros...)

Thank you.

edit retag flag offensive close merge delete

Comments

Wonderful!

Science gravatar image Science  ( 2015-10-07 03:45:53 -0500 )edit

1 Answer

Sort by » oldest newest most voted
3

answered 2015-09-06 00:46:13 -0500

gvdhoorn gravatar image

If your question is whether it is possible to install (fi) RT-PREEMPT or Xenomai on a system that is also being used to run ROS, then sure, that is certainly possible. In fact, many people do it (in order to be able to use OROCOS for their real-time control needs for instance). The specific kernel you install should have no influence on your ROS nodes (providing all the hardware you require is still properly supported by your new kernel, of course).

Note though that ROS 1.0 itself (ie: the middleware and probably almost all components) is inherently not hard real-time capable. This holds no matter what OS you run it on.

As to how to install RT-PREEMPT or Xenomai on your Trusty system, there are a multitude of tutorials available on the internet. The fact that you already have ROS installed on your machine should not matter.

edit flag offensive delete link more

Comments

May be we should try to do that!

Science gravatar image Science  ( 2015-10-07 03:49:04 -0500 )edit

As you mentioned that ROS 1.0 itself (ie: the middleware and probably almost all components) is inherently not hard real-time capable -> It means that even after installation of preeemt-rt like OSes can't ROS nodes are not real time capable? Please share your opinion.

TraiBo gravatar image TraiBo  ( 2017-10-13 05:23:39 -0500 )edit

If you have a real-time OS, it's perfectly possible to create real-time threads inside a ROS node / process. The ROS middleware itself will still not be real-time by default. Any interaction with other nodes will be non real-time.

gvdhoorn gravatar image gvdhoorn  ( 2017-10-13 05:52:21 -0500 )edit

Thank you gvdhoorn, Yes I have installed Preemt-RT patch running on Ubuntu 14.04. it's perfectly possible to create real-time threads inside a ROS node / process -> Is there any help or example where I can see creating real-time threads inside a ROS node.

TraiBo gravatar image TraiBo  ( 2017-10-13 06:01:30 -0500 )edit

re: help or example: no. But this is no different from how you would normally do it, so there is nothing ROS specific about it.

gvdhoorn gravatar image gvdhoorn  ( 2017-10-13 06:02:22 -0500 )edit

Hopefully I am thinking the same except priority setting in the ROS node. Thank you for your response and can I expect answer for the following question link I am sharing here https://answers.ros.org/question/2474...

TraiBo gravatar image TraiBo  ( 2017-10-13 06:14:41 -0500 )edit

Question Tools

2 followers

Stats

Asked: 2015-09-05 20:51:44 -0500

Seen: 2,656 times

Last updated: Sep 06 '15