How to transmit parameters to PID controller in simulink

2 vues (au cours des 30 derniers jours)
Renata Pan
Renata Pan le 22 Sep 2015
Modifié(e) : Renata Pan le 24 Sep 2015
My PID parameter value Kp, Ki, Kd has to be calculated through other port in my simulink graph, but I don't know how to achieve this.
I saw this picture in Mathworks:
And I think it may work, but I don't know how to set the PID controller in libraries becomes like this. Thank you for taking time to read my question.

Réponse acceptée

Sebastian Castro
Sebastian Castro le 22 Sep 2015
Configuring the PID Controller block in this way is new to R2015a, so if you have an earlier version you won't be able to do this. If you are on R2015a or R2015b, there should be a "Source" menu in the block dialog which you can change to external.
If you're on an earlier version, you can still implement this yourself. Right-click the PID Controller block and select "Mask > Look Under Mask". This will show you how the block is implemented, so you can replicate that diagram and replace all the Gain blocks with Product blocks, one of the inputs being a port to an external output.
- Sebastian
  1 commentaire
Renata Pan
Renata Pan le 24 Sep 2015
Modifié(e) : Renata Pan le 24 Sep 2015
Thanks, Sebastian. Very clear and helpful.

Connectez-vous pour commenter.

Plus de réponses (0)

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by