mirror of
https://github.com/iNavFlight/inav.git
synced 2025-07-24 00:35:34 +03:00
MSP_OSD_CONFIG MSP frame implementation
This commit is contained in:
parent
d68e4c9d41
commit
0fd4bd7007
1 changed files with 19 additions and 0 deletions
|
@ -956,6 +956,25 @@ static bool mspFcProcessOutCommand(uint8_t cmdMSP, sbuf_t *dst, mspPostProcessFn
|
|||
serializeSDCardSummaryReply(dst);
|
||||
break;
|
||||
|
||||
case MSP_OSD_CONFIG:
|
||||
#ifdef OSD
|
||||
sbufWriteU8(dst, 1); // OSD supported
|
||||
// send video system (AUTO/PAL/NTSC)
|
||||
sbufWriteU8(dst, masterConfig.osdProfile.video_system);
|
||||
sbufWriteU8(dst, masterConfig.osdProfile.units);
|
||||
sbufWriteU8(dst, masterConfig.osdProfile.rssi_alarm);
|
||||
sbufWriteU16(dst, masterConfig.osdProfile.cap_alarm);
|
||||
sbufWriteU16(dst, masterConfig.osdProfile.time_alarm);
|
||||
sbufWriteU16(dst, masterConfig.osdProfile.alt_alarm);
|
||||
|
||||
for (uint8_t i = 0; i < OSD_ITEM_COUNT; i++) {
|
||||
sbufWriteU16(dst, masterConfig.osdProfile.item_pos[i]);
|
||||
}
|
||||
#else
|
||||
sbufWriteU8(dst, 0); // OSD not supported
|
||||
#endif
|
||||
break;
|
||||
|
||||
case MSP_BF_BUILD_INFO:
|
||||
sbufWriteData(dst, buildDate, 11); // MMM DD YYYY as ascii, MMM = Jan/Feb... etc
|
||||
sbufWriteU32(dst, 0); // future exp
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue