Abstract:
In view of the comprehensive design experiment course, an experimental system of small ball balance control is developed. The system, with the STC12C5A60S2 as the core processor of the system, adjusts the wind speed through the adjustment of the peripheral PWM duty cycle. The ultrasonic measuring distance sensor is used to measure the position of the small ball in the tube and give feedback to the MCU. Next, the MCU calculates the PWM duty cycle needed to drive the fan via PID algorithm, thus forming a complete closed-loop control system. The whole system, adopting the Z-N coefficient method in the PID parameter tuning, realizes the fast and stable control of the small ball in the central location.