Hi i need connect ESP with Nextion displey.
But i dont know what pins i can use.
Nextion - ESP
RX - TX D10 GPI03
TX - RX D9 GPI01
And what i use in sketch. ?
//SoftwareSerial HMISerial(3,1,false,256); //nextion lcd on pins 5 and 4
//SoftwareSerial nextion(1, 3, false, 256);// RX,TX
http://support.iteadstudio.com/support/discussions/topics/11000008495/page/2?url_locale=
THanks.
The Nextion is a Serial protocol device, so you can use software serial to attach it. I’m not sure how stable it is. I’ve got a Nextion display and I must say I’m not fond of the software and the general quality of the screen. It can output simple serial commands, so handling that should be no different than from any other serial in/output
Gunner
February 8, 2017, 10:52am
3
You might get better traction using Google for this question as it is not Blynk specific.
For example…
https://hobbytronics.com.pk/noobs-guide-to-nextion-displays/
I recommend getting it working together using basic Arduino sketches, then work toward Blynkifying it.
1 Like
Lichtsignaal:
The Nextion is a Serial protocol device, so you can use software serial to attach it. I’m not sure how stable it is. I’ve got a Nextion display and I must say I’m not fond of the software and the general quality of the screen. It can output simple serial commands, so handling that should be no different than from any other serial in/output
Ok Thanks . Here someone used D4 and D9. http://www.plastibots.com/index.php/2017/01/03/wiot-2-weather-station-nextion-tft-with-esp8266/
Got my info from there too, he’s a good guy. I think he’s on the forum here too, though I think I haven’t seen him in a while
Gunner
February 8, 2017, 10:55am
6
Who? Mr Google I communicate with him daily.
Gunner
February 8, 2017, 10:58am
8
Ha… got ya!
I just Googled the title of this post and grabbed a few quick links to show how easy it is to find the answers being looked for.
Ok. So if i use:
so i in sketch will write : SoftwareSerial HMISerial3,1, false,256);
No, if you do it like that you will have hardware serial because you attached it to the hardware serial ports of the ESP
Ok. And if this:
I can will use:SoftwareSerial nextion(2, 3, false, 256);
?
Blue is TX on Nextion.
No, there is still one pin attached to the hardware pin of the MCU. Either you both attach them to digital pins or both to hardware pins.
SoftwareSerial nextion(2,3)
means: tx/rx pins are on pin d2 and pin d3 of your MCU. This will never work
Costas
February 8, 2017, 11:14am
13
I was only thinking yesterday that it’s time for an extra category on this site.
Perhaps “Hardware” or “Off- topic”?
Obviously “Need Help With My Project” covers these sort of issues but really this category should be Blynk related.
Agreed, we love to help of course, but this sort of questions may lead away from the essence of what we are here for, and that is Blynk.
Ok. So can i Nextion connect to tx/rx : D2/D3 ?
And i have use SoftwareSerial nextion(2,3)
or SoftwareSerial nextion(2, 3, false, 256);
? Thanks.
Yeah and it would look a bit like this:
SoftwareSerial nextion(2,3);
void setup()
{
nextion.begin(9600); // or what ever baud you set your nextion to
}
This is how you would make a software serial connection to a device
Costas
February 8, 2017, 11:33am
17
Forgot we had a “Hardware” category and OP has correctly moved it from the “Help” category.
I used this for arduino uno SoftwareSerial nextion(2, 3);// Nextion TX to pin 2 and RX to pin 3 of Arduino Nextion myNextion(nextion, 9600);
So i was think for connect to ESP i need use different pins… So 2,3 are D2 and D3 on ESP devkit?
THanks.
Costas
February 8, 2017, 12:03pm
19
2 and 3 are the GPIO references in the table of your first post. You can’t use 2 and 3 as ESP’s don’t have a 3.
Use 4 and 5 which are D2 and D1.
Ok. I try D2 to RX and D1 to TX. SoftwareSerial HMISerial(4,5); // RX,TX
And i will write how is it working.