aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSven Gothel <[email protected]>2022-04-19 06:26:22 +0200
committerSven Gothel <[email protected]>2022-04-19 06:26:22 +0200
commitfda49ef5ba0d3fb03aefb6f119f4196f9c05dc51 (patch)
treea5c7463a5408551a994f8f4e5dd4e828f6611dca
parent6c3451536ea6f468079349daec647d01354a3435 (diff)
README: Bump v2.6.4. Convert Connection_Paramter.md to markdown and link.v2.6.4
Also add scripts/run-trials-until.sh script.
-rw-r--r--README.md25
-rw-r--r--doc/Connection_Parameter.md42
-rw-r--r--doc/Connection_Parameter.txt46
-rwxr-xr-xscripts/run-trials-until.sh7
4 files changed, 71 insertions, 49 deletions
diff --git a/README.md b/README.md
index eaa6efef..4ec895ed 100644
--- a/README.md
+++ b/README.md
@@ -68,6 +68,9 @@ To support other platforms than Linux/BlueZ, we will have to
* move specified HCI host features used in DBTManager to HCIHandler, SMPHandler,.. - and -
* add specialization for each new platform using their non-platform-agnostic features.
+### Direct-BT Default Connection Parameter
+Please check the [Connection Paramter](doc/Connection_Parameter.md) for details.
+
## Supported Platforms
The following **platforms** are tested and hence supported
@@ -384,9 +387,9 @@ The *trial* tests take around 100 seconds, since `TestDBClientServer1*` performs
All tests pass reproducible using two well working adapter, e.g. Raspi 3b+ (BT4) and CSR (BT4).
-1/7 tests using at least one not well working BT5 adapter may timeout and hence fail.
+1/7 legacy security (SC 0) tests using at least one not well working BT5 adapter may timeout waiting for key completion.
The following issues are known and are under investigation:
-- *BlueZ* is not sending us all new key information under legacy security (SC 0)
+- *BlueZ* is not sending us all new key information under legacy security (SC 0) using at least one BT5 adapter
- This is mitigated by *BTAdapter*'s *smp_watchdog*, leading to a retrial visible as *SMP Timeout*
### Cross Build
@@ -497,8 +500,24 @@ from the year 2016.
* TODO
+**2.6.4**
+* Fix several memory leaks and uninitialized fields using valgrind analysis (native and w/ JVM)
+ - BTGattHandler::disconnect(): Check weak BTDevice before using resources
+ - BTGattHandler::l2capReaderEndLocked(): Remove off-thread BTDevice::disconnect() on io-error, use BT host's disconnect (simplify tear down)
+ - BTGattHandler's l2capReader data race (use after free)
+* Trial `TestDBClientServer1*` test changes
+ - Split tests into NoEnc, SC0 and SC1 classes
+ - Have client/server adapter names unique, allowing multi-machine testing in one room
+* Bump jaulib v0.8.0
+* BTAdapter Server: Offload waiting for L2CAP client connection to BTDevice::processL2CAPSetup() dedicated thread
+* [L2CAP, HCI]Comm: Hold external interrupted delegate from `service_runner` for complete interrupted() query
+* WIP: BTAdapter::startDiscovery(): Retry up to `MAX_BACKGROUND_DISCOVERY_RETRY` (3), mitigating failure to start discovery
+* BTDevice::notifyLEFeature(): Remove HCIStatusCode param and only call with SUCCESS status code
+* Fix and [document default connection paramter](doc/Connection_Parameter.md), leaning to the higher performance side
+* Resolve legacy security (SC 0) BlueZ/Kernel Mgmt LTK role of `master` or `initiator` field
+
**2.6.3**
-- Have trial `TestDBClientServer1*` test in both client/server directions, legacy and secure connections (SC)
+* Have trial `TestDBClientServer1*` test in both client/server directions, legacy and secure connections (SC)
* Fix BTAdapter's server mode key handling
* Have failed pairing issue disconnect, posting indicative reason
* Use global `inline constexpr` instead of `#define` macros
diff --git a/doc/Connection_Parameter.md b/doc/Connection_Parameter.md
new file mode 100644
index 00000000..42082756
--- /dev/null
+++ b/doc/Connection_Parameter.md
@@ -0,0 +1,42 @@
+# Direct-BT Default Connection Parameter
+
+## Server
+
+* BTAdapter::setDefaultConnParam():
+ - const uint16_t conn_min_interval = 8; // 10ms
+ - const uint16_t conn_max_interval = 40; // 50ms
+ - const uint16_t conn_latency = 0;
+ - const uint16_t supervision_timeout = 50; // 500ms
+ - status = adapter->setDefaultConnParam(conn_min_interval, conn_max_interval, conn_latency, supervision_timeout);
+
+* BTAdapter::startAdvertising()
+ - static const uint16_t adv_interval_min=160; // x0.625 = 100ms - default is 640 -> 400ms
+ - static const uint16_t adv_interval_max=480; // x0.625 = 300ms - default is 640 -> 400ms
+ - static const AD_PDU_Type adv_type=AD_PDU_Type::ADV_IND;
+ - static const uint8_t adv_chan_map=0x07;
+ - static const uint8_t filter_policy=0x00;
+ - eir.setConnInterval(8, 12); // 10ms - 15ms
+
+
+## Client
+
+* BTAdapter::startDiscovery():
+ - static DiscoveryPolicy discoveryPolicy = DiscoveryPolicy::PAUSE_CONNECTED_UNTIL_READY; // default value
+ - static bool le_scan_active = true; // default value
+ - static const uint16_t le_scan_interval = 24; // 15ms, default value
+ - static const uint16_t le_scan_window = 24; // 15ms, default value
+ - static const uint8_t filter_policy = 0; // default value
+ - adapter->startDiscovery( discoveryPolicy, le_scan_active, le_scan_interval, le_scan_window, filter_policy );
+
+
+* BTDevice::connectLE():
+ - static const uint16_t le_scan_interval = 24; // 15ms, default value
+ - static const uint16_t le_scan_window = 24; // 15ms, default value
+ - uint16_t conn_interval_min = (uint16_t)8; // 10ms
+ - uint16_t conn_interval_max = (uint16_t)12; // 15ms
+ - const uint16_t conn_latency = (uint16_t)0;
+ - const uint16_t supervision_timeout = (uint16_t) getHCIConnSupervisorTimeout(conn_latency, (int) ( conn_interval_max * 1.25 ) /* ms */);
+ - device->connectLE(le_scan_interval, le_scan_window, conn_interval_min, conn_interval_max, conn_latency, supervision_timeout);
+
+
+
diff --git a/doc/Connection_Parameter.txt b/doc/Connection_Parameter.txt
deleted file mode 100644
index d9233e88..00000000
--- a/doc/Connection_Parameter.txt
+++ /dev/null
@@ -1,46 +0,0 @@
-Server:
-========
-
-BTAdapter::setDefaultConnParam():
- const uint16_t conn_min_interval = 8; // 10ms
- const uint16_t conn_max_interval = 40; // 50ms
- const uint16_t conn_latency = 0;
- const uint16_t supervision_timeout = 50; // 500ms
- status = adapter->setDefaultConnParam(conn_min_interval, conn_max_interval, conn_latency, supervision_timeout);
-
-BTAdapter::startAdvertising()
- static const uint16_t adv_interval_min=160; // x0.625 = 100ms - default is 640 -> 400ms
- static const uint16_t adv_interval_max=480; // x0.625 = 300ms - default is 640 -> 400ms
- static const AD_PDU_Type adv_type=AD_PDU_Type::ADV_IND;
- static const uint8_t adv_chan_map=0x07;
- static const uint8_t filter_policy=0x00;
-
- eir.setConnInterval(8, 12); // 10ms - 15ms
-
-
-Client:
-========
-
-BTAdapter::startDiscovery():
- static DiscoveryPolicy discoveryPolicy = DiscoveryPolicy::PAUSE_CONNECTED_UNTIL_READY; // default value
- static bool le_scan_active = true; // default value
- static const uint16_t le_scan_interval = 24; // 15ms, default value
- static const uint16_t le_scan_window = 24; // 15ms, default value
- static const uint8_t filter_policy = 0; // default value
-
- adapter->startDiscovery( discoveryPolicy, le_scan_active, le_scan_interval, le_scan_window, filter_policy );
-
-
-BTDevice::connectLE():
- static const uint16_t le_scan_interval = 24; // 15ms, default value
- static const uint16_t le_scan_window = 24; // 15ms, default value
-
- uint16_t conn_interval_min = (uint16_t)8; // 10ms
- uint16_t conn_interval_max = (uint16_t)12; // 15ms
- const uint16_t conn_latency = (uint16_t)0;
-
- const uint16_t supervision_timeout = (uint16_t) getHCIConnSupervisorTimeout(conn_latency, (int) ( conn_interval_max * 1.25 ) /* ms */);
- device->connectLE(le_scan_interval, le_scan_window, conn_interval_min, conn_interval_max, conn_latency, supervision_timeout);
-
-
-
diff --git a/scripts/run-trials-until.sh b/scripts/run-trials-until.sh
new file mode 100755
index 00000000..c891db7f
--- /dev/null
+++ b/scripts/run-trials-until.sh
@@ -0,0 +1,7 @@
+#!/bin/bash
+
+run_until() {
+ let n=0; while make test ; do let n=${n}+1; echo "Test ${n} OK"; cp -av Testing/Temporary/LastTest.log LastTest-${n}.log ; done
+}
+
+run_until 2>&1 | tee run-trials-until.log