BLE auto reconnect when previously paired device is range?

MyESP32
Posts: 2
Joined: Tue Feb 23, 2021 9:21 pm

BLE auto reconnect when previously paired device is range?

Postby MyESP32 » Fri Mar 05, 2021 4:28 am

Hi sorry newbee here looking to program an esp32 to just do 3 simple things. I'm still learning Arduino programing and can't seem to figure this out....

I need it to do:
1 - securely connect to a phone via passcode
2 - if secure connection successful:
pin goes high to turn ON LED
if not securely connected LED -> OFF
if phone disconnects from bluetooth -> LED OFF
3 - automatically reconnect to the phone if the previously paired phone comes back into range. Or if the phone BLE is off, and I turn the BLE back on on the phone I want esp32 to again automatically reconnect to the phone.

Would such a sketch possible on esp32 and BLE? and would it be default? I've searched all over the internet for days now for a similar example for esp32 on Arduino IDE and couldn't fine anything that does that. I was able to accomplish number 1 and 2, but never number 3 auto reconnecting...

If someone could point me in the right direction or show me an example that does something similar that would awesome.

I very much appreciate any help anyone

ShahenS
Posts: 1
Joined: Fri Jul 02, 2021 11:34 pm

Re: BLE auto reconnect when previously paired device is range?

Postby ShahenS » Fri Jul 02, 2021 11:36 pm

I'm looking for the exact thing.
Were you able to come up with anything?

Who is online

Users browsing this forum: Bing [Bot] and 99 guests