Rotary encoder refactoring
This commit is contained in:
@@ -856,22 +856,6 @@ void drawShortTrimMode(coord_t x, coord_t y, uint8_t fm, uint8_t idx, LcdFlags a
|
||||
}
|
||||
}
|
||||
|
||||
#if ROTARY_ENCODERS > 0
|
||||
void putsRotaryEncoderMode(coord_t x, coord_t y, uint8_t phase, uint8_t idx, LcdFlags att)
|
||||
{
|
||||
int16_t v = flightModeAddress(phase)->rotaryEncoders[idx];
|
||||
|
||||
if (v > ROTARY_ENCODER_MAX) {
|
||||
uint8_t p = v - ROTARY_ENCODER_MAX - 1;
|
||||
if (p >= phase) p++;
|
||||
lcdDrawChar(x, y, '0'+p, att);
|
||||
}
|
||||
else {
|
||||
lcdDrawChar(x, y, 'a'+idx, att);
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
void drawValueWithUnit(coord_t x, coord_t y, lcdint_t val, uint8_t unit, LcdFlags att)
|
||||
{
|
||||
// convertUnit(val, unit);
|
||||
|
||||
Reference in New Issue
Block a user