MATLAB Answers

Inactivate PID controller for 3 seconds

조회 수: 2(최근 30일)
Matt Hinesley
Matt Hinesley 2021년 7월 12일
댓글: Mathieu NOE 2021년 7월 12일
I have set up a PID controller to control wheel speed by manipulating torque on a wheel, but I would like this PID controller to kick in at t=3 seconds and output a torque of 0N*m until then. After t=3s, I would like the PID controller to function as if there was never any delay if that makes sense. I have tried the delay blocks, but the problem with those is that at any time t, the PID controller is using speeds from 3 seconds ago and not the current wheel speed. Is there a way to simply inactivate my controller until 3 seconds have passed and then have it function as normal?
Below is a screenshot of my feedback loop thus far:

채택된 답변

Mathieu NOE
Mathieu NOE 2021년 7월 12일
hello
simply add a switch block at the input side of the PID
the first signal (input) of the switch is zero, the second is the error torque
use a step signal to switch from the zero to error signal at time t = 3 s , so the PID will start to work after t = 3 s
  댓글 수: 2
Mathieu NOE
Mathieu NOE 2021년 7월 12일
My pleasure

댓글을 달려면 로그인하십시오.

추가 답변(0개)

제품


릴리스

R2021a

Community Treasure Hunt

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

Start Hunting!

Translated by