Skip to content

iamyufan/hri-project

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

18 Commits
 
 
 
 
 
 
 
 

Repository files navigation

HRI Final Project

Authors

  • Henry Bao (hb482)
  • Liz Wang (sw2333)
  • Yuan Liu (Alan) (yl3688)
  • Yufan Zhang (Bruce) (yz2894)
  • Waranun Wachakorn (Peary) (ww554)

How-To

Enable the object detection topic:

Install DepthAI-ROS:

sudo apt install ros-humble-depthai-ros

Run the YOLO object detection node:

ros2 launch depthai_examples mobile_publisher.launch.py
ros2 launch depthai_examples rgb_stereo_node.launch.py

Open a new terminal, check if the topic exists:

ros2 topic list | grep mobile
  • This should give:
    /colors/mobilenet_detections

Check if the topic yeilds any messages:

ros2 topic echo /colors/mobilenet_detections
  • This should return something like this if there is no object detected:

    ---
    header:
      stamp:
        sec: 1730486765
        nanosec: 639241689
      frame_id: oak_rgb_camera_optical_frame
    detections: []
  • If there is a person (class_id = 15) being detected:

    ---
    header:
      stamp:
        sec: 1730485920
        nanosec: 232146637
      frame_id: oak_rgb_camera_optical_frame
    detections:
    - header:
        stamp:
          sec: 0
          nanosec: 0
        frame_id: ''
      results:
      - hypothesis:
          class_id: '15'
          score: 0.95361328125
        pose:
          pose:
            position:
              x: 0.0
              y: 0.0
              z: 0.0
            orientation:
              x: 0.0
              y: 0.0
              z: 0.0
              w: 1.0
          covariance:
          - 0.0
          - 0.0
          - 0.0
          - 0.0
          - 0.0
          - 0.0
          - 0.0
          - 0.0
          - 0.0
          - 0.0
          - 0.0
          - 0.0
          - 0.0
          - 0.0
          - 0.0
          - 0.0
          - 0.0
          - 0.0
          - 0.0
          - 0.0
          - 0.0
          - 0.0
          - 0.0
          - 0.0
          - 0.0
          - 0.0
          - 0.0
          - 0.0
          - 0.0
          - 0.0
          - 0.0
          - 0.0
          - 0.0
          - 0.0
          - 0.0
          - 0.0
      bbox:
        center:
          position:
            x: 222.0
            y: 151.5
          theta: 0.0
        size_x: 156.0
        size_y: 299.0
      id: '15'

Scan data from the LiDAR sensor

Check if the topic exists:

ros2 topic list | grep scan

Inspect the topic /scan:

ros2 topic echo /scan
  • This should start to yeild some messages. If not, try rebooting the system.

Run the package

Navigate to the ROS workspace and run the package:

rosdep install --from-path src -yi
source /opt/ros/humble/setup.bash
colcon build --symlink-install
source install/setup.bash
ros2 run robot_control_architecture_pkg robot_control_architecture_node

ros2 pkg create --build-type ament_python --license Apache-2.0 --node-name robot_control_architecture_node robot_control_architecture_pkg

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python 54.2%
  • Shell 33.1%
  • PowerShell 12.7%