VOXL MPA_to_ROS rostopics not subscribing to anything
-
@Darshit-Desai that service is setup so that it does not publish anything without a subscriber. maybe try to record a rosbag to see if you're getting data?
-
rostopic hz /trackingshould subscribe to the topic and work as you expected.
e.g. for me:

I've seen two things that might be happening:
-
The
voxl-camera-servicehas stopped running. Check withvoxl-inspect-services,voxl-inspect-qvio,systemctl status voxl-camera-service. -
Your environment variables might not be set right for ROS1 remote message transport. Setting
ROS_MASTER_URIon your laptop to point to the master running on the voxl is enough to discover ROS1 topic names. Two more variables are needed to be set to get message transport workingROS_IPandROS_HOSTNAME
Here's an example that works for me. Adjust it to match the IP addresses for your voxl2, laptop, and the ROS1 version you're running on your laptop. Select the image you want to view in the rqt_image_view GUI.
Script on voxl2:
start_mpa_to_ros1.sh#!/bin/bash source /opt/ros/melodic/setup.bash voxlIP=`hostname -I | awk '{print $1}'` echo "VOXL IP is: " $voxlIP export ROS_IP=$voxlIP echo "ROS_IP is: " $ROS_IP export ROS_HOSTNAME=$voxlIP echo "ROS_HOSTNAME is: " $ROS_HOSTNAME echo "ROS_MASTER_URI is: " $ROS_MASTER_URI roslaunch voxl_mpa_to_ros voxl_mpa_to_ros.launchScript on laptop:
start_rqt_imageview.sh#!/bin/bash # change these to match the computer connecting to VOXL ROS1 MasterIP=192.168.1.100 MyIP=192.168.1.101 ROS_DIST=noetic # set environment variables and start rqt_image_view source /opt/ros/$ROS_DIST/setup.bash export ROS_IP=$MyIP export ROS_HOSTNAME=$MyIP export ROS_MASTER_URI=http://$MasterIP:11311 rosrun rqt_image_view rqt_image_view -
-
@ben-grocholsky Thanks that helped me do it.
My tof_ir, tof_conf image feed is rotated 90 degrees counter clockwise when the drone is in a normal position, is there way to change that rotation

-
@Darshit-Desai @Moderator Can anyone reply on this post?
-
@Darshit-Desai Can anyone help with this? @tom
-
@Darshit-Desai this is a more generic ROS
tftransform network question than anything specific to ModalAI devices. You can get any result you'd like by adding appropriate frames to map or vehicle in thetftree. For example, sincervizis hard coded to expect z axis upwards and everything is easier with z axis down, I'll attach anENUframe to every fixed mapNEDframe and vehicle carried bodyFRDframe. That allows for all algorithms to be implemented inNED/FRDand still use ROS visualization by selectingENUframes asfixedandview.Check out the
tfdocumentation http://wiki.ros.org/tf2The
static transform publisheris a quick way to test changes. Then you'll want to explore using http://wiki.ros.org/urdf -
@ben-grocholsky It shows up the same in VOXL PORTAL too.
Is there a way to get camera intrinsic Matrix of the ToF camera. Also, if I want to align the depth image with the RGB image how do I do that? -
@Darshit-Desai I wanted to ask one more follow up to this question? The datasheet in voxl-documentation says the PMD TOF runs at 45 fps for ranging distances less then 1 metres. Is there a way to set that?
-
-
@Darshit-Desai No, there is no current way to set that
-
@Darshit-Desai said in VOXL MPA_to_ROS rostopics not subscribing to anything:
@ben-grocholsky It shows up the same in VOXL PORTAL too.
Is there a way to get camera intrinsic Matrix of the ToF camera. Also, if I want to align the depth image with the RGB image how do I do that? -
@Darshit-Desai the recommendation to learn about
tf,urdf, andxacroin ROS was because that's a way to achieve what you're asking for. If you get thelaunchandconfigfiles right then ROS tools such asrvizwill do what ever you want without writing any code. -
@Darshit-Desai said in VOXL MPA_to_ROS rostopics not subscribing to anything:
Is there a way to get camera intrinsic Matrix of the ToF camera. Also, if I want to align the depth image with the RGB image how do I do that?
Hi sorry, I wanted to ask about the intrinsics that was highlighted by mistake. @ben-grocholsky