Some will say i'm lazy but i just want to get an answer so i can immediately start looking in the right direction.
Sooo, my goal is to use arduino uno with esp-01, along with some simple sensor on uno like one for temperature or humidity. I want that my esp serve as a acces point so when i connect to its network i will see a web page that will show me data for that sensor along with some data charts , and also i would like to be able to change for example period of time for my charts ...
Now my question would be is it possible to do this with simple AT commands or because of this charts and interactive web page i have to program both uno and esp(using some library) and then make them communicate through serial ?
Of course you can share other tips for this if you like i would be very thankful.
"Of course you can share other tips for this if you like i would be very thankful."
Sure, skip the combining of an arduino with an ESP and get a development board with the ESP built into it. You could use the arduino as a slave too the ESP if needed. Skip the AT command stuff.
"AT" stands for Ancient Technology.
Use something like the Wemos D1 Mini or NodeMCU that already has WiFi. You may discover that you don't even need the Arduino board, but there are several ways that the two can communicate data.
The ESP8266 is a substantially more capable microcomputer than the Arduino. Interfacing to an Arduino such as a UNO/ Nano (better for "real world" projects) is just making problems for yourself. A marginally more expensive ESP can interface - using expansion boards if necessary - easily to your sensors and neatly integrate the WiFi and sensor/ control functions.
OTOH, if you only need four I/O connections, the ESP-01 (and particularly ESP-01s) will do the job very nicely on its own.
Some will say i'm lazy but i just want to get an answer so i can immediately start looking in the right direction.
Sooo, my goal is to use arduino uno with esp-01, along with some simple sensor on uno like one for temperature or humidity. I want that my esp serve as a acces point so when i connect to its network i will see a web page that will show me data for that sensor along with some data charts , and also i would like to be able to change for example period of time for my charts ...
Now my question would be is it possible to do this with simple AT commands or because of this charts and interactive web page i have to program both uno and esp(using some library) and then make them communicate through serial ?
Of course you can share other tips for this if you like i would be very thankful.
Yes it is possible but it is a major pain in the butt.
I did it just to try it, but I certainly would advise using a different module.
ieee488:
Yes it is possible but it is a major pain in the butt.
I did it just to try it, but I certainly would advise using a different module.
Good luck.
So you uploaded a code on Arduino which handle sensor data and send it via serial to esp, and another code on Esp which recieved that data and handle creating a web page with sensor data?
Was your page interactive and enable you to make some changes?
robo17:
So you uploaded a code on Arduino which handle sensor data and send it via serial to esp, and another code on Esp which recieved that data and handle creating a web page with sensor data?
Was your page interactive and enable you to make some changes?
For fun, I followed :
Some important errors in the tutorial which I wrote about in the comments.
I have played a lot with the AT command method. I found that some of the commands have hidden "gotchas" especially concerning timing. I found that out when I tried to re-write the example sketches as non-blocking. Eventually, I gave up and developed my own network sketch that runs on the ESP. It provides a simplified command set (which, unlike the AT set, I can completely define and control) that I interface from another processor, using serial.
Why do I not use the ESP for both functions? Well there can be many reasons. ESP stack doesn't fully support real time I/O. Many libraries won't work for this reason, or need modifications. There are more I/O pins on a second processor. In my case, sometimes I use a secondary processor with onboard RTC. Yes I know you can use internet time. I do, but I also want RTC. Sometimes you need 5V I/O...etc.
robo17:
Because i can't get level converter or any resistors now, is it really necessary to shift RX from Arduino to 3.3V before connecting to TX on Esp.
One mistake, i meant to say to shift TX from Arduino to 3.3V before connecting to RX on Esp
did you use SoftwareSerial to communicate between Arduino and Esp, cause I see that some say that using that library is not good but instead use special "ESP softwarelibrary"?
Some will say i'm lazy but i just want to get an answer so i can immediately start looking in the right direction.
Sooo, my goal is to use arduino uno with esp-01, along with some simple sensor on uno like one for temperature or humidity. I want that my esp serve as a acces point so when i connect to its network i will see a web page that will show me data for that sensor along with some data charts , and also i would like to be able to change for example period of time for my charts ...
Now my question would be is it possible to do this with simple AT commands or because of this charts and interactive web page i have to program both uno and esp(using some library) and then make them communicate through serial ?
Of course you can share other tips for this if you like i would be very thankful.
Since this is a college assignment, there really are no options like just using the ESP and not use an Arduino.
teaching how to use a type of programming or a certain technology, even if it is 'old' like AT commands, increases your depth of knowledge.
There are lots of tutorials on how to use an ESP-01 with an Arduino.
robo17:
Reason I do this is simply because it is an assignment fo college and I have to do it in this way so.....
Interesting.
Well, if it is indeed an assignment for college, then please do us the courtesy of posting the exact and complete text of the assignment you have been given to avoid any further wasted effort on our part.
Well, if it is indeed an assignment for college, then please do us the courtesy of posting the exact and complete text of the assignment you have been given to avoid any further wasted effort on our part.
I don't have an assigment in some written format.
I have to use sensor(bme680) that will be directly connected to Arduino along with Esp-01 that will serve as an Acces Point. Goal is to have a web page that will show sensor reading in some chart format and user will also be able to change for example period of time that will be shown in chart so it must be interactive page.
User will simply connect his mobile with Wi-Fi network(no password) provided by esp.
robo17:
I don't have an assigment in some written format.
I have to use sensor(bme680) that will be directly connected to Arduino along with Esp-01 that will serve as an Acces Point. Goal is to have a web page that will show sensor reading in some chart format and user will also be able to change for example period of time that will be shown in chart so it must be interactive page.
User will simply connect his mobile with Wi-Fi network(no password) provided by esp.
If you don't have a written assignment, only a goal, then why must you use and Arduino plus ESP-01? As stated before, the Arduino plus ESP-01 is the hard way.