Shop OBEX P1 Docs P2 Docs Learn Events
Propeller OSD Drone — Parallax Forums

Propeller OSD Drone

PerryPerry Posts: 253
edited 2008-04-10 11:44 in Propeller 1
GPS On Screen Drone


General Description



Heads up navigational display for model airplane enthusiasts.

Terry Hitt's video overlay driver combined with the propellers graphic engine allows the dynamic display of indicators, dials, and gauges for heads up presentation of GPS and accelerometer data.

The system updates a double buffered display 10 times per second. To further smooth the presentation an 8 pole moving average is kept of accelermoters, latitude, longitude, and elevation data.


A flashing spot indicates the position of the craft relative to start position.
When distance to home is greater than 49 meters a flashing line on the compass indicates heading to take to return to start position
When distince to home is greater than 499 meters the relative position is zoomed out 10x

The system consists of the following major parts

Parallax propeller proto board

LM1881 for controlling the video overlay as per Terry Hitts Propeller OSD

Hitachi H48C Tri-Axis Accelerometer Module Parallax #28026
accelerometers use the MCP3208 8 channel A/D driver MCP3208.
spin code: 'ok := accel.start(5,4,3,7)"

TTl GPS module like Parallax #28146
GPS is on the mouse port
serXmit = 25 ' Serial Transmit on mouse
serRecv = 24 ' Serial Receive on mouse
spin code: "ok := uart.start(serRecv,serXmit,0,4800)"

NTSC Video Camera

900MHz video TX / RX




Screen Display



from upper left you see

speedometer
number of satellites
Horizontal Dilution Of Position

artificial horizon

from upper right you see
altimeter

compass

at center is the airplane attitude display and flashing position spot

below is distance to home in meters
then latitude and longitude are displayed

at bottom line we find the date, GMT time, and elapsed time






Operational Timing

There are two jumpers to modify display parameters.
Jumper on I/O port 0 sets kpm/mph speedometer display
Jumper on I/O port 1 sets high/low speedometer display

After reset, durining the initial 11 seconds of operation the unit displays the jumper settings for km/mph and high/low speed settings, calculated values for meters per latitude and longitude.are shown below.

at the end of this time averages of the first 100 values of accelerometers, altitude, latitude and longitude are saved and the unit is ready for operation

you need at least 4 satellites in view for best operation, the more the better. I use a reset push button switch on a two wire cable plugged into the prop boards programing port and keep reseting the system until satisfied with the inital conditions.



Camera Aiming Decisions



Some notes on camera orientation

the view of the camera may be positioned in several ways,

for operation in a land vehical place airplane attitude display just below the true horizon, or place the true horizon on the artificial horizon gauge.

for best use in the air , place the true horizon near the top of the display,
use artificial horizon to maintain pitch and roll of craft when true horizon is invisible

I have uploaded a video to Youtube called "From Sparrows Park to Eagles Nest" taken from the front window of my car



I am not ready to release the full source yet, I am fishing for some one who wants to collarabate and produce this as a commercial product

The eeprom file is attached, if any one would like some modifications e-mail me at pjm@ridge-communications.ca and I will attempt to accomodate your request


Perry

