Have you looked at the examples on the Nextion web site? Watched any YouTube videos? There are many out there and you should be able to figure it out pretty easily.
On the MCU side it’s easy to send data to the HMI and to listen for it coming back, and just as easy for the HMI to send a string of data on a touch event.
The Displays are good, but the Arduino library is total crap. Severeal lines of code are needed for just one button. The library hasn’t been updated for years. New Display functions like float ar not implemented therefore. Does anybody know a good alternative library? I tried to contact ITEAD, but that seems to be impossible to me. I had to create a account first wich was disabled immediately after creation. So a contact wasn’t possible. That company appears very weird to me.
Since the xfloat component is just a normal number field with additional attributes for the virtual decimal point, it should not be too difficult to duplicate and then extend the corresponding library object. BTW: In many real world applications (using other environments than Arduino, I admit), I prefer not using any library at all, the communication protocol with Nextion is so simple that it can be implemented on the fly.
This forum is in no way affiliated with NEXTION®, ITEAD STUDIO®, TJC®, or anyone else really. All product names, logos, and brands are property of their respective owners. All company, product, and service names used in this website are for identification purposes only. Use of these names, logos, and brands does not imply endorsement from the respective rights holder(s).