Creating your own IoT Cloud from scratch using php, Mysql, ESP12E

Creating your own IoT Cloud from scratch using php, Mysql, ESP12E – Part 4

Introduction:

In this tutorial, we will be Creating your own IoT Cloud from scratch using php, Mysql, ESP12E. This is part 4 of tutorial series. If you are seeing this tutorial directly then I will recommend you to read the Introduction of this tutorial first.

So in part 4 of "Creating your own IoT Cloud from scratch using php, Mysql, ESP12E", we will be controlling three led connected to our esp12e or nodemcu module through an HTML webpage. We will be scripting in javascript and also we will be using css for our HTML page. In the part 2 of tutorial, we have already created the api's to control led. We are not going to consume those api's to control our esp12e or nodemcu module.

Circuit Diagram and Breadboard Image

So start of by making the circuit on the breadboard. Refer the below image for reference.

 

Video

Now watch the below video. I have given step by step instructions in the video:

Code

PHP Api Code

Copy the below code and replace it in the "read_all.php" file which we created on our webhost server.

Arduino Code

Copy the below arduino code and program your esp12e or nodemcu with it. Make sure that you replace the wifi username, password and the webhost url.

 

HTML Code

Copy the below code and paste it in a notepad++ file, and save it as 'index.html'. Make sure that you have replaced webhost url in the code.

Support me by subscribing to my YouTube channel by hitting the below button.

youtube-iotmonk-subscribe

Please login to get access to the quiz
Creating your own IoT Cloud from scratch using php, Mysql, ESP12E – Part 3 (Prev Lesson)
Back to Creating your own IoT Cloud from scratch using php, Mysql, ESP12E

Comments ( 2 )

  • Ovan

    Hi, your tutorial is great and detailed. I have perfectly done it. And i have a question. Can the weather and led Arduino code combine together to become one and send to the ESP-12E to work it?

    • Offcourse you can do it.

Post a Reply