Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
Collapse
Brand Logo

ModalAI Forum

  1. ModalAI Support Forum
  2. Software Development
  3. Modal Pipe Architecture (MPA)
  4. Send ESDF/TSDF information from voxl-mapper to ROS2

Send ESDF/TSDF information from voxl-mapper to ROS2

Scheduled Pinned Locked Moved Modal Pipe Architecture (MPA)
4 Posts 3 Posters 3.5k Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • Jeffrey MaoJ Offline
    Jeffrey MaoJ Offline
    Jeffrey Mao
    Contributor
    wrote on last edited by
    #1

    Hi Modalai,

    Currently, I have the voxl mapper running, but when I run voxl_mpa_to_ros2. I see that only voxl_mapper_aligned_ptcloud is brought over to ROS2 because the interface for voxl_mpa_to_ros2 only has a pointcloud interface. What sort of interface would be needed to be made for the voxl_mapper_costmap to ROS2 or is there a certain guide. Also would it be possible to expose either the TSDF/ESDF from voxl-mapper to the MPA and then bring it to ROS2?

    voxl_mapper_aligned_ptcloud
    voxl_mapper_costmap
    voxl_mesh
    voxl_mesh_endpoint

    Thanks,

    Jeff

    ModeratorM 1 Reply Last reply
    0
    • Jeffrey MaoJ Jeffrey Mao

      Hi Modalai,

      Currently, I have the voxl mapper running, but when I run voxl_mpa_to_ros2. I see that only voxl_mapper_aligned_ptcloud is brought over to ROS2 because the interface for voxl_mpa_to_ros2 only has a pointcloud interface. What sort of interface would be needed to be made for the voxl_mapper_costmap to ROS2 or is there a certain guide. Also would it be possible to expose either the TSDF/ESDF from voxl-mapper to the MPA and then bring it to ROS2?

      voxl_mapper_aligned_ptcloud
      voxl_mapper_costmap
      voxl_mesh
      voxl_mesh_endpoint

      Thanks,

      Jeff

      ModeratorM Offline
      ModeratorM Offline
      Moderator
      ModalAI Team
      wrote on last edited by
      #2

      @Jeffrey-Mao voxl-mapper leverages voxlblox. You could look at their ROS implementation and try to port it over https://github.com/ethz-asl/voxblox/tree/master/voxblox_ros/src

      Jeffrey MaoJ 1 Reply Last reply
      0
      • ModeratorM Moderator

        @Jeffrey-Mao voxl-mapper leverages voxlblox. You could look at their ROS implementation and try to port it over https://github.com/ethz-asl/voxblox/tree/master/voxblox_ros/src

        Jeffrey MaoJ Offline
        Jeffrey MaoJ Offline
        Jeffrey Mao
        Contributor
        wrote on last edited by
        #3

        @Moderator Right I think that is a bit too difficult.

        I just edited the voxl-mapper library to send the pointcloud and it works now to get the map in ROS2 with the mpa_ros2 interface. It is a bit weird that you guys have this esdf publish pipe as a pointcloud but it doesn't seem exposed naturally

        Link Preview Image
        server/voxl-mapper/voxl_mapper.cc · master · voxl / VOXL SDK / Services / voxl-mapper · GitLab

        GitLab.com

        favicon

        GitLab (gitlab.com)

        void TsdfServer::publishEsdfPointcloud(){
            std::vector<point_xyz_i> esdf_ptcloud;
        
            voxblox::Layer<voxblox::EsdfVoxel> *layer_ptr = esdf_map_->getEsdfLayerPtr();
            createDistancePointcloudFromEsdfLayer(*layer_ptr, esdf_ptcloud);
        
            // intensity ptcloud for distance
            point_cloud_metadata_t esdf_meta;
            esdf_meta.magic_number = POINT_CLOUD_MAGIC_NUMBER;
            esdf_meta.timestamp_ns = rc_nanos_monotonic_time();
            esdf_meta.n_points = esdf_ptcloud.size();
            esdf_meta.format = POINT_CLOUD_FORMAT_FLOAT_XYZC;
        
            pipe_server_write_point_cloud(COSTMAP_CH, esdf_meta, esdf_ptcloud.data());
        }
        
        Roya SalehzadehR 1 Reply Last reply
        0
        • Jeffrey MaoJ Jeffrey Mao

          @Moderator Right I think that is a bit too difficult.

          I just edited the voxl-mapper library to send the pointcloud and it works now to get the map in ROS2 with the mpa_ros2 interface. It is a bit weird that you guys have this esdf publish pipe as a pointcloud but it doesn't seem exposed naturally

          Link Preview Image
          server/voxl-mapper/voxl_mapper.cc · master · voxl / VOXL SDK / Services / voxl-mapper · GitLab

          GitLab.com

          favicon

          GitLab (gitlab.com)

          void TsdfServer::publishEsdfPointcloud(){
              std::vector<point_xyz_i> esdf_ptcloud;
          
              voxblox::Layer<voxblox::EsdfVoxel> *layer_ptr = esdf_map_->getEsdfLayerPtr();
              createDistancePointcloudFromEsdfLayer(*layer_ptr, esdf_ptcloud);
          
              // intensity ptcloud for distance
              point_cloud_metadata_t esdf_meta;
              esdf_meta.magic_number = POINT_CLOUD_MAGIC_NUMBER;
              esdf_meta.timestamp_ns = rc_nanos_monotonic_time();
              esdf_meta.n_points = esdf_ptcloud.size();
              esdf_meta.format = POINT_CLOUD_FORMAT_FLOAT_XYZC;
          
              pipe_server_write_point_cloud(COSTMAP_CH, esdf_meta, esdf_ptcloud.data());
          }
          
          Roya SalehzadehR Offline
          Roya SalehzadehR Offline
          Roya Salehzadeh
          wrote on last edited by
          #4

          @Jeffrey-Mao Hello Jeffery, We are currently working on implementing SLAM for the Starling 2 platform. Our initial approach involved using the available ROS 2 topics provided by voxl_mpa_to_ros2, installing standard SLAM packages, and using RViz for visualization. However, we've encountered a major issue: most of the topics do not have a frame_id defined, and there is no existing transform (TF) tree that can be used with RViz.

          So far, we've only been able to visualize the tof_pc (Time-of-Flight point cloud) data. To do this, we had to manually publish a static transform between the TOF frame (which is named world) and map. However, in this setup, the drone's location does not update dynamically. To address this, we're considering writing a transformation node to define the relationships between coordinate frames (e.g., map, odom, base_link, tof, etc.). However, developing this from scratch is proving to be time-consuming and error-prone.

          I also noticed that you were able to generate a map using voxl-mapper and et the map in ROS2 with the mpa_ros2 interface. This could be a much more efficient path for us to pursue. Could you please explain in detail:

          What exact steps you followed to export the map using voxl-mapper?

          Is it possible to regenerate or update the map in real-time in RViz, or export it to another visualization tool?

          Thanks

          1 Reply Last reply
          0

          Hello! It looks like you're interested in this conversation, but you don't have an account yet.

          Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.

          With your input, this post could be even better 💗

          Register Login
          Reply
          • Reply as topic
          Log in to reply
          • Oldest to Newest
          • Newest to Oldest
          • Most Votes


          ModalAI
          Categories Recent Tags ModalAI.com Docs
          © 2026 ModalAI® · Accelerating autonomy for smaller, smarter, safer drones · Powered by NodeBB
          • Login

          • Don't have an account? Register

          • Login or register to search.
          • First post
            Last post
          0
          • Categories
          • Recent
          • Tags
          • Popular
          • Users
          • Groups