Jump to content


Dragon OSD+v2 and CopterControl

dosd coptercontrol

  • Please log in to reply
27 replies to this topic

#21 dankers

dankers

    Janitor

  • Administrators
  • 5124 posts
  • Country: flag of Australia Australia


Posted 28 January 2012 - 03:24 AM

I think that is fantastic! Cleaver use of the bridge board.

The next challenge is to write a CC firmware module that talks over the Flexi port to the D-OSD, it would basically read UAVOject values such as attitude and pass them along via I2C in the D-OSD protocol. I guess you know this, just a thought.

#22 Reddog

Reddog

    UI Manager

  • Members
  • PipPipPip
  • 1200 posts
  • Country: flag of Australia Australia


Posted 28 January 2012 - 09:06 AM

View PostLukeB, on 28 January 2012 - 02:27 AM, said:

Sure here's a link to the source code. https://bitbucket.or...b2208/osdbridge

It runs on an Arduino Pro Mini (3.3v ATMega 328).  You'll need to connect the tx, rx, ground and power pins to the telemetry port on the CC. The Arduino is then connected to the dragon OSD i2c.

I checked it again this morning and it works with the code attached. I hope it's of some use to you, let me know if you have any questions.

Thanks for putting up your code, much appreciated!

I am only new to hardware programming - the pinnacle of my career so far is getting an Arduino Mega with LCD shield and GPS to show Lat and Long values. I would like to parse UAVObject information sent from CC via an Xbee and receive on my Mega via an Xbee then pull out GPS location and attitude for it. I was wondering if you could point me to the part of your code where you are only pulling out the information you want from UAVObjects?

I would also like to understand why you chose the 3.3 Arduino Pro Min instead of the 5v Arduino Pro Mini?

#23 LukeB

LukeB

    New Member

  • Members
  • Pip
  • 7 posts
  • Country: flag of Singapore Singapore

Posted 29 January 2012 - 04:40 AM

The main reason for the 3.3v board was that I had one lying around already. Also I believe the DOSD uses 3.3v i2c but could be wrong. I remember seeing it somewhere but I just had a quick look and couldn't find the reference. It may still work with 5v but I'm not sure on this.

The sendAttitudeRequest function requested the attitude UAVObject from CC and the processMessage function parses the UAVObject response. I do recall seeing somewhere in the forum that someone has written an something a bit more complete for parsing UAVObjects for the Arduino. That's probably a better place to start than my code as I've just done it quick and dirty for this specific purpose. The other thing to note is that if the object id or structure of the attitude UAVObject change my code will break as I've hard coded these values.

#24 Reddog

Reddog

    UI Manager

  • Members
  • PipPipPip
  • 1200 posts
  • Country: flag of Australia Australia


Posted 30 January 2012 - 06:02 AM

View PostLukeB, on 29 January 2012 - 04:40 AM, said:

The main reason for the 3.3v board was that I had one lying around already. Also I believe the DOSD uses 3.3v i2c but could be wrong. I remember seeing it somewhere but I just had a quick look and couldn't find the reference. It may still work with 5v but I'm not sure on this.

The sendAttitudeRequest function requested the attitude UAVObject from CC and the processMessage function parses the UAVObject response. I do recall seeing somewhere in the forum that someone has written an something a bit more complete for parsing UAVObjects for the Arduino. That's probably a better place to start than my code as I've just done it quick and dirty for this specific purpose. The other thing to note is that if the object id or structure of the attitude UAVObject change my code will break as I've hard coded these values.

Thanks mate.

#25 z-axis

z-axis

    Key Member

  • Members
  • PipPipPip
  • 709 posts
  • LocationHouston, TX
  • Country: flag of United States United States


Posted 31 January 2012 - 08:35 PM

View PostLukeB, on 29 January 2012 - 04:40 AM, said:

The main reason for the 3.3v board was that I had one lying around already. Also I believe the DOSD uses 3.3v i2c but could be wrong. I remember seeing it somewhere but I just had a quick look and couldn't find the reference. It may still work with 5v but I'm not sure on this.

It is 3.3V : Page 11

Very nice work, I might have to do ths as well!

#26 z-axis

z-axis

    Key Member

  • Members
  • PipPipPip
  • 709 posts
  • LocationHouston, TX
  • Country: flag of United States United States


Posted 31 January 2012 - 08:39 PM

View PostLukeB, on 28 January 2012 - 02:27 AM, said:

Sure here's a link to the source code. https://bitbucket.or...b2208/osdbridge

It runs on an Arduino Pro Mini (3.3v ATMega 328).  You'll need to connect the tx, rx, ground and power pins to the telemetry port on the CC. The Arduino is then connected to the dragon OSD i2c.

I checked it again this morning and it works with the code attached. I hope it's of some use to you, let me know if you have any questions.

What Objects does it get? Will it also pass GPS through to the DOSD?

#27 LukeB

LukeB

    New Member

  • Members
  • Pip
  • 7 posts
  • Country: flag of Singapore Singapore

Posted 01 February 2012 - 12:19 AM

Just the Attitude object.

No it doesn't pass through the GPS to the DOSD. It would be nice to but their firmware sources the barometer and imu data via i2c, and I assume their GPS data is via a serial protocol of some sort.

#28 Markeydoo

Markeydoo

    New Member

  • Members
  • Pip
  • 8 posts
  • Country: flag of United States United States

Posted 24 February 2012 - 07:06 PM

Luke
Could you post pictures and parts you used also? A connectivity diagram would also be nice.
Thanks