User Tools

Site Tools


getting_started:tutorials:hal4

This is an old revision of the document!


Using ROS through the HAL

In the EEROS library you will find a directory with examples. Open a shell and run roscore. Open another shell in the build directory of your EEROS library and run sudo -E examples/ros/rosTest2 -c RosTest2Config.json.

Publishing

This example runs your EEROS application as a ROS node under the name /eerosNode. It publishes three topics

  • /test/val (of type double)
  • /test/state (of type boolean)

Use the same tools as in controlsystemros1 to show nodes, topics and messages.

Subscribing

Open another shell in the build directory of your EEROS library and run rosNodeTalker. This is not a EEROS program but simply starts a ROS node which publishes a couple of test topics. As soon as rosNodeTalker runs, your example application will receive the two topics

  • /rosNodeTalker/val (of type double)
  • /rosNodeTalker/state (of type boolean)

and logs its transported message values into the console. Use

$ rqt_graph

to show a graph with all involved nodes together with their topics.

getting_started/tutorials/hal4.1547728116.txt.gz · Last modified: 2019/01/17 13:28 by graf