Hello guest, if you read this it means you are not registered. Click here to register in a few simple steps, you will enjoy all features of our Forum.
This forum uses cookies
This forum makes use of cookies to store your login information if you are registered, and your last visit if you are not. Cookies are small text documents stored on your computer; the cookies set by this forum can only be used on this website and pose no security risk. Cookies on this forum also track the specific topics you have read and when you last read them. Please confirm whether you accept or reject these cookies being set.

A cookie will be stored in your browser regardless of choice to prevent you being asked this question again. You will be able to change your cookie settings at any time using the link in the footer.

Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Diatone SP3 VTX OSD kv mod for Raceflight
#1
That VTX/OSD combo is pretty much perfect - Grisha0 has already reviewed it here, so I won’t bother Wink

I had only one issue with this thing - it is unable to read battery voltage directly, only trough MSP, which in turn doesn’t work on Raceflight beta builds. The result on my build:

[Image: go849A7l.png]

That is a design decision - Diatone makes them to be used in their own builds, where they get power from a regulated source. Ok, I get that, time to hack ^^

Since OSD on board is basically an Atmega powered system, I have figured that the chips pinout has to be configured somewhere inside the MWOSD code. Here it is:

Code:
#ifdef SWAPVOLTAGEPINS                     
    #define VOLTAGEPIN    A2
    #define VIDVOLTAGEPIN A0
#else                                  
    #define VOLTAGEPIN    A0
    #define VIDVOLTAGEPIN A2
#endif

So basically, we can have live voltage reading taken either from analog pin 0 or 2. I have chosen A0. Because reasons Wink

Here is this chips pinout:

[Image: 4uyijxgl.png]

full sizesource

Pin A0 on this VTX is driven to the ground by a 1k resistor to always show 0V.

[Image: gT1WCcdl.jpg]

We have to remove that resistor and solder on a piece of wire either directly to an Atmega pin or a conveniently bigger resistors soldering pad. Guess which I have chosen ;p

Ok now, we shouldn’t deliver 4S voltage to an Atmega or else it will read gibberish. It has to be in range from 0 to 1.2V and then it can be calibrated through the MWOSD GUI. We have to make a voltage divider of some sort - I have made a resistor type divider here.

After countless minutes of calculating resistance values I figured: duh… I am making a KV mod here… Those are required resistor values:

[Image: sF6eIdul.png]

source

Of course I didn’t have a 1.5kOhm resistor. I have scavenged a very similar SMD components from an old board I had laying around. Reuse what you can guys.

They are so tiny - I have lost 2 during soldering Wink

[Image: qeqKspxl.jpg]

[Image: so0VsX4l.jpg]

Connect loose ends with another wire and your voltage divider is ready to be soldered onto the board:

[Image: 4svhI0yl.jpg]

Use some hot glue to secure it in place.

Afterthought: I could just replace old 1kOhm with a 1.5kOhm since it was grounded anyway and just drive a wire with a 22kOhm one to the same pad/leg - this way I would have only one wire flying around the board.

Since those resistors have slightly different values than “original” kvmod ones, they have also a bit different readings depending on voltage applied:

2s 7.7v reads as 7.4
3s 10.9 reads as 10.8
4s 15.05v reads as 15.0
4s 16.45v reads as 16.4

Perfect for my 4S needs.

BTW, live voltage reading seems to refresh more frequently than MSP driven solution:

Find me on Youtube and Instagram. I currently fly: DRC Aura, NOX5R, Minimalist 112 and drive a scrap RC car
[-] The following 4 users Like KonradS's post:
  • fftunes, Oscar, unseen, sloscotty
Reply
Login to remove this ad | Register Here
#2
Brave hack Konrad!! (and nice flying too) Big Grin
Reply
#3
awesome Big Grin kind of off topics, is it possible to get your version of the intro? love that quad shadow Big Grin LOL
Don't be a LOS'er, be an FPV'er :)  My Gear - Facebook - Instagram - Twitter
Reply
#4
(02-Apr-2017, 09:08 PM)Oscar Wrote: awesome Big Grin kind of off topics, is it possible to get your version of the intro? love that quad shadow Big Grin LOL

Sure mate, sent via wetransfer
Kudos to Grisha for some brave hovering Wink
Find me on Youtube and Instagram. I currently fly: DRC Aura, NOX5R, Minimalist 112 and drive a scrap RC car
Reply


Possibly Related Threads...
Thread Author Replies Views Last Post
  Tutorial Diatone ESC and Matek FC connection Cat_in_pants 4 454 05-Jul-2023, 09:05 PM
Last Post: Cat_in_pants
  <2g GPS Mod - Ultra-lightweight GPS! V-22 18 3,995 28-Feb-2023, 12:00 PM
Last Post: hugnosed_bat
  Tutorial FlySky i6X mod more than 4 switches psicho100pro 2 1,409 02-Jan-2023, 09:34 AM
Last Post: notsopilot
  ImmersionRC Ghost and non ImmersionRC VTX controls Badbaddad 9 750 07-Nov-2022, 01:31 AM
Last Post: Rob3ddd
  Goggles (Ask) Bad video image when mod irc rapidfire to ev800dm rendyha 1 462 15-Jun-2022, 02:42 PM
Last Post: kafie1980


Login to remove this ad | Register Here