Embedded PID Autotuner
In this video, we deploy a PID autotuner to embedded software running on LEGO® MINDSTORMS® EV3 robot to automatically tune gains of a PID controller that provides power to the wheel to regulate its speed.
We use Online PID Tuner block, a new capability in Simulink Control Design™ in release R2017b, to generate the code for the PID autotuning algorithm. We download the generated code to the LEGO EV3. We initialize the PID controller, running at 20 Hz in the LEGO EV3 embedded software, with initial guesses and command step changes in reference speed to evaluate PID controller performance with initial gains. We show that system performance is poor, with large overshoot and oscillations.
We then use Simulink® External Mode to run the autotuning algorithm. The algorithm opens the feedback loop, injects an excitation signal into the plant, measures the output, and uses collected data to estimate plant frequency response. All of this is done in embedded software. The algorithm then computes PID gains for use in the PID controller. We test the new gains by requesting a series of step changes in wheel speed to demonstrate improved controller performance.
Published: 14 Sep 2017
Related Products
Learn More
Featured Product
Simulink Control Design
웹사이트 선택
번역된 콘텐츠를 보고 지역별 이벤트와 혜택을 살펴보려면 웹사이트를 선택하십시오. 현재 계신 지역에 따라 다음 웹사이트를 권장합니다:
또한 다음 목록에서 웹사이트를 선택하실 수도 있습니다.
사이트 성능 최적화 방법
최고의 사이트 성능을 위해 중국 사이트(중국어 또는 영어)를 선택하십시오. 현재 계신 지역에서는 다른 국가의 MathWorks 사이트 방문이 최적화되지 않았습니다.
미주
- América Latina (Español)
- Canada (English)
- United States (English)
유럽
- Belgium (English)
- Denmark (English)
- Deutschland (Deutsch)
- España (Español)
- Finland (English)
- France (Français)
- Ireland (English)
- Italia (Italiano)
- Luxembourg (English)
- Netherlands (English)
- Norway (English)
- Österreich (Deutsch)
- Portugal (English)
- Sweden (English)
- Switzerland
- United Kingdom (English)
아시아 태평양
- Australia (English)
- India (English)
- New Zealand (English)
- 中国
- 日本Japanese (日本語)
- 한국Korean (한국어)