changeset 3:4ace58a7c03c

Send disconnect command before closing the connection The old BT module transmitted a notification in case a connection were closed which cause the ostc to exit the uart loop. The new one doesn't do this => send disconnect command to avoid waiting in the installation loop till timeout or button press.
author Ideenmodellierer
date Fri, 28 Nov 2025 20:00:02 +0100
parents 177f640940f2
children e30f00f760d3
files OSTC4Operations.cpp
diffstat 1 files changed, 1 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/OSTC4Operations.cpp	Fri Nov 28 19:57:35 2025 +0100
+++ b/OSTC4Operations.cpp	Fri Nov 28 20:00:02 2025 +0100
@@ -374,8 +374,7 @@
     //---- Done --------------------------------------------------------------
     // Low-level close, to avoid trying to send a 0xFF byte...
     if( !dryRun ) {
-        _serial.close();
-        _connectMode = CLOSED_MODE;
+        disconnect(true);
     }
 
     PROGRESS_RESET();