• Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Register
  • Login
ModalAI Forum
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
    • Register
    • Login

    mpa_to_ros publish stereo left and right image in different timestamp

    Ask your questions right here!
    2
    5
    279
    Loading More Posts
    • 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.
    • D
      Dong Liu
      last edited by 30 Mar 2023, 17:19

      Here is the code,

      imgL.header.stamp = (_clock_monotonic_to_ros_time(meta.timestamp_ns));
      imgL.width    = meta.width;
      imgL.height   = meta.height;
      imgL.step     = meta.width;
      imgL.encoding = GetRosFormat(meta.format);
      
      imgR.header.stamp = (_clock_monotonic_to_ros_time(meta.timestamp_ns));
      imgR.width    = meta.width;
      imgR.height   = meta.height;
      imgR.step     = meta.width;
      imgR.encoding = GetRosFormat(meta.format);
      

      They are all from meta.timestamp_ns, but _clock_monotonic_to_ros is using the current time, so the final times are slight different.

      I think it should be
      imgR.header.stamp = imgL.header.stamp

      1 Reply Last reply Reply Quote 0
      • C
        Chad Sweet ModalAI Team
        last edited by 30 Mar 2023, 17:21

        Thanks for the suggestion! We are happy to incorporate our partners merge requests if you want to make one on gitlab!

        1 Reply Last reply Reply Quote 0
        • D
          Dong Liu
          last edited by 30 Mar 2023, 17:58

          will do soon.

          1 Reply Last reply Reply Quote 0
          • D
            Dong Liu
            last edited by 30 Mar 2023, 21:12

            MR submitted.

            1 Reply Last reply Reply Quote 0
            • D
              Dong Liu
              last edited by 3 Apr 2023, 20:30

              Just tried to calibrated the stereo camera using ROS camera calibrator. Had to run the fixed voxl-mpa-to-ros. Because the ROS calibrator expects left and right to be exactly synchronized.

              1 Reply Last reply Reply Quote 0
              1 out of 5
              • First post
                1/5
                Last post
              Powered by NodeBB | Contributors