Skip to content

IntellisenseLab/final-project-akatsuki

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

18 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Final Project QBot AprilTag Routing

This repository contains a ROS 2 Jazzy workspace for the project objective: simulate a QBot that decodes AprilTags, routes each parcel tag to the encoded destination bay, and then run the same routing code on a Raspberry Pi QBot.

The QBot has no arm, so the task is navigation-only. It does not pick up or place parcels.

What The Robot Does

  1. Start at the configured home pose.
  2. Drive to the parcel scan pose.
  3. Decode a visible parcel AprilTag.
  4. Use robot_ws/src/parcel_delivery_robot/config/arena.yaml to map the parcel tag to a destination bay tag.
  5. Drive to the parcel approach pose only to verify the tag.
  6. Drive to the encoded bay approach pose.
  7. Verify the bay AprilTag.
  8. Repeat for all configured parcel tags.
  9. Return home.

Simulate

cd robot_ws
source /opt/ros/jazzy/setup.zsh
colcon build --packages-select robot_interfaces parcel_delivery_robot --symlink-install
source install/setup.zsh
ros2 launch parcel_delivery_robot parcel_delivery_sim.launch.py

The simulation uses simulated_tag_detector, which publishes the same project detection message that the real AprilTag adapter publishes on the Raspberry Pi.

Run On The Raspberry Pi QBot

Before cloning/building on the Pi, you can check whether this computer can see the Pi over Ethernet or Wi-Fi:

./tools/qbot_pi_network_check.sh

For a known Pi address, pass it explicitly:

./tools/qbot_pi_network_check.sh 192.168.1.50 raspberrypi.local

Install the hardware dependencies on the Pi first:

sudo apt update
sudo apt install -y python3-rosdep libfreenect-dev ros-jazzy-apriltag-ros ros-jazzy-apriltag-msgs
sudo rosdep init || true
rosdep update

Then clone/build/run the workspace:

cd ~/Final_Project/robot_ws
source /opt/ros/jazzy/setup.zsh
rosdep install --from-paths src --ignore-src -r -y
colcon build --symlink-install
source install/setup.zsh
../tools/qbot_pi_smoke_check.sh
ros2 launch parcel_delivery_robot parcel_delivery_qbot.launch.py port:=/dev/ttyUSB0

The QBot launch starts the existing Kobuki base driver, odometry, LiDAR, Kinect, apriltag_ros, the AprilTag adapter, and the parcel routing controller.

Expected runtime topics:

  • /cmd_vel: velocity commands to the Kobuki base.
  • /odom: QBot odometry.
  • /scan: LiDAR scan.
  • /detections: apriltag_msgs/msg/AprilTagDetectionArray from apriltag_ros.
  • /kinect/depth_registered/image: Kinect registered depth used to estimate tag range.
  • /parcel_delivery/status: task state and active route.

By default, apriltag_ros reads /kinect/rgb/image_raw and /kinect/rgb/camera_info, then publishes /detections. If your detector publishes on a different topic:

ros2 launch parcel_delivery_robot parcel_delivery_qbot.launch.py apriltag_topic:=/your/detections

The AprilTag adapter also reads /kinect/rgb/camera_info and /kinect/depth_registered/image. It samples registered depth at the detected tag center to publish the tag's relative position, range, and bearing in robot_interfaces/msg/AprilTagDetection.

If your depth image is published elsewhere:

ros2 launch parcel_delivery_robot parcel_delivery_qbot.launch.py depth_image_topic:=/your/depth/image

If you already run your own AprilTag detector, disable the built-in detector:

ros2 launch parcel_delivery_robot parcel_delivery_qbot.launch.py launch_apriltag:=false

If you already publish robot_interfaces/msg/AprilTagDetection directly, disable both the built-in detector and adapter:

ros2 launch parcel_delivery_robot parcel_delivery_qbot.launch.py launch_apriltag:=false use_apriltag_adapter:=false

Real-World Setup Notes

  • Place the QBot at the home_pose from arena.yaml before starting.
  • Arrange parcels and bay markers to match the coordinates in arena.yaml, or edit that file for the real arena measurements.
  • Parcel tags 1, 2, and 3 route to bay tags 101, 102, and 103.
  • The task manager assumes odometry coordinates match the configured arena.
  • AprilTag detection comes from the Kinect RGB image by default.
  • If the real printed tag size is not 0.28 m, update robot_ws/src/parcel_delivery_robot/config/apriltag_36h11.yaml.

ROS generated folders are intentionally ignored and should not be committed: robot_ws/build, robot_ws/install, and robot_ws/log.

About

final-project-akatsuki created by GitHub Classroom

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

No releases published

Packages

 
 
 

Contributors