trust

  • ****
  • 301
More miniOPOSD issues
« on: November 06, 2020, 08:59:44 pm »
I bought several more of these units on ebay, have wired up two and tested both. They both do the same thing.
The basic characters display properly, but the special graphics come up all wrong.
I've tried every suggested firmware and the suggested charset. Same result
Any ideas?

Re: More miniOPOSD issues
« Reply #1 on: November 08, 2020, 04:03:47 am »
I have little experience with OSD problems, but you might try getting the firmware and char set from someone who has tested them together.

And make sure you follow char set and firmware update instructions exactly.  I vaguely remember there was something tricky about the char set update...  It looks like char set does not match firmware or maybe hardware.
« Last Edit: November 08, 2020, 04:35:29 am by TheOtherCliff »

trust

  • ****
  • 301
Re: More miniOPOSD issues
« Reply #2 on: November 08, 2020, 07:29:49 pm »
I am definitely able to update firmware, as trying different versions gets the battery voltage to show up or not depending on the firmware version.
I used this same tool on a previous OSD board and it seemed to configure properly - I did upload charset also, but I think it came with the correct one anyway so it didn't change.
But my guess is the charset is NOT updating.
I'm using the Arducam OSD Config 2.1.3.0.
I try to upload the Charset_1_3_0.mcm and it seems to do it.
I've checked the charset with a MAX viewer and it looks reasonable.
Can you remember the "special" method needed to upload the charsets?

Re: More miniOPOSD issues
« Reply #3 on: November 09, 2020, 01:31:09 am »
I never had these problems, so I am only remembering other people's problems.

There was something about needing both power voltages for the OSDs that had 12 and 5
or you had to do them in a certain order or ???

I would search the forum for words
   OSD firmware char
and look for matching charset / firmware download
or instructions

Here too is a wiki search for OSD:
https://librepilot.atlassian.net/wiki/search?text=osd

trust

  • ****
  • 301
Re: More miniOPOSD issues
« Reply #4 on: November 10, 2020, 07:53:20 am »
These units don't use 12v, only 5v. The other one I have works fine for the most part. I found I need to plug in the video first, then the 5v electronics - then everything usually powers up fine, although occasionally the OSD doesn't seem to overlay. Unplug/replug seems to fix it.
I saw several youtube videos of those using these and the same firmware, and were successful using the same procedures and firmware I used. I'm thinking the units are not able to flash the char memory, or it's ROM not EEPROM.
Can you recommend a source you know that sells fully programmable units?

Re: More miniOPOSD issues
« Reply #5 on: November 10, 2020, 12:16:46 pm »
Sorry no.  I bought a cheap batch on eBay years ago.  They were cheap because they apparently didn't have firmware on them.  I recall I got source code and compiled / flashed it.

trust

  • ****
  • 301
Re: More miniOPOSD issues
« Reply #6 on: November 19, 2020, 10:02:04 pm »
I bought two more from a different supplier, tested one and it works fine after uploading firmware and charset:

https://www.ebay.com/itm/MinimOSD-Mini-OSD-Module-KV-Team-MOD-for-Racing-F3-CC3D-Naze32-Flight-Controller

Re: More miniOPOSD issues
« Reply #7 on: November 19, 2020, 10:51:45 pm »
Do these look like the same kind as the "bad" ones?

Maybe you can try that charset, firmware and update method for your "bad" OSD to see if that can work?

trust

  • ****
  • 301
Re: More miniOPOSD issues
« Reply #8 on: November 20, 2020, 01:53:55 am »
The boards pinouts and size look identical. There are a few subtle differences in the components and layout on the boards. The Atmel part numbers look almost identical, but not exactly the same. The MAX7456 part number is hidden under a QC label on the new (work) parts. I think for some reason the code is not allowing me to update and change the charset. I used exactly the same procedure, and tried it on two parts - they both failed to change the charset, even though it appeared to allow it when running the app. I didn't check to see if the charset was already loaded properly on the new ones - I just updated the firmware and charsets, along with the layout data.
One minor annoyance - the battery input pin I'm using to monitor battery voltage is reading about 2V lower than it should be, so my battery low alarm appears way too quickly. I imagine there's a voltage divider resistor that is not correct or different.
I did note some resistor value differences on the different boards.

Re: More miniOPOSD issues
« Reply #9 on: November 20, 2020, 05:34:31 am »
It's been a while since I played with OSD, but there may be scaling factor (multiply) and offset (add) for the voltage, in the OSD setup.  I would guess these also exist in the OSD source code, but you are probably not interested in (simple) source code changes and building the OSD firmware.

jdl

  • ***
  • 246
Re: More miniOPOSD issues
« Reply #10 on: November 20, 2020, 01:20:38 pm »
...
Can you recommend a source you know that sells fully programmable units?

I've recently bought some from this store on AliExpress (at slightly lower price than at the moment) and expect them to arrive in the next 10 days. I'll test and report here...

https://www.aliexpress.com/item/33024383695.html?spm=a2g0s.12269583.0.0.1e193fc6nVWJmO
« Last Edit: November 20, 2020, 02:39:34 pm by jdl »

trust

  • ****
  • 301
Re: More miniOPOSD issues
« Reply #11 on: November 21, 2020, 03:22:16 am »
Yes, I'm interested in looking at and potentially compiling the source code. I've done quite a bit of coding over my life - over 2M lines of code. Mostly C/C++, but a huge amount of microcode, assembly - I basically coded on all the original microprocessors, and went on to design 8 different microcoded 3D real-time graphics machines - designed both the hardware and wrote all the code from microcode through OS and modeling GUI. Developed a  3D modeling and rendering system. More recently, designed 2 SLS 3D printers that use 100w IR lasers, scanners, steppers, 3 Rpi's to print in nylon and steel.
I use Eclipse to cross-compile.
Do you have the OSD source code or a link to it?

