Every data sent via serial communication, there will be rules that make the data can be sent and received properly by the receiving device. In serial communication, Baud Rate is a data transfer rate in units of bits per second bps. If the baud rate is , it means that the ability to send data is bits in one second. This means that within 1 second, baud rat can transfer characters.. The higher the baud rate we will use the more data that can be transferred in 1 second.
This data transfer capability also depends on the baudrate regulation between the sender and receiver. The baudrate value that is set must be the same between the sender and receiver.
Sets the data rate in bits per second baud for serial data transmission. For communicating with Serial Monitor, make sure to use one of the baud rates listed in the menu at the bottom right corner of its screen. You can, however, specify other rates - for example, to communicate over pins 0 and 1 with a component that requires a particular baud rate.
An optional second argument configures the data, parity, and stop bits. The default is 8 data bits, no parity, one stop bit. Line N : Up to ten different Nextion command statements can be created that automatically execute at each timer interval. This provides a convenient way to periodically populate your Nextion display with data from the ESPEasy system variables. Here's an example that updates Progress Bar j1 on page Be mindful that Nextion's Progress Bar component expects an integer value that ranges from 0 to it does not support float values.
A device's value can be easily converted to integer precision by setting the Decimal entry to zero 0 in the Values section of a device plugin. Resend Values at Interval: When selected, the idx and value data is resent at each interval time. Typical applications would leave it unchecked disabled. Send to Controller: If selected the idx and value data will be automatically sent by the active controller using its configured protocol. Interval: Enter the repeating interval time in seconds ; Set to zero 0 to disable the timer.
At each interval time period the Nextion Command Statements are executed. If the Resend Values is enabled then idx and value data are also resent at the interval. Name 1: idx is the main Index key variable. For example, it can be a unique number that is sent by a Nextion touch button that has been is pressed or released.
But it is not limited to that purpose; It may be used for any data that needs to be passed from the Nextion display to ESPEasy. Name 2: value is a sub-variable related to idx. For example, it could contain "1" when a specific Nextion button is pressed, or a "0" when the button is released. The value variable can be ignored if it is not needed.
You are free to choose the format for your application. You can freely mix the different formats in the same application. What you do with the sent data is up to you. For example, use button press data from the Nextion to trigger actions in your home automation system that control your lights, appliances, and gadgets.
0コメント