currently we are trying to send some Mavlink commands to the FC from a python script, but only few of them seem to work. We use the PX4 flight stack and pymavlink library (the dronekit library provides the same bad result). Maybe you could give us a hint, why these commands don't work.
We discovered that four commands work well:
1. Arming and disarming motors:
2. Taking off:
self.mav.mav.command_long_send(self.mav.target_system, self.mav.target_component, mavutil.mavlink.MAV_CMD_NAV_LAND,0,0,0,0,0,self.home_position,self.home_position,0)
Following commands seem not to work – they will be just ignored by the FC after taking off and reaching the target altitude:
- 4. Yaw to a given angle, different commands were tested:
- self.mav.mav.command_long_send(self.mav.target_system, self.mav.target_component,mavutil.mavlink.MAV_CMD_CONDITION_YAW,0,heading,0,0,0,0,0,0)
- self.mav.mav.set_attitude_target_encode(0,self.mav.target_system,self.mav.target_component,0b00000100,self.to_quaternion(roll_angle, pitch_angle, yaw_angle),0,0,yaw_rate,thrust)
- 5. Velocity command:
- self.mav.mav.set_position_target_local_ned_encode(0,0,0,mavutil.mavlink.MAV_FRAME_LOCAL_NED,0b0000111111000111,0,0,0, velocity_x,velocity_y,velocity_z,0,0,0,0,0)
- 6. Waypoint command:
The copter loiters on the same spot while performing these commands (4 - 6). Also, we tested corresponding commands with the dronekit library on Yocto and Ubuntu with the same negative result. During the trials we have set the copter to different flight modes via RC – MANUAL, ALTITUDE, POSITON, OFFBOARD… None of these solutions could help. Currently we are working with:
BIOS_VERSION = Aero-01.00.13
OS_VERSION = Poky Aero (Intel Aero Linux Distro) 1.6.1 (pyro)"
AIRMAP_VERSION = 1.8
FPGA_VERSION = 0xc2
AeroFC firmware version = 1.6.5
Thank you for your interest in the Intel Aero drone.
In order to better investigate this issue can you try send the drone commands using Mavproxy?
Here is the guide for Mavproxy: https://github.com/intel-aero/meta-intel-aero/wiki/04-Autonomous-drone-programming-in-Python# hello-world-in-pymavproxy
Please let us know what your results are.
Also I would suggest you to update your Bios to the latest version: https://github.com/intel-aero/meta-intel-aero/wiki/90-(References)-OS-user-Installation# bios
Hope this helps.