PID Controller- not for simulation
3 ビュー (過去 30 日間)
古いコメントを表示
I want to build an application in Matlab for controlling temperature, by using NI TC-01 thermocouple and a peltier cooling plate, connected through an RS-232 controlled power supply.
To stabilize the temperature I'd like to use the PID tools in Matlab 2012b, but they all seem to be used only for simulation purposes.
Is there a way to use pid objects in Matlab scripts for working (non-simulation) purposes? (e.g. connecting the pid object to periodically-updated workspace variables)
Thanks!
2 件のコメント
Arkadiy Turevskiy
2013 年 2 月 25 日
Can you clarify a bit more? Do I understand correctly that you want to use something like Data Acquisition Toolbox and Instrument Control Toolbox to get the temperature into MATLAB, apply PID controller, and output voltage?
If this is what you are trying to do, then pid objects do not really support this workflow. The way to do this would be through Simulink PID Controller block.
Arkadiy
回答 (2 件)
Azzi Abdelmalek
2013 年 2 月 25 日
What is your goal in using a numeric pid, which can be done by matlab for real application, insteat of an analogic pid controller?
Arkadiy Turevskiy
2013 年 3 月 18 日
編集済み: Arkadiy Turevskiy
2013 年 3 月 18 日
Based on your clarification, it seems you want to do real-time control of the actual process. A typical workflow for that: model the process in Simulink, design and test PID controller in simulation. Once testing through desktop simulation is done, you can deploy the controller in real time using one of many different techniques.
- Most general way is to generate C code using Embedded Coder and download the code to the embedded processor.
- If you want to control from the same machine that runs MATLAB and Simulink, you might be able to do it with Real-Time Windows Target. Based on your questions, I think this is the option that you are looking for. More details here.
HTH.
Arkadiy
0 件のコメント
参考
製品
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!