Spectrum analyser fixes

Compatibily issue when telemetry comes from int + ext modules
This commit is contained in:
Bertrand Songis
2019-04-29 11:52:17 +02:00
parent 14c282110d
commit d70f3a40ef
12 changed files with 13 additions and 39 deletions
+2 -3
View File
@@ -1191,7 +1191,7 @@ void menuModelSetup(event_t event)
if (bluetooth.distantAddr[0]) {
lcdDrawText(INDENT_WIDTH, y+1, bluetooth.distantAddr, TINSIZE);
lcdDrawText(MODEL_SETUP_2ND_COLUMN, y, BUTTON(TR_CLEAR), attr);
if (attr && event == EVT_KEY_FIRST(KEY_ENTER)) {
if (attr && event == EVT_KEY_BREAK(KEY_ENTER)) {
bluetooth.state = BLUETOOTH_STATE_CLEAR_REQUESTED;
memclear(bluetooth.distantAddr, sizeof(bluetooth.distantAddr));
}
@@ -1202,8 +1202,7 @@ void menuModelSetup(event_t event)
lcdDrawText(MODEL_SETUP_2ND_COLUMN, y, STR_BUTTON_INIT, attr);
else
lcdDrawText(MODEL_SETUP_2ND_COLUMN, y, STR_BUTTON_DISCOVER, attr);
if (attr && event == EVT_KEY_FIRST(KEY_ENTER)) {
killEvents(KEY_ENTER);
if (attr && event == EVT_KEY_BREAK(KEY_ENTER)) {
if (bluetooth.state < BLUETOOTH_STATE_IDLE) {
bluetooth.state = BLUETOOTH_STATE_OFF;
}