diff --git a/src/blecsan.cpp b/src/blecsan.cpp index 34036749..4c2bb9af 100644 --- a/src/blecsan.cpp +++ b/src/blecsan.cpp @@ -100,7 +100,7 @@ static void gap_callback_handler(esp_gap_ble_cb_event_t event, esp_ble_gap_cb_pa { case ESP_GAP_BLE_SCAN_PARAM_SET_COMPLETE_EVT: { // restart scan - status = esp_ble_gap_start_scanning(BLESCANTIME); + status = esp_ble_gap_start_scanning(cfg.blescantime); if (status != ESP_OK) { ESP_LOGE(TAG, "esp_ble_gap_start_scanning: rc=%d", status); @@ -112,7 +112,7 @@ static void gap_callback_handler(esp_gap_ble_cb_event_t event, esp_ble_gap_cb_pa { if ( p->scan_rst.search_evt == ESP_GAP_SEARCH_INQ_CMPL_EVT) // Inquiry complete, scan is done { // restart scan - status = esp_ble_gap_start_scanning (BLESCANTIME); + status = esp_ble_gap_start_scanning (cfg.blescantime); if (status != ESP_OK) { ESP_LOGE(TAG, "esp_ble_gap_start_scanning: rc=%d", status);