Quad HIL Simulation with XPlane

Hello all,

I'm trying to get the waypoint navigation in HIL simulation using XPlane, but not successful yet.....with the default HIL firmware and the config file "AC211r6_Xplane.param" available in the starter_pack, i observe the following:

- The quad rotor in xplane get a max throttle of 0.169, and does not take-off.....

- If i change the throttle gain (from default 10000 to smthng like 3000), quad rotor takes off, but does not switch mode to AUTO even after reaching very high altitudes...

The mission script that i run from Mission Planner is this:


print 'Start Script' # auto-lauch the AUTO mode for HIL test in Xplane v9.70 (JLN January 6, 2012)
Script.SendRC(1,1500,True) # roll
Script.SendRC(2,1500,True) # pitch
Script.SendRC(3,1000,True) # throttle
Script.SendRC(4,1500,True) # yaw
Script.SendRC(5,1933,True) # mode Stabilize - Mode 6



Script.SendRC(4,2000,True) # yaw right to arm the motors
Script.WaitFor('ARMING MOTORS',30000)
print 'Motors Armed!'


print 'Takeoff'
Script.SendRC(3,1700,True) # throttle up

Script.SendRC(5,1515,True) # set mode to AUTO- Mode 3


Any suggestions on how do i get the mode change to AUTO and waypoint navigation working in HIL...??

APM Sim Tab.jpg


APM Commnad Line.jpg

You need to be a member of diydrones to add comments!

Join diydrones

Email me when people reply –


  • Was a silly mistake......i was doing it without a GPS lock.....now i can change mode to AUTO....

    But the throttle problem remains....max throttle tht i get with RC channel 3 (max,min = 1885,1100) and sim throttle gain of 10000 are 0.180, which makes sense.....so i change throttle gain to 3000, and quad takes off fine with mission script (new throttle in XPlane = 1885/3000 = 0.628)....

    However, whenever it encounters mode change command to AUTO in mission script, it just keeps coming down, until it crashes.....throttle value show the same (no reduction) in mission planner and XPlane....i've tried them with different home altitudes with only one command in AUTO mission: takeoff to certain altitude....but same thing happens always....the usual waypoint nav too responds the same...

    Any suggestions or ideas on what am I doing wrong here....??

This reply was deleted.