I'm trying to test my ESP8266 module with an Arduino Uno R3, but the AT command isn't having any result in the serial monitor. I tried baud rates 9600 and 115200, even 74880 baud. I also used Both NL & CR. Typing a simple AT doesn't tell me OK. I can't figure it out. Here's a weird drawing of my wiring:
initially run a loopback test - connect pins 8 and 9 characters entered on the serial monitor keyboard should echo back to the display
if that works then connect the ESP-01
any particular reason to us a UNO? the IO on the ESP-01 is very limited but it can support simple projects, .g. reading a I2C interfaced sensor and uploading data to a website
What exactly is this, and what do they look like and which one should I use? I think I have some but idk how to use them.
It's just what's on hand. I got it like 6 years ago and I'm getting into some projects now. Don't really want to buy another board just for this project because the Uno has been working fine for other basic projects (LCD, buzzer, LED, etc).
Wait, so, am I supposed to have more than 4 pins (on the ESP8266)? Because I have to the side of the module, 4 pins, but then there's 8 that go up. This picture is pretty much what mine is:
The board you are showing is an adapter for connecting an ESP-01 to an Arduino. It has a 3.3V regulator and level shifting for the serial pins. It only supports serial I/O with the Arduino.
perhaps it is time to move on
in particular if you are looking to use radio a ESP32 has builtin WiFi, Bluetooth Classic and BLE, plenty of flash, SRAM and IO capabilities
it does use 3,3V logic so care has to be taken connecting 5V logic sensors etc
the ESP-01 supports WiFi - the UNO generally communicates with the ESP-01 using serial as stated by @oldcurmudgeon
the UNO can use the WiFi by using the WiFiESP library (which sends AT commands to the ESP-01) or you load you own program into the ESP-01 and the UNO communicates with it using your own protocol
if you do wish to program the ESP-01 I find the ESP-01 helper module very useful - no changing switches between program and run and has a clone connector to attach external devices
still think you are making life complicated by using an ESP-01 to add WiFi functionality to a UNO
simpler to dump the UNO and use an ESP32 (cost about £7 in UK) or ESP8266 (cost about £4 in UK)
I have a project where I use an ESP-01 to provide a browser interface to an ATmega1284P board. The AVR board has onboard hardware for data collection and logging (Mayfly board for those interested). We originally used the USB serial interface for controlling it. This was a real pain because you had to open the sealed box to connect the cable for data download.
We eventually used an ESP-01 on the serial port to replace the cable interface. (The WiFi and web server interface running on the ESP-01 is about 1000 lines of code.) This had several advantages.
No opening and resealing the box for data download
No need to carry a laptop to the field - with the browser interface a cell phone can be used to download data
Only need to get "close" to the box to download data - it is a river monitor so some installations are harder to get to
There are some major drawbacks (from the development standpoint)
Splitting function between two processors
Two processors have to synchronize and communicate
Two sets of code to maintain
If I were doing it today I would replace the Mayfly board with an ESP32. A few years ago I looked at replacing it with an ESP8266, but we already had 10 systems built so it wasn't worth the trouble.
A dedicated ESP has all the advantages with none of the drawbacks. So unless you have a significant investment in the Arduino side forget the ESP-01 and go with a larger ESP module and do all your code on one processor.
this is always a problem with legacy systems which need to be upgraded with extra sensors, relays, modern technology, etc etc - this is particularly a problem if there are systems out in the world to be maintained etc
does one add the new functionality to the existing system which can end up with a maze of IO extenders, external ADC/DAC modules, I2C extenders, wireless modules,, etc etc with implications for running out of flash and SRAM memory, overloading power supplies, etc
or using the existing system to draw up a requirements specification to implement a system based on new technology
the decision is not easy - both options can involve a lot of work
recently moved a system based on PIC24 microcontrollers to an ESP32 based system - 90% of the C code ported across OK the main problem was adapting to use the ESP32 IO libraries
have you tried a simple test using just a UNO and ESP-01? using the WiFiESP library can you connect to your local WiFi and make a HTTP request
Which is why I mentioned significant investment in your current system.
What is the user interface? If it is a serial terminal then an ESP-01 could be used to convert that to a web interface by translating between the serial command/response and web pages. This is what we did with the river monitor project. The end user experience is much better because they can use a web interface rather than knowing a bunch of arcane serial terminal commands.
When I mentioned the 1000 lines of code I didn't mean to scare you, but to show the possibilities. Much of the code is HTML which is static. It provides a lot of function.
Root status page
Directory listing of SD card page
File download page
Sample rate page
Sensor calibration page (not used by normal users)
WiFi active pages (days and time WiFi is on - to save battery)
Time set page (sets RTC to browser time)
Many projects would have a simpler interface and less code.