Remapping Pose Data to PX4
This page gives details on how to remap the streamed Clover pose data to the PX4 for localization and control.
Last updated
This page gives details on how to remap the streamed Clover pose data to the PX4 for localization and control.
Last updated
MAVROS provides a plugin to relay pose data published on /mavros/vision_pose/pose to PX4. Assuming that MAVROS is running, you just need to remap the pose topic that you get from the MoCap /vrpn_client_node/clover1/pose directly to /mavros/vision_pose/pose. The Clover packages already have a MAVROS launch file setup to connect the raspberry Pi to the flight controller using MAVROS.
The method presented involves using an application called topic_tools and is discussed further.
The method of choice gives you the ability to turn the remap function on and off after launch. This functionality is useful because it allows you to view the /vrpn_client_node/clover1/pose topic and /mavros/vision_pose/pose topic separately in to ensure the yaw offset is minimal before remapping and fusing the external vision pose and onboard pose estimation. A ROS package called can be used to remap the topic where the package source can be found in its github . The steps to build from source for ROS Noetic are shown:
The following command can now be run on the Ubuntu Linux machine to remap the topic:
Another consideration when remapping the vrpn topic to the mavros vision topic is listed below, which involves coding a remap command into the sample.launch file.
From the description , the following command can be coded in vrpn launch file or sample.launch file to remap the vrpn topic to the vision_pose topic (assuming a rigid body name of clover1):