Comments

  • Fred HawkinsFred Hawkins Posts: 997
    edited 2007-07-18 19:01
    beyond cool!

    Checking: http://maps.google.com/maps?f=q&hl=en&geocode=&q=n45+5.3941+w77+51.3860&ie=UTF8&z=12&iwloc=addr&om=1

    Post Edited (Fred Hawkins) : 7/18/2007 7:25:39 PM GMT
  • Paul_HPaul_H Posts: 85
    edited 2007-07-19 01:19
    Perry,

    That is FANTASTIC! and is far beyond what I am perpetually working on. You really know what you are doing!

    I know you are pursuing commercialization, so without giving away the secret sauce, can you say how much memory and cogs remain available? I'd definitely buy this if I could splice in extras - like servo control and navigation routines that could:

    - fly straight and level
    - fly a certain diameter, smooth circle around the current GPS coordinates (for aerial photography, etc)
    - come home (my personal favorite)
    - in autopilot mode, let the R/C control sticks run other servos than what they normally do (like pan and tilt a camera etc)

    Great work !
    Paul
  • PerryPerry Posts: 253
    edited 2007-07-19 01:41
    The code is very tight due to the double buffered video, it takes some radical deletion of unused code in other modules
    but having looked at your effort with R/C passthough for the propeller I think I could implement a return to home function on loss of signal. Thought about giving up on display without video input to do that.

    probably could implement those other functions as well. I don't know how much coding you have done but I find when a project is just about complete. there suddenly comes to me new ways to reduce code size and add functions.

    I have not actually flown the unit yet. My friend has some 10 year old planes with large wing spans that could easily lift the unit but has been slow getting his electronics back up to snuff.


    Perry

    Post Edited (Perry) : 7/19/2007 2:02:18 AM GMT
  • stampedstamped Posts: 68
    edited 2007-07-19 13:31
    This is really neat Perry! I am slowly working on some OSD code although not Prop powered. Your work with the Prop is quite an inspiration!
  • BeanBean Posts: 8,129
    edited 2007-07-19 16:11
    Perry,
    Really cool. I actually worked on something similar for a little while with Brian Carpenter. You might want to PM him to see if he is interested.
    If you can do it, create a black border around everything so the white overlay doesn't get washed-out in the light backgrounds.

    Bean.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Teacher: What is the difference between ignorance and apathy ?
    Student: I don't know and I don't care
    Teacher: Correct !
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    www.hittconsulting.com
    ·
  • RinksCustomsRinksCustoms Posts: 531
    edited 2007-07-19 16:16
    Beat me to it! Damn good work. I have an unfinished P-51 with an 8ft wingspan. Your an inspiration, i'd like to do something like this with a basic display and use a six axis gyro system for an automated T-rex heli, it has allt he aluminum & carbon fiber upgrades so i know the control can be precise

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    E3 = Thought

    http://folding.stanford.edu/·- Donating some CPU/GPU downtime just might lead to a cure for cancer! The average PC while browsing the internet typically uses less than 30% of it's potential, why not donate a portion of the rest for cancer resaerch?
  • PerryPerry Posts: 253
    edited 2007-08-03 18:51
    Here is the source for the Propeller On Screen Drone

    I have learned that the altitude on GPS's is not very reliable, going to have to add an atmospheric pressure sensor

    also beware some video cameras do not have enough signal to drive the display, probably need a voltage follower to make up for that.

    Have Fun

    Perry
  • Paul_HPaul_H Posts: 85
    edited 2007-08-22 20:35
    Perry,

    I was playing with your GPS_IO_mini (GPS NMEA reading code from your OSD Drone compilation) this afternoon found an easily correctable bug. I wanted to use the $GPRMC validation character in my code and now I can. It turns out that the stack space assigned to the GPS_IO_mini was too small and was gargling the beginning of the $GPRMC values. This was corrected by adding two more longs to the stack space in GPS_IO_mini. This worked fine in the GPS_IO_full code.
    'GPS_IO_mini.spin
    
    VAR
      long gps_stack[noparse][[/noparse]10]    ' increased from [noparse][[/noparse]8]
    
    
    



    This gives the input enough room to store the entire NMEA string from processing. Thanks again for the posts!
    Paul
  • PerryPerry Posts: 253
    edited 2007-08-28 18:46
    Thanks for the error checking Paul

    attached is my latest source, with 16 waypoints and 4 zoom levels

    there is a problem if you go too far from where you ar for waypoints though
    I think the spin square root or just my integer logic distance_t_ home can not go above 65000 meters

    Perry
  • sparkssparks Posts: 11
    edited 2007-10-09 07:00
    Hi Perry,
    On the return to home function you were thinking about adding. Can you get away with just a 3 axis accelerometer for wing leveling(ie pitch roll and yaw control)??(we use 3axis of thermopile sensor on the paparazzi project,ala FMA copilot). and other solutions use 2-3 axis of gyro + 3 axis of accelerometers and possibly 3 axis magnetometers in some cases. would love to see a wing leveling solution that could get away with using 3 axis accelerometers(I am speaking from ignorance here as I dont know if its even possible)?

    thanx again for releasing your source, I will be ordering the necessary accelerometer and sync chip and adding to my propeller proto board.and then trying on my new easy star FPV craft just for the instrument panel effect alone.


    sparks
  • sparkssparks Posts: 11
    edited 2007-10-09 07:03
    actually it was the right post, have ordered all the parts , had 2 propeller proto boards in stock but have thought about using the hitt consulting usb proto board instead,
    I am using an FMA copilot for a wing leveller, as to program size? program overlays from a serial memory device(eeprom or flash)?

    sparks
    ps will be attempting to develop this further for personal use with my FPV video project..

    Post Edited (sparks) : 10/24/2007 9:38:40 AM GMT
  • JimTheProgrammerJimTheProgrammer Posts: 44
    edited 2008-01-18 02:20
    Just outstanding! Has anyone gone to the same extent with a Helicopter?
  • PerryPerry Posts: 253
    edited 2008-01-22 02:01
    I see no reason why this project can not be used on a Helicopter, much of the time invested in the code was to smooth the artificial horizon display. It is intended for any machine in a reasonably open space . . . car, boat, plane or helicopter. Sadly it has actually not yet been flown. My friend who has the flight equipment I want to use has still been slow to actually get his equipment working. (they have been sitting unused for maybe 10 years) He has promised we could do something on a frozen lake this winter. I hoping to publish the final version then. One of the contentions he has is that the accelerometers will not produce the correct indications in flight.

    Perry
  • PerryPerry Posts: 253
    edited 2008-04-09 22:12
    On sunday we finally got to fly the OSD. It was a bit of a comedy as after getting the throttle servo replaced I was in such a rush to get off the ground that I installed OSD module backwards.

    The video was not as useful as hoped but I am posting a few snapshots from it.

    Focus was too short, taping camera to wing strut got too much jiggle ...

    Perry
  • Ron SutcliffeRon Sutcliffe Posts: 420
    edited 2008-04-10 01:15
    I modified the Mini_Gps_Mini object to provide for waypoint navigation.

    Others may find it useful.

    Ron



    Post Edited (Ron Sutcliffe) : 4/10/2008 1:25:25 AM GMT
  • PerryPerry Posts: 253
    edited 2008-04-10 02:56
    What GPS do you use Ron? Is it an inexpensive module?

    My code does it's own waypoints now. There are 7 hard-coded points and waypoint 0 is the reset location.

    Perry
  • Ron SutcliffeRon Sutcliffe Posts: 420
    edited 2008-04-10 04:28
    Perry
    Most of the hand held GPs units fully conform to NMEA 0183 rev 2.3 now

    $GPRMB and $GRXTE should always be transmitted to conform fully with 2.3
    and should update with the 2-sec time frame. The Garmin72 is a good example. Some of the sentences are turned off by default, so that the 2-sec update requirement can be maintained. The garmin72 manual, which you can down load explains this on Page 47 in small print.

    There are a few 2.3 USB GPS available now. They are tiny and inexpensive but I guess you would have to use a prop plug to interface it. I will try this when I get a chance. I think I can borrow one from another ship alongside.

    I would be very surprised if the Parallax GPS module did not transmit other NMEA sentences.
    It could be that the firmware disables these sentences.

    I have no experience with Aircraft Autopilots. Marine autoPilots and controllers is my bag.

    Your project looks Great.

    Ron
  • Ron SutcliffeRon Sutcliffe Posts: 420
    edited 2008-04-10 11:44
    Looks like you can't upload the current waypoint data to a general purpose USB GPS, seems it is only available on Marine Units.

    Hence no $GPRMB and sub-sets. That's a real pity. It leaves you with a lot
    work.

    Ron
Sign In or Register to comment.