Nextion code is mostly a case of serial type reads and sends… not much else to it, just don’t hog the void loop()
I have a topic here using Blynk and Nextion… it is on an ESP32, but aside form it’s extra serial ports the type of MCU isn’t really relevant, so you should be able to glean some coding ideas from how I wrote mine.
Since my use was only display, my communication needs where simple and I just used a single timed function to do the transmitting to the Nextion.
Also search for other examples, in case they use the touch features as well…