Just post the library mods to permit the inclusion of both ESP32 Blynk BT / BLE and WiFi libraries in one sketch. Then select one (WiFi or BT/BLE) to run at runtime. Just added BLE.
This is in infancy state, please have a try at
Inspired from @Crosswalkersam OP
See sample code, modified from OP’s code in
Update
@Crosswalkersam has posted the very good project (using this mod lib) on Intructables
Update Jan 27th 2020
This new version v1.0.1 enables user to include both Blynk BT / BLE and WiFi libraries in one sketch, and run both WiFi and BT/BLE simultaneously
, or select one to use at runtime after reboot by pressing a switch.
All the previously-working widgets are still working correctly.
Terminal output when running WiFi and BT simultaneously using example Geiger_Counter_OLED_BT_WF
:
Starting Geiger-Counter-OLED-BT-WF
Use WiFi to connect Blynk
[251] Connecting to HueNet1
[2412] Connected to WiFi
[2412] IP: 192.168.2.109
[2412]
___ __ __
/ _ )/ /_ _____ / /__
/ _ / / // / _ \/ '_/
/____/_/\_, /_//_/_/\_\
/___/ v0.6.1 on ESP32
[2418] BlynkArduinoClient.connect: Connecting to account.duckdns.org:8080
[2524] Ready (ping: 6ms).
Use BT to connect Blynk
[2594]
___ __ __
/ _ )/ /_ _____ / /__
/ _ / / // / _ \/ '_/
/____/_/\_, /_//_/_/\_\
/___/ v0.6.1 on ESP32
cpm = 0 - RadiationValue = 0.00uSv/h - Equivalent RadiationDose = 0.0000uSv
[25805] BT connect
[25831] Ready (ping: 25ms).
cpm = 0 - RadiationValue = 0.00uSv/h - Equivalent RadiationDose = 0.0000uSv
Terminal output when running WiFi and BLE simultaneously using example Geiger_Counter_OLED_BT_BLE_WF
:
Starting Geiger-Counter-OLED-BT-BLE-WF
Use WiFi to connect Blynk
[248] Connecting to HueNet1
[2377] Connected to WiFi
[2377] IP: 192.168.2.126
[2377]
___ __ __
/ _ )/ /_ _____ / /__
/ _ / / // / _ \/ '_/
/____/_/\_, /_//_/_/\_\
/___/ v0.6.1 on ESP32
[2383] BlynkArduinoClient.connect: Connecting to account.duckdns.org:8080
[2429] Ready (ping: 15ms).
Use BLE to connect Blynk
[2499]
___ __ __
/ _ )/ /_ _____ / /__
/ _ / / // / _ \/ '_/
/____/_/\_, /_//_/_/\_\
/___/ v0.6.1 on ESP32
[16135] BLE connect
[17353] Ready
cpm = 0 - RadiationValue = 0.000 uSv/h - Equivalent RadiationDose = 0.0000 uSv
cpm = 30 - RadiationValue = 0.197 uSv/h - Equivalent RadiationDose = 0.0008 uSv
cpm = 60 - RadiationValue = 0.395 uSv/h - Equivalent RadiationDose = 0.0025 uSv
cpm = 90 - RadiationValue = 0.592 uSv/h - Equivalent RadiationDose = 0.0049 uSv
cpm = 120 - RadiationValue = 0.790 uSv/h - Equivalent RadiationDose = 0.0082 uSv
cpm = 150 - RadiationValue = 0.987 uSv/h - Equivalent RadiationDose = 0.0123 uSv
Update Jan 28th 2020
BlynkESP32_BT_WF libraries v1.0.1
just got included into Arduino Library Manager.
Now you can install this library directly from Arduino Library Manager.