-
-
Notifications
You must be signed in to change notification settings - Fork 115
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
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
- Loading branch information
1 parent
a631e0d
commit c58ea02
Showing
21 changed files
with
632 additions
and
25 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
#include "drivers/display_font_metadata.h" | ||
#include "drivers/osd.h" | ||
|
||
bool displayFontMetadataUpdateFromCharacter(displayFontMetadata_t *metadata, const osdCharacter_t *chr) | ||
{ | ||
if (chr && FONT_CHR_IS_METADATA(chr)) { | ||
metadata->version = chr->data[5]; | ||
return true; | ||
} | ||
return false; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
#pragma once | ||
|
||
#include <stdbool.h> | ||
#include <stdint.h> | ||
|
||
typedef struct osdCharacter_s osdCharacter_t; | ||
|
||
typedef struct displayFontMetadata_s { | ||
uint8_t version; | ||
uint16_t charCount; | ||
} displayFontMetadata_t; | ||
|
||
// 'I', 'N', 'A', 'V' | ||
#define FONT_CHR_IS_METADATA(chr) ((chr)->data[0] == 'I' && \ | ||
(chr)->data[1] == 'N' && \ | ||
(chr)->data[2] == 'A' && \ | ||
(chr)->data[3] == 'V') | ||
|
||
#define FONT_METADATA_CHR_INDEX 255 | ||
// Used for runtime detection of display drivers that might | ||
// support 256 or 512 characters. | ||
#define FONT_METADATA_CHR_INDEX_2ND_PAGE 256 | ||
|
||
bool displayFontMetadataUpdateFromCharacter(displayFontMetadata_t *metadata, const osdCharacter_t *chr); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.