mirror of
https://github.com/opentx/opentx.git
synced 2025-07-19 14:25:11 +03:00
Missing change in old telemetry protocol for #534
FAS offset range increased to +/-12A. Was initially limited to +/-1.5A to use only 5 bits, but later changes gave it a whole 8bit int.
This commit is contained in:
parent
30a457234e
commit
95f7dbf102
2 changed files with 2 additions and 2 deletions
|
@ -5620,7 +5620,7 @@ void menuModelTelemetry(uint8_t event)
|
|||
lcd_outdezAtt(TELEM_COL2, y, g_model.frsky.fasOffset, attr|LEFT|PREC1);
|
||||
lcd_outdezAtt(TELEM_COL2+6*FW, y, frskyData.hub.current, LEFT|PREC1);
|
||||
lcd_putc(TELEM_COL2+8*FW, y, 'A');
|
||||
if (attr) g_model.frsky.fasOffset = checkIncDec(event, g_model.frsky.fasOffset, -15, 15, EE_MODEL);
|
||||
if (attr) g_model.frsky.fasOffset = checkIncDec(event, g_model.frsky.fasOffset, -120, 120, EE_MODEL);
|
||||
break;
|
||||
#endif
|
||||
|
||||
|
|
|
@ -192,7 +192,7 @@ void parseTelemHubByte(uint8_t byte)
|
|||
|
||||
case offsetof(FrskySerialData, current):
|
||||
#if defined(FAS_OFFSET) || !defined(CPUM64)
|
||||
if(((int16_t)frskyData.hub.current + g_model.frsky.fasOffset)>0)
|
||||
if ((int16_t)frskyData.hub.current > 0 && ((int16_t)frskyData.hub.current + g_model.frsky.fasOffset) > 0)
|
||||
frskyData.hub.current += g_model.frsky.fasOffset;
|
||||
else
|
||||
frskyData.hub.current = 0;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue