I’m currently working on a hexacopter and wanted to use Mocap instead of the regular IMU readings, but when I tried following the detailed guide about fake gps in the developer guide, I had a few issues:
Namely, I cannot find the following parameters in any of the suggested places: 1) ATT_EXT_HDG_M, 2) INAV_DISAB_MOCAP.
I also cannot change the paramter SYS_COMPANION to the suggested “magic mode” of 257600, due to the drop down list.
I am using the most recent QGroundControl developer build and flashed the most up-to-date firmware on the Pixhawk. Any ideas?
Good news! I now know the reason why I could not find these parameters. The pixhawk apps for them (attitude_estimator_q and local_position_estimator) were disabled in the build of px4fmu-v2. This made me stumble on the post about the same problem here on the PX4 Discuss if anyone is facing a similar problem:
I am facing the same issue right now. Have you been able to solve this ?. Are there some parameters that need to be enabled? If so could you tell me which ?.
What you need to do is go to Firmware/cmake/configs and change the nuttx_px4fmu_v2_default.cmake if using make px4fmu_v2. This file decides which applications are built, and you need to enable the estimator modules 1) local position estimator and 2) attitude_estimator_q , while removing ekf2 (comment it). This should enable you to find the missing parameters.
Make sure to then change ALL the parameters as entailed on the dev guide , apparently disbling barometric fusion is essential. Good luck
Refer to the dev guide (dev.px4.io) and look at the fake gps section. Yes, I use mavros because it already has plugins to send VICON or Optitrack transform messages to the Pixhawk.
In the worst case you have to change some configs (yaml files), but it should be fine.
If you have a 3DR Radiometry set you do not need an onboard computer, unless of course you need one for additional onboard applications. Refer for pixhawk companion computer for that (also in dev guide).
I used to use custom made app that gets mocap data, then transmits it via telemetry module (Xbee). It worked fine with versions 1.5.1 to 1.5.5 with LPE, but I had to increase the transmission frequency to 50Hz, which is weird. Usually 10Hz is enough, but I was getting ‘mocap timeout’ message very frequently.
The mavros solution, however, never worked for me. I mean, I can use the mocap mavros plugin to send mocap data, but always getting '‘mocap timeout’ message, no matter how I increase the frequency.
I have not tried v1.6.0 yet, or master. Maybe it’s fixed i latest master version.
Hi, I am doing the same tutotrial (fake gps), right now I have the following:
1.- The comunication between my windows pc and Ubuntu pc (ROS): I am using vrpn
2.- The communication between mavros and Iris drone: I am using two telemetry in the port (TELEM1) with boudrate 57600
In the pixhawk setup: I am usin the firmwere 1.5.5 and eneable the LPE estimator and mocap.
Mi problem is: When I am in the LPE parameters tab, i want disable barometer fusion and this option not appear, I can’t find LPE_FUSION in the QGC.
Master is the very latest branch, usually filled with the more experimental features that are not yet completely stable and suitable for reliable flight. This is what you clone directly from github.
If you follow the ‘Build the code’ part in the devguide you basically use that Firmware version 1.6.*
‘Flashing’ is the act of uploading the Firmware to the Pixhawk
Thanks for the help, your answers have helped me a lot, I have another question,
I am using vrpn to transmit the position data from motive (optitrack) to ROS, then the data of the node vrpn I have to send to mocap_pose_estimate plugin. my question is:
How to use the mocap_pose_estmate plugin?
When I start the mavros node and look in “rostopic list” I do not see topic mocap
I personally do not use the vrpn so I don’t know how that works. I use vicon_bridge package (VICON system) instead.
In terms of the plugin, the way the Mavros package works is that you launch the mavros node and it automatically loads a list of plugins and runs them in the background. This list of plugins can be configured with the mavros_plugins.xml file.
The mocap one should be in there by default, are you sure you don’t see the topic /mavros/mocap/pose?
What you need to do anyway is remap the Mocap data from the Optitrack to that same topic. This is what the plugin listens to.