Add RAS to X7 analogs screen (#4865)

* Add RAS to X7 analogs screen

* Also fix SWR->RAS in simulator UI

* Only display RAS for external XJT module

The „this is almost useless but I have done the work, now it stays commit“
This commit is contained in:
Arne Schwabe
2017-04-27 20:31:00 +02:00
committed by Bertrand Songis
parent c6d15c6f37
commit 37b0dab9da
2 changed files with 6 additions and 1 deletions
+1 -1
View File
@@ -528,7 +528,7 @@ Timestamp</string>
</font>
</property>
<property name="text">
<string>SWR</string>
<string>RAS</string>
</property>
</widget>
</item>
+5
View File
@@ -65,6 +65,11 @@ void menuRadioDiagAnalogs(event_t event)
#if defined(PCBX7)
lcdDrawTextAlignedLeft(MENU_HEADER_HEIGHT + 1 + (NUM_STICKS+NUM_POTS+NUM_SLIDERS+1)/2 * FH + 2, STR_BATT_CALIB);
putsVolts(LEN_CALIB_FIELDS*FW+FW, MENU_HEADER_HEIGHT + 1 + (NUM_STICKS+NUM_POTS+NUM_SLIDERS+1)/2 * FH + 2, getBatteryVoltage(), (menuVerticalPosition==HEADER_LINE ? INVERS | (s_editMode > 0 ? BLINK : 0) : 0) | PREC2 | LEFT);
// SWR
if(IS_MODULE_XJT(EXTERNAL_MODULE)) {
lcdDrawTextAlignedLeft(MENU_HEADER_HEIGHT + 1 + (NUM_STICKS+NUM_POTS+NUM_SLIDERS+1)/2 * FH + 1 * FH + 2, "RAS");
lcdDrawNumber(LEN_CALIB_FIELDS*FW+FW, MENU_HEADER_HEIGHT + 1 + (NUM_STICKS+NUM_POTS+NUM_SLIDERS+1)/2 * FH + 1 * FH + 2, telemetryData.swr.value, LEFT);
}
#elif defined(PCBSKY9X)
lcdDrawTextAlignedLeft(MENU_HEADER_HEIGHT+1+4*FH, STR_BATT_CALIB);
static int32_t adcBatt;