fixed BT LED state in case some mouse is reconnecting while the quack is scanning

This commit is contained in:
demik 2021-10-30 15:38:34 +02:00
parent 157ab85c84
commit 03a92bcda4
2 changed files with 6 additions and 2 deletions

View File

@ -1,5 +1,6 @@
## v1.4.2 (unreleased)
## v1.4.2
- added support for MicroSpeed MacTRAC 2.0
- fixed a BT led state when a device reconnect while scanning
## v1.4.1
- update to ESP-IDF v4.2.2:

View File

@ -513,7 +513,10 @@ void blue_scan(void *pvParameters) {
ESP_LOGI(TAG, "starting scan on core %d…", xPortGetCoreID());
esp_hid_scan(BLUE_SCAN_DURATION, &len, &results);
ESP_LOGI(TAG, "scan returned %u result(s)", len);
xTaskNotify(t_blue, LED_SLOW, eSetValueWithOverwrite);
/* don't put the slow blink is a device reconnected while scanning */
if (blue_pointers == 0)
xTaskNotify(t_blue, LED_SLOW, eSetValueWithOverwrite);
if (len) {
esp_hid_scan_result_t *r = results;