Skip to content

[Documentation] "How to" Tracker #4

Closed
@guilyx

Description

@guilyx

Create ROS2 Package

source /opt/ros/eloquent/setup.bash
ros2 pkg create --build-type ament_python realtime_statistics

Installation

RT Pendulum Demo

First, get and set the pendulum package here : https://github.com/ros2-realtime-demo/pendulum

$ source /opt/ros/eloquent/setup.bash
$ mkdir -p ~/pendulum_ws/src
$ cd ~/pendulum_ws/src
$ git clone https://github.com/ros2-realtime-demo/pendulum
$ cd ~/pendulum_ws
$ sudo rosdep init
$ rosdep update
$ rosdep install -q -y --from-paths src --ignore-src --rosdistro eloquent
$ colcon build --merge-install # OR colcon build --symlink-install

Then try and run some of these : https://github.com/ros2-realtime-demo/pendulum/blob/eloquent/docs/real_time_tutorial.md

RealTime Statistics

$ mkdir -p ~/rt_stats_ws
$ git clone https://github.com/MasterERTS/ros2_realtime_statistics.git
$ colcon build --symlink-install
$ . install/setup.bash # or setup.zsh if on zsh

Run

Terminal 1 :

$ cd ~/pendulum_ws
$ . install/setup.bash
$ ros2 run pendulum_demo pendulum_demo --priority 80 --pub-stats

Terminal 2 :

$ cd ~/pendulum_ws
$ install/setup.bash
$ ros2 run pendulum_manager pendulum_manager
press 0 to activate all nodes

Terminal 3 :

$ cd ~/rt_stats_ws
$ . install/setup.bash
$ ros2 run realtime_statistics write_json
leave it open for as long as you want then close it

Terminal 4 :

$ cd ~/rt_stats_ws
$ . install/setup.bash
$ ros2 run realtime_statistics plot_json

Metadata

Metadata

Assignees

No one assigned

    Labels

    documentationImprovements or additions to documentation

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions