* Snapdragon Flight with Qualcomm image 3.1.3
* Mavros Kinetic
* PX4/Firmware branch global_to_local (keeps PX4 from treating lack of GPS as lack of position for certain modes)
* Qualcomm VISLAM altered to operate with mavros
I'm attempting to use mavros' setpoint_raw topic to launch the vehicle upward and then set it to loiter in its current position once it reaches height. I perform these behaviors by setting the type_mask field of the PositionTarget message to
0x1000 | 0b110111000011 for takeoff. It instructs PX4 to ignore XY position, XYZ accel, and yaw_[rate] properties. In simulation, the vehicle takes off almost straight up and then drifts slightly at height-- no loiter mode is even needed in this case. During actual flight, the vehicle takes off at an angle and continues to move forward at a decent speed (0.3m/s perhaps) without stopping. See it here. I kill it at the end.
Next, I tried setting the type_mask to loiter with value
0x3000 | (1 << 1) | (7 << 6) | (7 << 3) (the loiter mask ORed with the default value used in mavlink for a standard setpoint command) once the vehicle had been in the air for a couple seconds. It did not seem to attempt to stop.
So here are some questions:
1. Am I invoking the wrong takeoff function? Is PX4 trying to launch my quadcopter like a fixed wing vehicle?
2. If I'm invoking the correct takeoff function, how do I make the takeoff vertical?
3. VISLAM sends its calculated position (it does calculate a position) to
mavros/vision_pose/pose_cov. Should I be seeing a position coming back from PX4 at the mavros topic
/mavros/local_position/pose topic? Nothing is published there.
4. Which bits of configuration or settings should I check to ensure that takeoff and loiter work properly?
Thanks for your help.