@@CheapControls I now have a sensor that is automatically uploaded through the serial port in an ASCII fixed format. The data has three decimal places. I assign the data to the text control after receiving the data. Now I want to achieve average filtering after receiving the data multiple times and then display it. The decimal part of the text control How do I get it? Here I ask you for advice, thank you for your answer
What is sending the data? Is direct from the sensor or is the sensor connected to an MCU and the MCU sending the data to the Nextion. It would be easier to do the averaging prior to sending it to the Nextion, if you can. Other wise you will have to remove the decimal point, convert to integer, do the math, convert back to text and reinsert the decimal point.
I want to create a colored table in display and i’ve managed to show my sensor output on display by color with changing the buttons color but i want to have 50 section that i can change color of each of them but i dont know how should i work around of strings i have to send to display , i tried to use arrays but it dosent work with string. does any body know how should i do this ? thanks exp: if(current11 && current22 && current33 && current44 && current56 && current67 && current78 && current89 && current
You sent me this. It should work but you should use id values instead of the element names. If you place the boxes on the display in order they will get sequential IDs. then you can loop through the IDs with a counter on the Arduino. This video shows how to do this th-cam.com/video/azEXRHXKZQU/w-d-xo.html
文本字符串数据如何扩展?比如4.678化成4678
I am not sure what you are asking. Do you want to add a decimal point?
@@CheapControls I now have a sensor that is automatically uploaded through the serial port in an ASCII fixed format. The data has three decimal places. I assign the data to the text control after receiving the data. Now I want to achieve average filtering after receiving the data multiple times and then display it. The decimal part of the text control How do I get it? Here I ask you for advice, thank you for your answer
What is sending the data? Is direct from the sensor or is the sensor connected to an MCU and the MCU sending the data to the Nextion. It would be easier to do the averaging prior to sending it to the Nextion, if you can. Other wise you will have to remove the decimal point, convert to integer, do the math, convert back to text and reinsert the decimal point.
@@CheapControls sensor I can't control it, no MCU for transition, directly to nextion, I've done it, thanks
Glad to hear you got it.
I want to create a colored table in display and i’ve managed to show my sensor output on display by color with changing the buttons color but i want to have 50 section that i can change color of each of them but i dont know how should i work around of strings i have to send to display , i tried to use arrays but it dosent work with string. does any body know how should i do this ?
thanks
exp:
if(current11 && current22 && current33 && current44 && current56 && current67 && current78 && current89 && current
You sent me this. It should work but you should use id values instead of the element names. If you place the boxes on the display in order they will get sequential IDs. then you can loop through the IDs with a counter on the Arduino. This video shows how to do this th-cam.com/video/azEXRHXKZQU/w-d-xo.html
its so bad that you cant set the text position if you want to stop scrolling it
I am not sure but I think you can go to the Nextion official website and submit things you want to see in future versions.