-
-
Notifications
You must be signed in to change notification settings - Fork 115
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Import HDZero OSD Driver from iNav #775
Conversation
uint16_t charCount; | ||
} displayFontMetadata_t; | ||
|
||
// 'I', 'N', 'A', 'V' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@saidinesh5 , what is the purpose of this section? with "INAV"
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I had to include this for availing displayFontMetadata_t
this one function (which is used nowhere). Originally I wanted to keep this osd driver as close to the inav version as possible to minimize the headaches when updating, but I am beginning to think that we don't have to worry about that right now because we have a lot of code that is useless currently.
static bool getFontMetadata(displayFontMetadata_t *metadata, const displayPort_t *displayPort)
{
UNUSED(displayPort);
metadata->charCount = 512;
metadata->version = FONT_VERSION;
return true;
}
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
i believe, this will need to be EMUF for hdzero font EMUF_000.bmp
. not validated yet.
nope. it was elsewhere.
This comment was marked as outdated.
This comment was marked as outdated.
|
258f073
to
669f265
Compare
Mostly from https://github.com/iNavFlight/inav/pull/7668/files commit Notable changes: * And added missing functions to bitarray.h/.c, msp_serial.h/.c * Used "drivers/max7456_symbols.h" instead of "drivers/osd_symbols.h" * Used baudRates[portConfig->msp_baudrateIndex] instead of baudRates[portConfig->peripheral_baudrateIndex] Additional changes: serial: serialPortFunction_e now needs 32 bits How to use: In CLI, Set FUNCTION_HDZERO_OSD to the appropriate serial port: Eg. Assuming to use serial port 4, enter the following CLI commands to enable FUNCTION_HDZERO_OSD in EmuFlight Configurator 3.0.1: serial 3 65536 115200 115200 0 115200 save
This is because we changed the size of serialPortConfig_s.functionMask TODO: Add the peripheral_baudrateIndex entry to serialPortConfig_s ?
As per geoffsim, the HDZero VTX hardcodes thE baudrate at 115200. So No point making this configurable in EmuFlight As of now. We can bring back the configurability later on if needed
Emuflight does not implement vtx tables and that causes corruption on certain hdzero firmware. Everything seems smooth as Buttercake
b764ad6
to
9f09225
Compare
I assume this will then also work with https://github.com/fpv-wtf/msp-osd ? |
unknown; needs to be tested. Here are the HDZero builds:
we request report/feedback on results. edit: WTF.OS works, but need to set as PAL to align correctly. |
I think we need to fix the OSD canvas size because DJI goggles only support SD resolution. |
@saidinesh5 , can you rebase on |
This needs work. I plan to take ownership. I really want to avoid MSP change for the uint32. betaflight stayed uint16. edit: uint32 is fine. OSD bits will be reverted to 5bit, thanks to BF; #958 |
005d43d
to
e6aab0f
Compare
Mostly from https://github.com/iNavFlight/inav/pull/7668/files commit
Notable changes:
baudRates[portConfig->peripheral_baudrateIndex]
Additional changes:
How to use:
In CLI, Set FUNCTION_HDZERO_OSD to the appropriate serial port:
Eg. Assuming to use serial port 4, enter the following CLI commands to
enable FUNCTION_HDZERO_OSD in EmuFlight Configurator's CLI:
REQUIRES HDZero firmware Rev 11062022 or later, otherwise older firmware will be a corruption issue in EmuFlight due to VTX-Tables "BackPack"
Known quirks to be attended before ready for
master
:osd_crosshairs_pos = 2253
notosd_crosshairs_pos = 8589
. Desire to be backward-compat and/or intercept layer for DJI.Closes #700