mirror of
https://github.com/opentx/opentx.git
synced 2025-07-18 22:05:10 +03:00
Some reserve in telemetry sources added
This commit is contained in:
parent
a47ac42996
commit
7e43a88d3f
6 changed files with 127 additions and 63 deletions
|
@ -1815,7 +1815,7 @@ enum FlightModesItems {
|
|||
ITEM_PHASES_LAST = ITEM_PHASES_COUNT-1
|
||||
};
|
||||
|
||||
bool isTrimModeAvailable(int16_t mode)
|
||||
bool isTrimModeAvailable(int mode)
|
||||
{
|
||||
return (mode == TRIM_MODE_NONE || (mode%2) == 0 || (mode/2) != (m_posVert-1));
|
||||
}
|
||||
|
@ -5738,7 +5738,7 @@ void menuModelTelemetry(uint8_t event)
|
|||
if (attr && (s_editMode>0 || p1valdiff)) {
|
||||
switch (m_posHorz) {
|
||||
case 0:
|
||||
bar.source = checkIncDecModel(event, barSource, 0, TELEM_DISPLAY_MAX);
|
||||
bar.source = CHECK_INCDEC_MODELVAR_ZERO_CHECK(event, barSource, TELEM_DISPLAY_MAX, isTelemetrySourceAvailable);
|
||||
if (checkIncDec_Ret) {
|
||||
bar.barMin = 0;
|
||||
bar.barMax = 255 - maxBarTelemValue(bar.source);
|
||||
|
@ -5766,7 +5766,7 @@ void menuModelTelemetry(uint8_t event)
|
|||
#endif
|
||||
lcd_putsiAtt(pos[c], y, STR_VTELEMCHNS, value, cellAttr);
|
||||
if (cellAttr && (s_editMode>0 || p1valdiff)) {
|
||||
CHECK_INCDEC_MODELVAR_ZERO(event, value, (lineIndex==3 && c==0) ? TELEM_STATUS_MAX : TELEM_DISPLAY_MAX);
|
||||
CHECK_INCDEC_MODELVAR_ZERO_CHECK(event, value, (lineIndex==3 && c==0) ? TELEM_STATUS_MAX : TELEM_DISPLAY_MAX, isTelemetrySourceAvailable);
|
||||
}
|
||||
}
|
||||
if (attr && m_posHorz == NUM_LINE_ITEMS) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue