Welcome back guys to video number 4.3. And
in this video, why going to set up a hotspot and buy
a hotspot, we will connect our machine
our Windows machine and from the browser. We
will access the page where we have an option to turn on
and off an LED. So guys, let's get started with that. Okay.
to
get started with that click on file example and
Wi-Fi. Okay before
moving on firstly we need to select the development board.
We already have a do it esp32 dev kit
and on the com Port because it will only show the
examples according to the development board.
So guys if we come here.
And here you will see examples for the do it esp32 dev
kit. We won and come to the Wi-Fi and
in the Wi-Fi. We have a Wi-Fi access
point example, okay, and click
on that.
and it will be the same because I already have opened that okay, and
here we have our SSID so
you can change it to according to your requirement like
my
ESP 32 LED and
the password will be same you can change it. No worries.
Okay, and the web server will listen on the port 80 but
you can also change it to the port 8080 but by
default is a good to go with that. Okay, and the next
we are enabling the built-in LED
pin mode to the output. So guys we can use
that.
and the operations and the rest is Wi-Fi soft
AP and this is the SSID and
this is the password and it will initiate the excess point,
but this
Method okay and here is the IP address because we
need to get the IP address. Why default by
the way, it's giving 192.168.4.1. Actually
we are not allowing and
that's why esp32 is a
signing that IP address to the
access point, okay
and next the server will be start and in
the loop, the system will wait Wi-Fi
client client is equal to the server dot available and If
client serial.print line and it will
show you all the stuff for already.
I have uploaded the code on the esp32 and you guys
can see here and for you guys. I will just
Firstly I need to clear the output. Okay, and I will
just
press the reset.
button
It's not working. Okay, no worries.
Maybe there are some sort of glitch in that.
and by the way, here is the browser 192.168.4.1 and
if I click on the
yes, there's a one issue with that. Okay,
no worries. We will upload the code again.
Yes, if you see here, there are some sort of delays and
here's the data new client connected and
there's a client request and if I click
you will see here the blue LED turned on
and if I click on the off and it will be off. So
there's some sort of glitch in the which takes
some time. That's why it's not showing all the stuff on
the time and if you see here there is a one another request here
client can comes and this is the URL h
means high and L means low. So
once again, we need to click on the
LED on and off you will see
here. Okay, and
This is the working and for you guys. I need to upload the
code again. So you will get the idea.
There is a bug in the esp32 when it starts connecting. Just press
on the boot Button. So will it move into the
Download mode and start uploading the
code. If you will not press the boot Button on
the esp32. Then there will be error.
So now code has been successfully uploaded to
the board and
we need to verify our AP by clicking on that and
here we will get my esp32 LED.
Okay, and here we will put the password.
your password
and we are good to go with that.
Just now we are connected with that.
Try 192.168.4.1 and
we are good to go with that and if
we see here.
Again, we will type it again.
And yes the request. Is there click on the LED
on LED off and we
are good to go with that example.
Okay guys in the next video. We're going to send the data
to think speak cloud from the esp32 using
the Wi-Fi. So I see you in the next video. Have a good day, bye-bye.