From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Closed-loop transfer function - thermostat

Solved!
Go to solution

Hello,

I want to present you my program for thermostat. I did it as my bachelor thesis. Here is the annotation so you know what is it about.

 

Annotation Lušková, Lenka. Simple thermostat for teaching closed-loop transfer function. Hradec Králové, 2016. Bachelor thesis. University of Hradec Králové, Faculty of Science. Leader of the Bachelor Degree Thesis: RNDr. Daniel Jezbera

 

The aim of the work is to design and programme simple program designed for practical class students. Its function will be proved by a measurement for various parameters. A theory of heat, closed-loop function and LabView will be described in theoretical part. There will be detailed description of LabView programs for calibration and closed-loop function in practical part.

labview.jpg

I renamed every component in the VI to english. Hopefully, you'll understand what I did.

0 Kudos
Message 1 of 5
(3,182 Views)

It is a good thing that I am not on your Thesis committee, as I would not allow such "beginner" LabVIEW code to be presented as part of a Thesis that purports to instruct other students in the "theory of ... LabVIEW".  

 

Have you taken the Core 1, 2, and 3 tutorials?  Have you ever heard of a sub-VI?  Why is there MathScript in your LabVIEW code?  Why are you using the Dreaded DAQ Assistant, and its Evil Twin, the Dynamic Data Wire?  Do you know about DAQmx?  Why is there a Tab Control?  Where is the Icon for your VI?  Where is the Description for your VI?

 

Find someone at your Institution who really knows LabVIEW (hereafter referred to as a LabVIEW Guru) and who has designed reasonably-complex routines (such as ones having at least 100 VIs and 30 TypeDefs), and ask if you can "apprentice yourself" to her (or him) in order to become somewhat proficient in LabVIEW.  Then design (write the Documentation first) your Thesis Project (which, of course, starts by creating a LabVIEW Project) and start creating sub-VIs and Type Definitions.  Learn proper Front Panel design (Tab Controls are rarely advised).  Learn about things like State Machines and the Queued Message Handler.  Consult your LabVIEW Guru, and learn LabVIEW.

 

Bob Schor

Message 2 of 5
(3,163 Views)

Hi leni,

 

some comments:

- have you ever used AutoCleanup on your block diagram?

- replace that formula node by a simple case structure: much cleaner code!

- the "top" variable of this formula node should be a boolean value! (Then you don't need that "==1" comparison after the formula node!)

- why do you setup DAQAssistant3 to output 5 DO signals when your code is using only one DO?

- your "chart" is named "graph"…

- replace the DDT wire by a scalar DBL wire!

- I would replace all DAQAssistant ExpressVIs by plain DAQmx functions!

- replace the TimeDelay ExpressVI by a simple Wait(ms) (or WaitForNextMultiple)

- enable the additional digital display for your chart and get rid of the numeric "Temperature" indicator…

- the same applies for voltage chart and "U" indicator…

- the tab control can be placed outside the loop

 

Edit: I agree with Bob - I wouldn't give you a degree for this representation if I were your teacher…

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
Message 3 of 5
(3,160 Views)

Thank you both for your points to improve my work. This was my very first program and my committee didn't really care about the program itself but mostly about the physics behind it. Since I'm physics major. 

 

I'm mostly self taught in Labview and I found DAQ Assistant the easiest way to do anything. I just don't understand what is so wrong with Express functions. They work so why wouldn't I use it?

 

Thank you for the Auto Cleanup suggestion, I didn't know about that before. It will become very handy in my new set of programs.

0 Kudos
Message 4 of 5
(3,151 Views)
Solution
Accepted by topic author lenithemonster

Hi leni,

 

 I just don't understand what is so wrong with Express functions. They work so why wouldn't I use it?

- they hide important stuff from direct view because they use some configuration dialogs

- they do more stuff than needed, especially when you configure them wrong (like your DO assistant)

- they use DDT wires, which also hide important information from direct view…

- especially DAQAssistant is known to give problems once you try to make "professional" software (and create executables)

 

Thank you for the Auto Cleanup suggestion, I didn't know about that before.

That's why Bob recommended to take the beginner courses…

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
Message 5 of 5
(3,145 Views)