Documented target: Ubuntu 24.04 · ROS 2 Jazzy · Gazebo Harmonic where used. Browser labs tested; ROS/Ubuntu/hardware execution not performed here.
What you will understand
- Distinguish package, executable and node.
- Inspect a live node.
- Build a package skeleton.
Prerequisites: Choose and verify a ROS 2 environment and its stated environment.
The idea, made clear.
A package groups source, dependencies and executable entry points. A node is a running graph participant. One executable may create several nodes, and a package can supply several executables. A package being installed does not mean its node is running.
A colcon workspace usually contains src plus generated build, install and log directories. Sourcing install/setup.bash overlays built packages onto an existing ROS installation. Source the underlay first and workspace overlay afterward in every new terminal used for the exercise.
Inspect before editing. Namespaces, node names and remappings are runtime identifiers. A process that exits immediately disappears from the graph. Two processes sharing a node name can confuse introspection; give instances distinct names when investigating them.
Try it, step by step.
Inspect the graph
Keep a demo talker running.
ros2 node list
ros2 node info /talkerExpected: The talker and its communication endpoints.
Create a package
Requires a sourced Jazzy shell and development tools.
mkdir -p ~/nexviora_ws/src
cd ~/nexviora_ws/src
ros2 pkg create --build-type ament_python nexviora_demo --dependencies rclpy std_msgsExpected: Package source and metadata; no runnable entry point yet.
Build and source
Build from workspace root.
cd ~/nexviora_ws
colcon build --symlink-install
source install/setup.bash
ros2 pkg prefix nexviora_demoExpected: The package resolves to this workspace install prefix.
If something goes wrong
- Package missing after build
- Source the install setup script in your run terminal.
- Unresolved dependency
- Inspect package.xml and install the matching dependency.
Check your understanding
Make it yours
Start a second talker with --ros-args -r __node:=second_talker and inspect both.
Optional progress stays in this browser. No account needed.
Go to the source documentation
Commands are educational examples for the stated environment, not a transcript of local ROS execution. Verify actual behavior on your machine.