QT 5 designer and Line Graph
-
Hi guys I am using QT5 Designer first time. I have created a simple GUI and I want to display some values on that interface like temperature and all. My question is how I can input the values from the sensor to the text box and how I can create the graph from that, some sort of Temp Vs Time graph.
Would love to know the ways from you people. -
Hi guys I am using QT5 Designer first time. I have created a simple GUI and I want to display some values on that interface like temperature and all. My question is how I can input the values from the sensor to the text box and how I can create the graph from that, some sort of Temp Vs Time graph.
Would love to know the ways from you people.@Crabnewbula You can show text using QLabel, see https://doc.qt.io/qt-6/qlabel.html#text-prop
To show graphs you can use https://doc.qt.io/qt-5/qtcharts-index.html -
Thanks for the reply, I am trying to transmit thermocouple readings(used to measure temperature) to my raspberry pi 4 and then raspberry pi 4 will insert those values into that Label (text box) and the graph will be made from the label values.
-
Thanks for the reply, I am trying to transmit thermocouple readings(used to measure temperature) to my raspberry pi 4 and then raspberry pi 4 will insert those values into that Label (text box) and the graph will be made from the label values.
@Crabnewbula Sorry, but you have to be more specific when asking questions. To me it is unclear where exactly you need help.
-
Ok so this what I am doing. I have attached my arduino uno to Raspberry Pi4 , Arduino is sending some text to my raspberry through serial communication. And I can see the text on thonny IDE. I want that text to be displayed on my GUI of QT5 designer.
So overall, how to send that text from raspberry to my GUI that I built in QT5 Designer. -
Ok so this what I am doing. I have attached my arduino uno to Raspberry Pi4 , Arduino is sending some text to my raspberry through serial communication. And I can see the text on thonny IDE. I want that text to be displayed on my GUI of QT5 designer.
So overall, how to send that text from raspberry to my GUI that I built in QT5 Designer.@Crabnewbula So, you have to implement serial communication in your app first.
Take a look at: https://doc.qt.io/qt-6/qserialport.html
There are also example applications: https://doc.qt.io/qt-6/qtserialport-examples.html -
Thanks a lot I will try and let you know.