As an engineering student, I always loved to play with lab equipment. I have fond memories of building my very first controller to swing-up and balance an inverted pendulum in the last year of my undergrad. We were tasked to design a controller from scratch in Matlab/Simulink, test it with a system model and eventually implement it on the real hardware. I remember how I had discussions with other students about what assumptions we are using about the systems, how we could improve our model to get a better response and how to make our controller more “robust” for the real implementation. In the end, it all worked wonderfully well and I was hooked on Control Engineering.
Fast forward several years, lectures and hours in various labs and I am more and more amazed that it all worked. The one thing nobody seemed to have considered at the time was that we’re actually dealing with a discrete system and are using a digital controller to drive the hardware and stabilize the pendulum. Nobody was worried that their controllers designed for a continuous model would not work (or work well) in a digital implementation or that we didn’t have to design analog circuits to get real continuous controllers. Even nowadays, with superfast microprocessors available for only a few dollars, all they do in the end is running according to a (very fast) clock signal, but by no means in actual real-time.
Intuitively, it is clear that a controller’s performance running at a few megahertz will be hardly distinguishable from one that is purely continuous. However, it is also clear that implementing a continuous controller at very slow sampling rates will inevitably fail. In particular for a PID controller, we know that we are happy to deal with the discrete equivalents of the proportional and integral part of the controller, but what about the derivative part, in particular with respect to measurement/system noise and quantization errors in the feedback signal?
|
Students at Queen's University test the new digital control curriculum during their Modeling and Computer Control of Mechatronic Systems Course |
To answer these questions (and more), Quanser has started to design a lab sequence to introduce students to common problems that are inherent to
digital controller implementations. In particular, we’re investigating what effects different sampling rates have on the performance of a continuous PD position controller for the
SRV02 Rotary Servo, how a continuous control design can be used as a starting point for a purely digital controller using the Matched-Zero-Pole mapping method for different sampling rates, and how to design a pure digital controller directly (and what the implications of different sampling rates on the design process). Furthermore, there is also a lab that investigates typical hardware implementation issues such as quantized measurement signals and buffer overruns. The overall goal is to enable the students to deal with real-world control constraints in their own hardware implementations, and therefore include discussions on how the lab material can be implemented in a programming environment (in high level pseudo-code).
My colleague Amir Haddadi and I had the chance to present the first part of the new lab sequence as part of Prof.
Keyvan Hashtrudi-Zaad’s course on Modeling and Computer Control of Mechatronic Systems at
Queen’s University in Kingston, Ontario last week. We were able to get the students started with the new curriculum in a hands-on lab on digital control, and the consensus seemed quite positive. A few students pointed out how the lab has helped them understand some of the theory discussed during the lectures and that they believe the labs will be beneficial for their upcoming design and research projects. We’ve also received valuable feedback from the students and TAs on the lab material and will implement it over the upcoming weeks.
At the moment, the first draft of the digital control labs is only available for the SRV02 Rotary Servo MATLAB/Simulink platform. Future releases will include an offering for LabVIEW, as well as for the Quanser
QUBE-Servo platform (both MATLAB/Simulink and LabVIEW).