1
0
Fork 0
mirror of https://github.com/EdgeTX/edgetx.git synced 2025-07-17 05:15:17 +03:00

Bsongis/issue 6910 x10 express bluetooth (#6931)

[X10 Express] Bluetooth function added
This commit is contained in:
Bertrand Songis 2019-10-11 08:09:59 +02:00 committed by GitHub
parent 9bdccd47fe
commit 135133423a
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
18 changed files with 93 additions and 53 deletions

View file

@ -227,7 +227,7 @@ enum {
#elif defined(PCBX9E)
#define BLUETOOTH_ROWS 0, uint8_t(g_eeGeneral.bluetoothMode == BLUETOOTH_OFF ? HIDDEN_ROW : READONLY_ROW), uint8_t(g_eeGeneral.bluetoothMode == BLUETOOTH_OFF ? HIDDEN_ROW : READONLY_ROW), uint8_t(g_eeGeneral.bluetoothMode == BLUETOOTH_OFF ? HIDDEN_ROW : 0), uint8_t(g_eeGeneral.bluetoothMode == BLUETOOTH_OFF ? HIDDEN_ROW : 0),
#else
#define BLUETOOTH_ROWS uint8_t(IS_BLUETOOTH_CHIP_PRESENT() ? 0 : HIDDEN_ROW), uint8_t(g_eeGeneral.bluetoothMode == BLUETOOTH_TELEMETRY ? -1 : HIDDEN_ROW), uint8_t(g_eeGeneral.bluetoothMode == BLUETOOTH_OFF ? HIDDEN_ROW : -1), uint8_t(g_eeGeneral.bluetoothMode == BLUETOOTH_OFF ? HIDDEN_ROW : -1), uint8_t(g_eeGeneral.bluetoothMode == BLUETOOTH_OFF ? HIDDEN_ROW : 0),
#define BLUETOOTH_ROWS uint8_t(IS_BLUETOOTH_CHIP_PRESENT() ? 0 : HIDDEN_ROW), uint8_t(g_eeGeneral.bluetoothMode == BLUETOOTH_TELEMETRY ? READONLY_ROW : HIDDEN_ROW), uint8_t(g_eeGeneral.bluetoothMode == BLUETOOTH_OFF ? HIDDEN_ROW : READONLY_ROW), uint8_t(g_eeGeneral.bluetoothMode == BLUETOOTH_OFF ? HIDDEN_ROW : READONLY_ROW), uint8_t(g_eeGeneral.bluetoothMode == BLUETOOTH_OFF ? HIDDEN_ROW : 0),
#endif
#if defined(INTERNAL_MODULE_PXX1) && defined(EXTERNAL_ANTENNA)
@ -561,17 +561,17 @@ void menuRadioHardware(event_t event)
break;
case ITEM_RADIO_HARDWARE_BLUETOOTH_PAIRING_CODE:
lcdDrawTextAlignedLeft(y, STR_BLUETOOTH_PIN_CODE);
lcdDrawText(INDENT_WIDTH, y, STR_BLUETOOTH_PIN_CODE);
lcdDrawText(HW_SETTINGS_COLUMN2, y, "000000");
break;
case ITEM_RADIO_HARDWARE_BLUETOOTH_LOCAL_ADDR:
lcdDrawTextAlignedLeft(y, STR_BLUETOOTH_LOCAL_ADDR);
lcdDrawText(INDENT_WIDTH, y, STR_BLUETOOTH_LOCAL_ADDR);
lcdDrawText(HW_SETTINGS_COLUMN2, y, bluetooth.localAddr[0] == '\0' ? "---" : bluetooth.localAddr);
break;
case ITEM_RADIO_HARDWARE_BLUETOOTH_DISTANT_ADDR:
lcdDrawTextAlignedLeft(y, STR_BLUETOOTH_DIST_ADDR);
lcdDrawText(INDENT_WIDTH, y, STR_BLUETOOTH_DIST_ADDR);
lcdDrawText(HW_SETTINGS_COLUMN2, y, bluetooth.distantAddr[0] == '\0' ? "---" : bluetooth.distantAddr);
break;