Re: More miniOPOSD issues
« Reply #12 on: November 21, 2020, 06:54:24 am »
Cool experience you have there.  :)  We should (all) swap stories.  ;)

Certainly there are some #defines in the source that would allow you to tweak the 2V offset you found.

First of all, the LP wiki which should be assumed correct if it says something different than I do:
https://librepilot.atlassian.net/wiki/spaces/LPDOC/pages/91947115/MWOSD+Setup

The following are my recollections about OSD and may be wrong.

MinimOSD is the OSD hardware we use.  The variant is Micro-MinimOSD (small square board with one voltage source) KV-Team (which as I recall started out as a few trace changes to bring out a couple A-D pins for voltage and current sensors).

MWOSD is the standard firmware inside the OSD.  It was designed to run with different FC firmware.  LibrePilot made source code changes to talk to it starting in 16.09.  It works fine on Revo class FCs.  It doesn't run on CC3D because of memory constraints although I recall that @f5soh made a version that did work.  You could probably disable some memory hog stuff and get it to work.  You can certainly redo some memory allocations (stack and heap) or disable some unused modules in the build to get it to work with CC3D.

MinOPOSD is a LibrePilot variant of MWOSD (firmware and configurator).  It talks native LibrePilot and doesn't require translation and works on Revo or on CC3D.

ShikOfTheRa/scarab-osd is the where MWOSD comes from.  ShikOfTheRa took it closed source and doesn't release full source code for free any more.  The MWOSD that we use is basically the free last version of ShikOfTheRa.  I went through the github repo and extracted what I think is the last free version 1.6.8.0.  I recall thinking that what I got this way was a little newer than the other MWOSD versions.  One concern is getting matching firmware and configurator versions.  The configurator underwent a source language change after 1.6.8.0.
https://github.com/ShikOfTheRa/scarab-osd

Here is an old thread with some good info:
https://forum.librepilot.org/index.php?topic=3926.0
« Last Edit: November 21, 2020, 07:12:16 am by TheOtherCliff »

jdl

  • ***
  • 246
Re: More miniOPOSD issues
« Reply #13 on: November 21, 2020, 03:56:53 pm »
It's been a while since I played with OSD, but there may be scaling factor (multiply) and offset (add) for the voltage, in the OSD setup.

FlightBatt.h
Code: [Select]
#define VOLT_DIV_RATIO    15.55                   // Vref 1.1V based: This is the start value for calibrating a 16k0/1k1 voltage divider usable up to 4s LiPo

// !!! for the +-50A Current Sensor(AC/DC) DFRobot SEN0098 we need approx. a 1/4 voltage divider 3k0/1k1 so that we stay below 1.1 V -> 2*50A * 0.04V/A / (4.1/1.1) = 1.073 V !!!
#define CURR_AMP_PER_VOLT 100.00 // Vref 1.1V based: This is the start value for calibrating a +-50A Current Sensor(AC/DC) DFRobot SEN0098 Sensitivity: 40 mV/A
#define CURR_AMPS_OFFSET  0.5000                  // Vref 1.1V based: This is the start value for calibrating a +-50A Current Sensor(AC/DC) DFRobot SEN0098 Sensitivity: 40 mV/A

#define CURRENT_VOLTAGE(x) ((x) * REF_VOLTAGE / 1024.0) * (volt_div_ratio / 100.0)
#define CURRENT_AMPS(x)    (((x) * REF_VOLTAGE / 1024.0) - (curr_amp_offset / 10000.0)) * (curr_amp_per_volt / 100.0)

No offset for voltage in MinOPOSD code, only for current sensor.
Proper calibration in the OSD Setup menu (enter by toggling to panel 3 while FC is disarmed) should be enough to get proper voltage readings.

https://librepilot.atlassian.net/wiki/spaces/LPDOC/pages/7274504/MinOPOSD+setup#MinOPOSDsetup-rc_setup_screen

jdl

  • ***
  • 246
Re: More miniOPOSD issues
« Reply #14 on: November 26, 2020, 03:24:06 pm »
These units don't use 12v, only 5v. The other one I have works fine for the most part. I found I need to plug in the video first, then the 5v electronics - then everything usually powers up fine, although occasionally the OSD doesn't seem to overlay. Unplug/replug seems to fix it.
I saw several youtube videos of those using these and the same firmware, and were successful using the same procedures and firmware I used. I'm thinking the units are not able to flash the char memory, or it's ROM not EEPROM.
Can you recommend a source you know that sells fully programmable units?

Here I found old thread with some advices:
https://www.dronetrest.com/t/minimosd-cant-see-osd-information-on-video/114/2

Quote
You might also want to try to update the CharSet - instructions here 134, take care to make sure the board is supplied with exactly 5V during update as it can be abit sensitive to that.

Defective and fuzzy chars are the result of a faulty character updating. Max7456’s internal memory is really picky about voltage level during a charset update. Usually it happens with some PCs with lower USB voltage. The only way to fix that is updating the charset by feeding the board properly. Just making sure it has around 5V there. E.g.: tying the two stages and feeding it by an external battery on the video IO pins.

I've also had recently a single occasion of charset update failure when OSD was only powered by USB power.

It might worth trying the charset update while OSD is powered with a clean and stable +5V, like from a linear regulator, e.g. 7805.

P.S. I'm waiting for recently ordered MicroMinimOSD boards to arrive. Will report if they update charset correctly when I get them!