Neutralise BT on X9E, unless DEBUG is defined (#5148)

* Neutralise BT on X9E, unless DEBUG is defined

* Adjust to Bertrand comments
This commit is contained in:
3djc
2017-08-14 22:03:26 -07:00
committed by Bertrand Songis
parent 0e139fd0d6
commit 5a8a074f0c
8 changed files with 85 additions and 12 deletions
+4 -1
View File
@@ -1205,11 +1205,14 @@ int cliBlueTooth(const char ** argv)
char command[32];
strAppend(strAppend(command, argv[1]), "\r\n");
bluetoothWriteString(command);
char * line = bluetoothReadline();
serialPrint("<BT %s", line);
}
else if (toInt(argv, 1, &baudrate) > 0) {
if (baudrate > 0) {
bluetoothInit(baudrate);
serialPrint("BT baudrate set to %d", baudrate);
char * line = bluetoothReadline();
serialPrint("<BT %s", line);
}
else {
bluetoothDone();