B4R Question ESP32<->Android/iPhone without internet

fbritop

Active Member
Licensed User
Longtime User
I have the folowing case:
An ESP32 programed in Arduino, which has no internet connection (Wifi has not been setup). At it first stage, the ESP32 has an open Access Point (You must activate this function by pressing X number of times a button). Then a phone can connect to this device.

Here comes the wierd part. I have not managed to have the ESP32 to work as an MQTT broker and at the same time as an MQTT Client (The phone has to be also a client). In that way, Phone and ESP32 can share data, in order to configure the network.

I pretty sure that is way to complicated to have the broker on the phone, so I think an alternative is that the broker is in the access point (ESP32). Has anyone done something like this or have an alternative method in order to configure the device through the access point, without mounting a web server on the phone. There is also another issue. As we have a single network on Wifi, if you do a WiFi Scan to search for the networks, which if you do on the ESP32, yo can know for sure, that those are the SSID that are visible to him, when yo do a WifiScan, the access points gets disconnected, as the scan need to free the channels in order to scan, so the phone looses his connection as a station as it receives no beacon from the Access Point (ESP32).

I´m sure there are some ways, as Tuya Smart app can register devices on that way.

Thanks
FBP
 

candide

Active Member
Licensed User
a simple alternative way is to make esp provisioning by serial link with a terminal on mobile and a connection by USB with esp

in my test format is : command parmeter1 parameter2 parameter3 parameter4
(separator is "space")

under Android i use "Serial USB Terminal" , it is freeware without pub
under PC i use Termite.exe
 

Attachments

  • test_Serial.zip
    1.7 KB · Views: 167
Upvote 0

fbritop

Active Member
Licensed User
Longtime User
Well it will do for normal ESP development. But when you have a product, that is locked within an enclosure in a DIN Rail its kind of hard for the user. And the user is not an IT guy. I as thinking of BLE GATTs, I know I did something like than long time ago, based on ESP32, but it was with MongooseOS interpreter on the ESP
 
Upvote 0

candide

Active Member
Licensed User
Last edited:
Upvote 0
Top