ESP32 as Access Point without webserver

Hello Everyone.

I wanted to know (might be a dumb question) is it possible to configure ESP32 as AP without having a web server on it?

I'm working on a project where I have a cellphone app designed by someone else. I need to connect the cell phone to my ESP32 configured as AP, as a client. I have two buttons on the app - on/off. whenever On button is clicked any one of the GPIO of ESP32 goes high and viceversa.

I tried looking for it, but all the examples I see has a webserver on it. Am I wrong about the understanding or this is how it works?

Thanks in advance

Certainly, though an "access point" generally implies the provision of access to something, whether that is a Web server on the same device, of the Internet proper by some other connection.

However, if you have two WiFi devices, neither of which is an Access Point in themselves, then you generally need an Access Point in order for those devices to be allocated IP addresses (DHCP) and connect to each other. There is an alternative called "ESP-NOW"

If the ESP is itself the device to run the control app, then you clearly do need it to be a Access Point. While a Web server is one way and possibly the most common way to do this (I have a "Times Square Display" on my business door that is controlled in this manner), there are no doubt other ways to do it - as devices such as the WiFi light bulbs and such do, but I do not know how they do it.

Your question is unclear. Do you have an app - not a Web Browser - that is already controlling the ESP32, or you want to know how to arrange this?

typically examples of Access Points run a webserver to demonstrate functionality
however, it is possible run a TCP or UDP server which can be accessed by remote clients

Edit: for an example of an ESP32 Access Point running a chat server (program which enables two machines to send text messages to each other) see post #13 of controller-data-displayed-on-a-webpage-can-it-be-manipulated

Sorry for getting on this really late. Unfortunately I was sick, but now I'm back on track.

So the thing is I need ESP32 configured as AP I have a device connected to it and I want to switch it on/off using a cell phone app.

In all the examples that I see on the internet if ESP is configured as AP and it is controlling something they put a web server on it.
My question is, is it possible to control a device thru ESP32 configured as AP without having a web server on it. and if it is possible how to do it?
My next question (again a dumb one) is if I configure esp as AP and put a web server on it, and if I open up the web browser and type in the IP address of my esp I'll be directed to the web server's landing page. Would I still be able to control this ESP with my cellphone app, when it has a webserver running on it?

Thanks in advance. I do know where lil about this, so please forgive if my questions are too dumb

once you have an ESP running an access point you can run TCP client/server programs such as webservers, email servers, etc including TCP or UDP client/servers you have written yourself.
A webserver is often used to demonstrate the functionality, e.g. ESP8266 example: Wi-Fi Access point, static IP, web-server and remote GPIO control, as it is simple to run the webserver and pass its input to the device being controlled.
Therefore

  1. you write a program for the ESP which accepts TCP or UDP connections from the cell phone
  2. you write an app for the cell phone which will make a connection to the ESP and send it data, I would use Java for this but alternatives are available
    you use a suitable protocol to pass the information between the ESP and cell phone

The point really is - what will the app on the phone be?

Phones universally incorporate a Web browser, and a Web browser functions on Web pages, so a Web server is the easiest way to control something.

If you wish to do it some other way, then you have to have an app on the phone to operate it, which means you have to find or develop that app yourself - and install it on the phone.

Do you really want to go to the trouble of developing such an app? :face_with_raised_eyebrow:

That's precisely what you do. You use the Web server to interact with a Web page on a Web server. :thinking:

So you do not want to navigate to an IP address of an ESP32 and use the web pages generated by an ESP32 loaded onto the phone to control the ESP32. What I am reading you want to do is to be able to send signals from the phone to the ESP32 directly, correct?

Why yes, it's possible. How. Some form of hosting needs to be done. Either have the host be the phone or the ESP32 or a 3rd party host. I use a 3rd party host. I use MQTT Broker. You could use an IoT thingy like Arduino has a https://docs.arduino.cc/cloud/iot-cloud IoT cloud thingy and there is Sparky Funs, Internet of Things Experiment Guide - SparkFun Learn IoT thingy. The phone could get put stuff to/from the cloud thingy and the ESP32 can get put stuff to/from the IoT cloud thingy.

I can change the temperature of my home's heating/ac from anywhere in the world I have internet access, with my phone.

Thank you for all these valuable and lovely inputs. It has been really great help to me. Finally I adapted a reference and got my thing working:

https://techtotinker.blogspot.com/2020/08/tutorial-esp32-web-server-esp32-wifi-in.html?m=1

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.