-
Notifications
You must be signed in to change notification settings - Fork 1.5k
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
Osd custom #9508
Osd custom #9508
Conversation
3c5a67b
to
c201a4d
Compare
https://youtu.be/BqkDo-2O7js?si=yss03OEfJrJPk7TY&t=28 tested outside and it works really nice. If it's aremed and altitude is below 15m, then on OSD is text "!GROUND! [atlitude_number][altitude_icon]" it programmed in inav programming framework. I fixed some minor bugs and allowed more chars for text [^A-Z0-9!.\* ] Maybe would be nice to add posibility to set blinking text. And connect vidibility to logic condition instead of GV |
670434e
to
0f212ff
Compare
A small improvement.
|
faf40f8
to
24b280a
Compare
@error414 please resolve conflicts I will want to merge and build the release ASAP |
I see Pawel is merging this, which is great because it looks like it could be very useful. Maybe with a couple examples as screenshots. |
@sensei-hacker Its done - https://github.com/iNavFlight/inav/wiki/OSD-custom-messages |
Hi,
Description
As i talked here #9497 I implemented OSD custom elements for INAV.
It's designed mainly for cooperation with programing framework, without programming framework it does not make sense.
In default are there 3 custom osd elements with three part plus visibility settings. Each part can be set to:
none don't use that part
text show text (for save memory can be set as "text" only one part of element), max 15 chars [A-Z0-9]
icon static user select icon which he wants to show
icon gv icon is driven by global variable value
gv shows global variable value
Visibility can be show only to
gv driven by global variable 0 = hidden , x > 0 = showed
always it's clear :)
Here is demo from development. https://www.youtube.com/watch?v=LKFFJfYywM4


Custom elements are in "Global variables" section in OSD tab, because custom osd elements are higtly connected to programming framework. I can change in.
If this PR will be merged then global variables and Switch Indicator Settings can be removed because these elements can be easily replaced by custom elements.
Code
I tried to folow INAV standarts and use same programming style as it's used in inav, but still please go throught code carefully and check it properly. I'm not sure about saving char array in cli. In the cli.c is hardcoded number of part for custom elements, I did not know how to do dynamically. Maybe not worth to do dynamically.
And next whether it's good uidea to use separated file for custom OSD elements.
Configurator
PR for configurator: iNavFlight/inav-configurator#1901