3djc/x7 draw timer (#4764)
* Use drawText with tiem string like x12s. Change font ':' which where way to large for SMLSIZE * MIDSIZE ':' lower dot was not horizontaly symetrical, moving it up one pixel * Make it all ARM * Let's try not to brake timer adjust * Fix
This commit is contained in:
Binary file not shown.
|
Before Width: | Height: | Size: 755 B After Width: | Height: | Size: 762 B |
Binary file not shown.
|
Before Width: | Height: | Size: 1003 B After Width: | Height: | Size: 1.3 KiB |
@@ -815,7 +815,7 @@ void drawTimer(coord_t x, coord_t y, putstime_t tme, LcdFlags att, LcdFlags att2
|
|||||||
#endif
|
#endif
|
||||||
lcdDrawNumber(x, y, qr.quot, att|LEADING0|LEFT, 2);
|
lcdDrawNumber(x, y, qr.quot, att|LEADING0|LEFT, 2);
|
||||||
#if defined(CPUARM)
|
#if defined(CPUARM)
|
||||||
if (att & MIDSIZE) {
|
if (FONTSIZE(att) == MIDSIZE) {
|
||||||
lcdLastRightPos--;
|
lcdLastRightPos--;
|
||||||
}
|
}
|
||||||
if (separator == CHR_HOUR)
|
if (separator == CHR_HOUR)
|
||||||
|
|||||||
@@ -28,16 +28,16 @@ void drawCurveRef(coord_t x, coord_t y, CurveRef & curve, LcdFlags att)
|
|||||||
lcdDrawText(x, y, "D", att);
|
lcdDrawText(x, y, "D", att);
|
||||||
GVAR_MENU_ITEM(lcdNextPos, y, curve.value, -100, 100, LEFT|att, 0, 0);
|
GVAR_MENU_ITEM(lcdNextPos, y, curve.value, -100, 100, LEFT|att, 0, 0);
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case CURVE_REF_EXPO:
|
case CURVE_REF_EXPO:
|
||||||
lcdDrawText(x, y, "E", att);
|
lcdDrawText(x, y, "E", att);
|
||||||
GVAR_MENU_ITEM(lcdNextPos, y, curve.value, -100, 100, LEFT|att, 0, 0);
|
GVAR_MENU_ITEM(lcdNextPos, y, curve.value, -100, 100, LEFT|att, 0, 0);
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case CURVE_REF_FUNC:
|
case CURVE_REF_FUNC:
|
||||||
lcdDrawTextAtIndex(x, y, STR_VCURVEFUNC, curve.value, att);
|
lcdDrawTextAtIndex(x, y, STR_VCURVEFUNC, curve.value, att);
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case CURVE_REF_CUSTOM:
|
case CURVE_REF_CUSTOM:
|
||||||
drawCurveName(x, y, curve.value, att);
|
drawCurveName(x, y, curve.value, att);
|
||||||
break;
|
break;
|
||||||
@@ -51,10 +51,10 @@ void drawSensorCustomValue(coord_t x, coord_t y, uint8_t sensor, int32_t value,
|
|||||||
// Lua luaLcdDrawChannel() can call us with a bad value
|
// Lua luaLcdDrawChannel() can call us with a bad value
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
TelemetryItem & telemetryItem = telemetryItems[sensor];
|
TelemetryItem & telemetryItem = telemetryItems[sensor];
|
||||||
TelemetrySensor & telemetrySensor = g_model.telemetrySensors[sensor];
|
TelemetrySensor & telemetrySensor = g_model.telemetrySensors[sensor];
|
||||||
|
|
||||||
if (telemetrySensor.unit == UNIT_DATETIME) {
|
if (telemetrySensor.unit == UNIT_DATETIME) {
|
||||||
drawDate(x, y, telemetryItem, flags);
|
drawDate(x, y, telemetryItem, flags);
|
||||||
}
|
}
|
||||||
@@ -126,6 +126,7 @@ void drawSourceCustomValue(coord_t x, coord_t y, source_t source, int32_t value,
|
|||||||
drawSensorCustomValue(x, y, source, value, flags);
|
drawSensorCustomValue(x, y, source, value, flags);
|
||||||
}
|
}
|
||||||
else if (source >= MIXSRC_FIRST_TIMER || source == MIXSRC_TX_TIME) {
|
else if (source >= MIXSRC_FIRST_TIMER || source == MIXSRC_TX_TIME) {
|
||||||
|
if (value < 0) flags |= BLINK|INVERS;
|
||||||
drawTimer(x, y, value, flags);
|
drawTimer(x, y, value, flags);
|
||||||
}
|
}
|
||||||
else if (source == MIXSRC_TX_VOLTAGE) {
|
else if (source == MIXSRC_TX_VOLTAGE) {
|
||||||
|
|||||||
Reference in New Issue
Block a user