Want to test code with the simulator X-Plane?

Here's an example of how to get data from the simulator: http://gist.github.com/228998It has everything you need to treat it as a virtual IMU. This was instrumental in getting my extended Kalman filter running (to be open sourced soonish) and I hope you find it useful too!(I'll do an updated version that shows you how to control the plane in X-Plane from your code.)

E-mail me when people leave their comments –

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

Join diydrones


  • In the example code I'm grabbing the gyros, accelerometers, indicated airspeed, altitude, lat/long and heading. You can read a lot more data if you want (I'm taking probably 1% of the data available for access from X-Plane). Download the demo and go to the input/output menu to see what's available.

    I would recommend reading the comments in the code. I actually spent some time explaining what's going on…
  • Nice work, what data in/out settings have you got in xplane?
This reply was deleted.