Academic Hardware Products (myDAQ, myRIO)

cancel
Showing results for 
Search instead for 
Did you mean: 

PID Temperature Controller with myRIO

I am interested in implementing the LabVIEW PID VI to create a temperature controller using the myRIO for a sous vide cooking apparatus similiar to this: https://learn.adafruit.com/sous-vide-powered-by-arduino-the-sous-viduino/sous-vide. I will be using a slow-cooker as the heating element; for the temperature measurements, I am using the DS18B20 one-wire temperature sensor; and to alter the temperature I am using a relay connected to the slow cooker.

 

I have had success getting temperature measurements from the DS18B20 with the myRIO following the guidance of this thread: https://decibel.ni.com/content/docs/DOC-41626#comment-44403, however, I am having difficulty finding a starting place to learn how to use the PID VIs for the rest of the project. In a new VI file, I used the program I had used for the temperature readings as a subVI, and tried to connect its output containing the live numerical temperature measurements into the PID VI, but the live temperature measurements as well as the PID VI output are not being transmitted after running the program.

 

Here are a few more specific questions:

  • Are there any preliminary steps for creating a PID program to accept live measurements from a myRIO target (should the program be enclosed in a loop for continuous updating of myRIO measurements)?
  • What information is transmitted at the "output" terminal of the PID VI?
  • Is autotuning recommended for this type of application?
  • How does the "PID Autotuning" VI differ from the "PID Autotuning (Temperature)" VI?

 

I have attached the files I am currently working with: ("1-wire interface.lvproj" is the project file, "RT Main.vi" is the temperature reading program, "PID_Test" is the new PID VI file I am experimenting with).

 

If the content in this post is not appropriate to what is expected to be asked in the forums (not specific enough, etc.), please let me know and I apologize in advance. Thank you for your time and assistance!

0 Kudos
Message 1 of 2
(5,695 Views)

Hello dpull,

 

There shouldn’t be any particular configuration that needs to be done, for the PID vi to start using the PID VIs, and if you desire to continously acquire the data from the myRIO, then this within a loop might be appropriate.

 

The output terminal transmits the control signal of the PID controller, so basically the action that would have to take place to take the desired value to the setpoint.

 

As far as recommending autotuning, it mostly  depends on your application and the precision you need, it would always be better to determine the parameters yourself, but if you don’t require super high accuracy, then autotunning should be sufficient.

 

The PID autotunning (Temperature) VI is used for processes that include a dead time, since it’s incorporated into that model, the other one is better suited for processes that don’t have dead time.

 

As far as resources go for learning to use this toolkit, I’d recommend sticking to the examples you can find in LabVIEW and maybe the following manual.

 

http://www.ni.com/pdf/manuals/372192d.pdf

0 Kudos
Message 2 of 2
(5,549 Views)