itead / ITEADLIB_Arduino_Nextion

MIT License
329 stars 320 forks source link

read data from serial #15

Open yo2ldk opened 8 years ago

yo2ldk commented 8 years ago

Hi, how I can to read with arduino interface, data from serial input (RX) and put it on display ? for example, a device send to Nextion numbers from 1 to 9 like 123456789, and I need to see it on diplay. please a sample code..

palivoda commented 7 years ago

use sendCommand, check out hardware.h file in the library. There all you need.

palivoda commented 7 years ago

and if you want to send data from nextion to arduino use something like:

printh 65 01 01 00 ff ff ff <---- this will triget event handler function for page 1 component 1 get vFeedIgnWork.val <---- this you can read with nxRecvRetNumber function