Fix compilation problem on ESP32 using Bluetooth Classic
Issues Resolved
In https://github.com/blynkkk/blynk-library/pull/555 a fix was introduced to solve a compilation problem on ESP32
Fixing "error: 'ESP_BT_SCAN_MODE_CONNECTABLE_DISCOVERABLE' was not declared in this scope"
But this fix introduces a compilation error in previous versions of IDF / ESP32 Arduino Core.
Now it will check the IDF version and depending on version 3 or 4, it will compile using other code.
Description
Fix compilation problem on ESP32 using Bluetooth Classic
Issues Resolved
In https://github.com/blynkkk/blynk-library/pull/555 a fix was introduced to solve a compilation problem on ESP32 Fixing "error: 'ESP_BT_SCAN_MODE_CONNECTABLE_DISCOVERABLE' was not declared in this scope"
But this fix introduces a compilation error in previous versions of IDF / ESP32 Arduino Core.
Now it will check the IDF version and depending on version 3 or 4, it will compile using other code.