Welcome to PhantomPilots.com

Sign up for a weekly email of the latest drone news & information

record accelerometer / gyro data?

Discussion in 'Phantom 2 Vision + Discussion' started by tonybarnhill, Oct 7, 2014.

  1. tonybarnhill

    Joined:
    May 24, 2014
    Messages:
    8
    Likes Received:
    0
    Hi,

    Aside from strapping on an Arduino with an accelerometer. is there any way to record the X and Z position (tilt) of the drone?

    Thanks!
     
  2. varmint

    Joined:
    Feb 5, 2014
    Messages:
    390
    Likes Received:
    6
    Location:
    Hillsboro, OR
    Three other choices depending on whether or not you need the data on the ground-end or the air-end.

    1) On the air end, you still need an Arduino, but you can capture the GPS/magnetometer/accelerometer data directly from the source rather than flying a dedicated breakout. There's a library for decoding the GPS/compass here: http://www.rcgroups.com/forums/showthread.php?t=1995704

    2A) On the ground-end it's more difficult, but far from impossible. You can disassemble the Android DJI app (not difficult) and find the pertinent data in one of the libraries. It's not encrypted. You can either extend the DJI app to output it to Bluetooth or something, or simply copy the libraries and compile your own app.

    2B) Another approach would be to log into the wireless A/P (port 2001 I believe, but you can verify here: viewtopic.php?f=27&t=17704) and try to decode the data stream directly. It may even use the same documented encoding on the ground-end that it uses on the air-end.

    All depends on your application, but it would help if I knew what the end-game was.
     
  3. DBS

    DBS

    Joined:
    Apr 6, 2014
    Messages:
    1,187
    Likes Received:
    163
    Location:
    Ft. Pierce, Florida
    the Vision + Utility Pro app has data logger and includes columns for Pitch, Roll, and Yaw... so some of that stuff is right there in the log file :ugeek:
     
  4. varmint

    Joined:
    Feb 5, 2014
    Messages:
    390
    Likes Received:
    6
    Location:
    Hillsboro, OR
    Depends what he wants to do. The options I propsed were for capturing and using realtime telemetry. Logged data is not particularly useful until after the fact, unless the logging includes a mechanism to broadcast it to other devices live.
     
  5. mmn

    mmn

    Joined:
    Aug 12, 2014
    Messages:
    144
    Likes Received:
    8
    Location:
    Fort Lauderdale, FL USA
    He does say "record" which kinda implies post-processing.