Hello everyone. I've bought an ESP8266 CP2102 NodeMCU LUA ESP-12E WIFI Serial Wireless Module from Amazon.com
I can successfully blink a LED using the ESP-12E with the Arduino IDE without flash the ESP-12E.
I wish to change the baud rate of the ESP-12E from 115200 to 9600. I'm not sure the initial baud rate of the ESP-12E is 115200 or not but I can only see the output of the serial monitor at the baud rate of 115200 so I guess it is.
Can anyone tell me how to do so? Thank you.
And I've tried to upload the blink sketch with the upload speed '115200' and '9600'. Does the upload speed matters?
You set the baud rate for serial communication from your sketch using Serial.begin():
The upload speed is completely unrelated to that.
For the ESP32 under tools Upload Speed there are several options for upload speed. The upload speed, for the ESP32, is also affected by the Tools | Flash Mode setting. Perhaps the 8266, I don't own one, has similar options?
pert:
You set the baud rate for serial communication from your sketch using Serial.begin():
Serial.begin() - Arduino ReferenceThe upload speed is completely unrelated to that.
So is this means that I can set the baud rate to 9600 using 'Serial.begin(9600)'?
After that, I can straight connect the ESP-12E to the Arduino Robot Control board and configure the NeoSWSerial library to use those pins?
Idahowalker:
For the ESP32 under tools Upload Speed there are several options for upload speed. The upload speed, for the ESP32, is also affected by the Tools | Flash Mode setting. Perhaps the 8266, I don't own one, has similar options?
The ESP8266 core does have a Tools > Upload Speed menu, but that is not relevant to this discussion.
Sin2:
So is this means that I can set the baud rate to 9600 using 'Serial.begin(9600)'?
After that, I can straight connect the ESP-12E to the Arduino Robot Control board and configure the NeoSWSerial library to use those pins?
I think it's time that you provided a complete and detailed explanation of what you are trying to do. Are you trying to change the baud rate of the ESP8266 AT firmware, or are you writing a custom sketch that you are going to upload to the ESP8266?
pert:
I think it's time that you provided a complete and detailed explanation of what you are trying to do. Are you trying to change the baud rate of the ESP8266 AT firmware, or are you writing a custom sketch that you are going to upload to the ESP8266?
Well. I plan to send the outputs from node-RED to the ESP-12E and the ESP-12E will control the movement of the Arduino Robot (e.g. move forward).
ESP-12E: https://www.amazon.com/HiLetgo-Version-NodeMCU-Internet-Development/dp/B010O1G1ES/ref=cm_cr_arp_d_product_top?ie=UTF8
Arduino Robot: https://www.arduino.cc/en/Guide/Robot
I've bought the ESP-12E and it can blinks a LED without flashing any firmware into it. So I'm curious can I directly use it to configure with the NeoSWSerial library and writing a sketch which will be upload to the ESP-12E.
Besides, I also discover the ESP Easy firmware. Can it be used in the plan since it mentioned no coding needed to control the ESP-12E?
The upload baud rate you set in the IDE. I normally simply set it as high as it allows; it'll negotiate the fastest possible with the IDE.
The Serial port speed for communications from your sketch is what you set it to be in your Serial.begin() call.
wvmarle:
The upload baud rate you set in the IDE. I normally simply set it as high as it allows; it'll negotiate the fastest possible with the IDE.The Serial port speed for communications from your sketch is what you set it to be in your Serial.begin() call.
I need to set it to 9600 since the maximum baud rate for the NeoSWSerial library is 38400 and I need to use NeoSWSerial library in my project.
If you're writing your own sketch (or using someone else's sketch) and uploading it to the ESP8266, then you can set the communication baud rate to anything you like via Serial.begin(). In the case of ESP Easy, I don't have any experience but I see it is an Arduino sketch so the same should apply.
The reason I had asked about the AT firmware is because it's common for people to want to change the baud rate down from the default 115200 so they can communicate with the ESP8266 using software serial. In that case, you don't have the option of modifying the AT firmware and uploading it to your ESP8266 (because it's not a sketch) so you have to use the correct AT command to change the baud rate. Since it sounds like you have no plans to use the AT firmware, that issue does not apply to you.
pert:
If you're writing your own sketch (or using someone else's sketch) and uploading it to the ESP8266, then you can set the communication baud rate to anything you like via Serial.begin(). In the case of ESP Easy, I don't have any experience but I see it is an Arduino sketch so the same should apply.The reason I had asked about the AT firmware is because it's common for people to want to change the baud rate down from the default 115200 so they can communicate with the ESP8266 using software serial. In that case, you don't have the option of modifying the AT firmware and uploading it to your ESP8266 (because it's not a sketch) so you have to use the correct AT command to change the baud rate. Since it sounds like you have no plans to use the AT firmware, that issue does not apply to you.
Okay, I think I understand what you are trying to say. Let's me conclude this. So I can write my own sketch and upload to the ESP8266 to control the movement of the robot without flashing any AT firmware and the baud rate of the ESP can be set to 9600 via Serial.begin(). Is that correct?
Yes
OKay. Thank you for the helping.