ESP32 BLE fallback if NO WiFi?

Hello, I want to be able to configure ESP32, if no wifi credentials are given or wasn’t connected to wifi for, let say, 1 min to start BLE service and accept wifi credentials sent by it. Is it possible in Home Assistant ESPHome?
I saw examples with arduino, but this can’t be integrated in HA, unless MQTT is used, right?
I’ll be happy if I can see any yaml example of implemented in HA BLE control.
Thanks!

You can have it create a fallback AP:

I know that. Thanks.

It would be good in future to make your research clear. There’s no BLE equivalent AFAIK.

Why do you specifically need a BLE version where the WiFi equivalent won’t suffice?

parautenbach, thanks you for participation.
I didn’t mean to make the question so long, but to satisfy your curiosity:
Sending WiFi credentials by BLE is the easiest way to reconfigure new device where the network is unknown to it.
The ESP32 has BLE capability, which I intend to utilize. While there is a WiFi fallback option available, it involves additional steps that contradict the streamlined nature of automations and smart gadgets, which are designed to minimize such complexities.

I agree that is the standard way of doing things nowadays.

Maybe log an FR here on the forum and tag it with ESPHome.

PS: You can reply to or tag someone with an @ — the link is just to one’s profile and won’t issue a notification.

Isn’t that what this does? Improv via BLE — ESPHome

1 Like

I think you’re right. I didn’t know!

That just connects via BT and allows you to confugure wifi ssid, password. If you made an esphome project for someone for an example. Thhis allows them to connecct to the esp node via BT and configure their wifi,ssid instead of having to deal with esphome and installing that.

It you can find Arduino examples for this then surely you can find the eaphome documents and go read them. They explain all this basic stuff.

Isn’t that what the OP asked for?

It seems like you’re actually responding to different people. You directly replied to my message, yet you refer to something from the first post.

I’ve tried Improv via BLE example from ESPHome, but I wasn’t able to make it work. Not much documentation as well examples.
This code somehow works:

# Example configuration entry
wifi:
  # ...

esp32_improv:
  authorizer: none # <- this way I was able to compile, when "none"

But, I wasn’t able to connect to device.
“an app is needed to use this device” - this is the error my phone returns when I try to connect.

Why are you using BT to set up wifi when you can use wifi to set up wifi… You understand that if there is “No wifi” like your original question then then using BT is of no use because it only allows you to enter an ssid and password… for wifi…

I thought it was the easiest way and was just so awesome because it requires one less step. Surely you can figure it out then.