qrb_ros_transport

Quickstart

  1. Add dependencies in your package.xml

    <depend>qrb_ros_transport</depend>
    
  2. Use ament_cmake_auto to find dependencies in your CMakeLists.txt

    find_package(ament_cmake_auto REQUIRED)
    ament_auto_find_build_dependencies()
    
  3. Using adapted types in your ROS node

    #include "qrb_ros_transport/type/image.hpp"
    
    // create message
    auto msg = std::make_unique<qrb_ros::transport::type::Image>();
    msg->header = std_msgs::msg::Header();
    msg->width = width;
    msg->height = height;
    msg->encoding = "nv12";
    
    // alloc dmabuf for message
    auto dmabuf = lib_mem_dmabuf::DmaBuffer::alloc(size, "/dev/dma_heap/system");
    // ... set data to dmabuf
    msg->dmabuf = dmabuf;
    
    // publish message
    pub->publish(std::move(msg));
    

Supported Types

The following table lists current supported types:

QRB ROS Transport Type

ROS Interface

qrb_ros::transport::type::Image

sensor_msgs::msg::Image

qrb_ros::transport::type::Imu

sensor_msgs::msg::Imu