3D Robotics

Best way to simulate a UAV flight?

While it's cold and windy outside, the best way to test our UAVs may be simulations. As best as I can tell there are at least two ways to do this, but I can't say I really understand either of them well enough to implement:

  1. Generate synthetic GPS data with your PC's serial port, see what the autopilot does as a result. Here's a GPS NEMA sentence generator. The fake course data can be plotted in Google Earth. This is just for navigation, of course.
  2. Generate synthetic GPS and IMU sensor reading, and display the autopilot responses in a flight simulator. Curtis Olson, the creator of FlightGear (open source flight simulator) does that with his UAVs. No idea how. Impressive, though...

Has anyone tried either of these? Something else? Can you tell us how to do it?


E-mail me when people leave their comments –

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

Join diydrones

Comments

  • 3D Robotics
    Harrison,

    Yes, that's right. I discovered that work-around shortly after that comment. Thanks for correcting the record.
  • I realize this is a pretty old topic but I wanted to comment on Chris Anderson's post:
    "Unfortunately I can't use the Sailsoft one (GPSSIML) because it only supports com ports 1-4. Like most people with laptops, I don't have a dedicated serial port, so I use a driver to send serial over USB instead. The driver assigns this to a higher port (between 8 and 10). Do you know of any other sim programs that might work on those ports?"

    I've enountered the same problem before and up until a month ago I was always dissapointed when any program I enocunter only allowed a few select serial ports. I've actually found a way around this: You can change which port a USB2Serial adapter apears to be. If you right click on My Computer -> Properties -> Device Manager -> Select Your USB2Serial(UNDER PORTS) -> Right Click -> Properties -> Port Settings -> Advanced -> Com Port Number And then adjust that however you want!
  • Most people who dont try this use what i call "trial and error" but mostly error.
  • Developer
    Paul you can download a Virtual Serial port Driver from Eltima, to create a virtual port (like COM1) and connect it (virtually) to COM8.
    Hey Chris i used that program to simulate the GPS waypoint navigation for Arduino, i even have a Video. (is in spanish, but you can see), to convert the r232 signal to TLL i used a 7404 from TI. Check the pictures and the video here:
    http://gizmobits.com/arduino/gps/

    Another great trick is the GPSout plugin for FlightSimulator 2004, output NMEA sentences to serial port, to conect any device:
    http://www.schiratti.com/
    files/dowson/GPSout.zip

    http://gizmobits.com/
    wp-content/uploads/2007/12/foto2.jpg

    My problem is, i don't know how to output the pitch and roll from FS2004. =( But i can control the airplane using PPM signals connected to PC using a milehighwings cable.
    http://gizmobits.com/arduino/gps/Another
  • 3D Robotics
    Paul,

    Unfortunately I can't use the Sailsoft one (GPSSIML) because it only supports com ports 1-4. Like most people with laptops, I don't have a dedicated serial port, so I use a driver to send serial over USB instead. The driver assigns this to a higher port (between 8 and 10). Do you know of any other sim programs that might work on those ports?
  • Chris,

    I use the sailsoft freeware program with good success. It generates any of these six different NMEA strings at 1-59 second intervals:

    $GPGLL
    $GPRMC
    $GPVTG
    $GPZDA
    $GPGGA
    $GPGSA

    I use GGA and RMC for my project to get the basics (Lat, Lon, Alt, date, time, etc) I run a serial cable to my prototype board to pass the receive only signal.

    On a 9pin D-connector (standard serial cable) I use pin 5 for ground and pin 3 for the GPS data. No other pins are needed as the program is free running / a one way communication.

    It works great for my needs.
    Paul
This reply was deleted.