摘 要:本系统以 STM32 为核心控制芯片,由姿态采集模块、风力摆模块、人机交互模块及机械结构组成闭环控制系统。姿态采集模块采用六轴加速度陀螺仪 MPU6050,采集姿态数据后通过内部集成的 DMP 处理单元进行姿态角的解算。STM32 根据解算得到的角度计算风力摆的状态,通过调节各状态量 PID 参数实现对风力摆摆动幅度和线性度的控制,将输出量和输入量进行线性分解,控制风力摆完成按指定轨迹运动。本系统受到外部干扰后能快速恢复到指定状态。
关键词:风力摆;STM32;MPU6050;PID
DOI:10.19850/j.cnki.2096-4706.2021.14.018
中图分类号:TP273 文献标识码:A 文章编号:2096-4706(2021)14-0068-04
Design of a Wind Pendulum Control System Based on STM32
BI Tao, GE Baochuan, LIU Di, YANG Lili
(School of Basic Science for Aviation, PLA Naval Aviation University, Yantai 264001, China
Abstract: This system takes STM32 as the core control chip, and consists of attitude acquisition module, wind pendulum module, human-computer interaction module and mechanical structure, forming a closed-loop control system. Six axis acceleration gyroscope MPU6050 is used in the attitude acquisition module. After collecting the attitude data, the attitude angle is calculated through the internal integrated DMP processing unit. STM32 calculates the state of the wind pendulum according to the angle obtained by the solution, controls the swing amplitude and linearity of the wind pendulum by adjusting the PID parameters of each state quantity, linearly decomposes the volume of output and input, and controls the wind pendulum to move according to the specified track. The system can quickly recover to the specified state after external interference.
Keywords: wind pendulum; STM32; MPU6050; PID
参考文献:
[1] 王平,张新东 . 基于智能仪表的数据采集系统设计 [J]. 自动化与仪表,2009,24(4):9-10+18.
[2] 王云飞,张凯,田亚芳,等 . 基于 STM32 的简易多功能液体容器的设计与制作 [J]. 电子制作,2020(19):21-24.
[3] 杜里,张其善 . 电子装备自动测试系统发展综述 [J]. 计算机测量与控制,2009,17(6):1019-1021.
[4] 邢兰昌,祁雨,刘昌岭,等 . 电 - 声 - 热多参数联合测试系统开发 [J]. 实验技术与管理, 2017,34(11):78-85.
[5] 李惠,徐小川,于学伟,等 . 基于 STM32 的智能发电机电参量测量装置的设计 [J]. 电测与仪表,2016,53(2):125-128.
[6] 康婷霞,牟丽霞 . 基于 STC8A8K 的智能 LED 灯条检测仪设计 [J]. 电子测试,2020(6):24-26.
[7] 武慧挺.基于STC8A8K单片机的智能水泵控制器设计 [J]. 集成电路应用,2019,36(10):100-101.
[8] 张星宇,郭金刚,胡全义,等 . 基于 STC8 的户外仪器加热器及其控制系统设计 [J]. 工业控制计算机,2019,32(9): 151-152+156.
[9] 李虹静,李升辉 . 基于 STC8 系列单片机的继电器控制电路设计 [J]. 科技与创新,2019(13):37-38.
[10] 孟庆生,徐中干 . 基于无线传感器网络的电参数测量系统设计 [J]. 数字技术与应用,2019,37(1):195-196+198.
[11] 陆翔,刘邦经 . 基于 STM32 的嵌入式综合实验开发平台研究 [J]. 实验室研究与探索,2017,36(10):57-60.
[12] 王建莉,田成元,张总 . 一种简易多功能液体容器测量装置的设计 [J]. 电子世界,2019(20):139-140.
[13] 杨旭 . 传感器技术在机电技术中的应用 [J]. 当代化工研究,2020(22):73-74.
作者简介:毕涛(1986—),男,汉族,山东烟台人,讲师,硕士研究生,研究方向:控制工程。