CN111722636A - Self-balancing vehicle design scheme based on multi-innovation Kalman filtering - Google Patents

Self-balancing vehicle design scheme based on multi-innovation Kalman filtering Download PDF

Info

Publication number
CN111722636A
CN111722636A CN202010532368.8A CN202010532368A CN111722636A CN 111722636 A CN111722636 A CN 111722636A CN 202010532368 A CN202010532368 A CN 202010532368A CN 111722636 A CN111722636 A CN 111722636A
Authority
CN
China
Prior art keywords
unit
self
balancing vehicle
attitude
innovation
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Withdrawn
Application number
CN202010532368.8A
Other languages
Chinese (zh)
Inventor
王晓明
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Xinhe Semiconductor Technology Wuxi Co Ltd
Original Assignee
Xinhe Semiconductor Technology Wuxi Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Xinhe Semiconductor Technology Wuxi Co Ltd filed Critical Xinhe Semiconductor Technology Wuxi Co Ltd
Priority to CN202010532368.8A priority Critical patent/CN111722636A/en
Publication of CN111722636A publication Critical patent/CN111722636A/en
Withdrawn legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G05CONTROLLING; REGULATING
    • G05DSYSTEMS FOR CONTROLLING OR REGULATING NON-ELECTRIC VARIABLES
    • G05D1/00Control of position, course, altitude or attitude of land, water, air or space vehicles, e.g. using automatic pilots
    • G05D1/08Control of attitude, i.e. control of roll, pitch, or yaw
    • G05D1/0891Control of attitude, i.e. control of roll, pitch, or yaw specially adapted for land vehicles

Landscapes

  • Engineering & Computer Science (AREA)
  • Aviation & Aerospace Engineering (AREA)
  • Radar, Positioning & Navigation (AREA)
  • Remote Sensing (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Automation & Control Theory (AREA)
  • Telephone Function (AREA)

Abstract

The invention discloses a self-balancing vehicle design scheme based on multi-innovation Kalman filtering, which comprises a microprocessor unit, an attitude measurement unit, a direct current motor unit, an LED indication unit, a wireless transmission module and a mobile phone client, wherein the microprocessor unit is responsible for processing attitude data of the self-balancing vehicle and scheduling control tasks, the attitude measurement unit is responsible for reading attitude data of the self-balancing vehicle and processing the attitude data by the microprocessor unit, the direct current motor unit is responsible for controlling the running state of a motor and ensuring the stable running of equipment, the LED indication unit is used for indicating the running and fault states of the equipment so as to observe the running condition of the equipment conveniently, the wireless transmission module is used for transmitting or receiving data or instructions to realize wireless control of a self. The invention also provides a multi-innovation Kalman filtering algorithm, which fully considers the current motion attitude of the self-balancing vehicle and obtains attitude data with higher filtering precision and stability by utilizing the motion attitude information before the target, thereby ensuring the reliable operation of the self-balancing vehicle.

Description

Self-balancing vehicle design scheme based on multi-innovation Kalman filtering
Technical Field
The invention belongs to the technical field of intelligent equipment attitude control, and particularly relates to a self-balancing vehicle design scheme based on multi-innovation Kalman filtering.
Background
The two-wheeled self-balancing vehicle has extremely strong flexibility and belongs to a coaxial parallel arrangement structure. The self-balancing vehicle mechanism has natural instability characteristic, and is a nonlinear system with high order, instability, multiple variables and strong coupling. Attitude detection and control is critical to maintaining servo balance. In the process of obtaining the attitude of the self-balancing vehicle, fusion filtering is usually carried out on the gyroscope and acceleration data, so that the attitude of the self-balancing vehicle is calculated.
Data errors caused by inaccuracy of a system model cause random drift of a self-balancing vehicle system, the precision of a filter is reduced, and even system divergence is caused. By adopting the extended Kalman filtering algorithm, the random drift of the gyroscope and the acceleration sensor can be filtered, the problems of random temperature drift error compensation and attitude optimal estimation are solved, and the attitude control of the self-balancing vehicle can be realized. However, when multiple sensors interact, there is a problem in that the data operation logic lags, which will reduce the response speed of the balance control. In view of the above, the invention adopts an MPU6050 sensor to directly obtain attitude data, utilizes a multi-innovation control theory to improve a Kalman filtering algorithm to obtain the multi-innovation Kalman filtering algorithm, not only considers the current motion attitude of the self-balancing vehicle, but also fully utilizes the motion attitude information before a target, thereby obtaining the attitude data with higher filtering precision and stability.
Disclosure of Invention
The invention aims to provide a posture data processing method based on a multi-innovation Kalman filtering algorithm aiming at the conditions of low and unstable self-balancing vehicle posture data processing precision, and provides a self-balancing vehicle design scheme based on the method.
In order to achieve the purpose, the invention provides the following technical scheme:
a self-balancing vehicle design scheme based on a multi-innovation Kalman filtering algorithm comprises a main control microprocessor unit, a power supply unit, an attitude measurement unit, a direct current motor unit, an LED indication unit, a wireless transmission unit and a mobile phone client.
The microprocessor unit is responsible for processing attitude data of the self-balancing vehicle and controlling task scheduling; the attitude data processing adopts a multi-innovation Kalman filtering algorithm, and a control task is responsible for processing commands of going straight, backing, turning left and turning right of the self-balancing vehicle, processing real-time rotating speed data, indicating the running state and communicating with the wireless transmission module.
The power supply unit provides 3.3V of working voltage of the microprocessor unit and the attitude measuring unit, 5V of working voltage of the wireless transmission unit and 12V of running working voltage of the motor.
The attitude measurement unit directly obtains attitude data of an X/Y/Z axis of the self-balancing vehicle by adopting MPU6050 sensing.
The direct current motor unit comprises a direct current motor driving unit and two direct current motors; the direct current motor driving unit is responsible for independently and bidirectionally controlling the two direct current motors so as to ensure the movement of the self-balancing vehicle.
The LED indicating unit is responsible for indicating the operation and fault states of the self-balancing vehicle system; the LED indicator light flashes at a frequency of 1s to indicate system standby, flash for 2 times of 0.5s indicates data communication faults of the wireless transmission unit, flash for 3 times of 0.5s indicates abnormal driving of the motor 1, and flash for 4 times of 0.5s indicates abnormal driving of the motor 2.
The wireless transmission unit adopts an ESP8266 module, adopts a serial port communication mode with the microprocessor unit, and is responsible for acquiring real-time attitude data and motor data; and transmitting the instruction data and the PID parameters issued by the mobile phone client by adopting the WIFI connection.
The mobile phone client side is provided with an application program for controlling the self-balancing vehicle, the application program is responsible for issuing an instruction for controlling the self-balancing vehicle on one hand and calculating an optimal PID parameter on the other hand, and an ant colony algorithm is adopted for optimization of the PID parameter.
The processing flow of the multi-innovation Kalman filtering algorithm on the attitude data is as follows:
firstly, reading attitude data by utilizing an attitude measurement unit;
then, selecting a proper innovation length according to the load of the current processor;
then, obtaining an available attitude angle real-time value by utilizing a multi-innovation Kalman filtering algorithm;
and finally, transmitting the attitude angle real-time value to a mobile phone client through a wireless transmission module for data processing.
In detail, the direct current motor unit consists of a U1 module, a P1 wiring interface and a P2 wiring interface.
As a further scheme of the invention: the U1 module adopts TB6612FNG integrated chip, adopts VCC12V and VCC5V to supply power.
As a further scheme of the invention: the P1 wiring port and the P2 wiring port are connected with the UI module; through high and low levels, AB _ EN and AA _ EN are responsible for positive and negative rotation and stop of the motor 1, and BA _ EN and BB _ EN are responsible for positive and negative rotation and stop of the motor 2; a _ M1, A _ M2, B _ M1 and B _ M2 are connected with the motor 1 and the motor 2 through a P1 wiring port and a P2 wiring port; the PWM1 and the PWM2 are connected with a PWM output port of the microprocessor, and the running speed of the motor is controlled by adjusting the output PWM duty ratio, so that the self-balancing vehicle can run stably.
As a further scheme of the invention: a VCC5V common point power supply in the U1 module is connected with C14 and C20 and is used for filtering voltage ripples and ensuring the stability of power supply; VCC5V connected with the P1 wiring port and the P2 wiring port is respectively connected with C16 and C17, so that the stability of power supply is ensured.
Compared with the prior art, the invention has the following advantages:
(1) and the MPU6050 is adopted to directly acquire attitude data of an X/Y/Z axis, so that the problem of data inconsistency caused by fusion of different sensors is avoided, further, the calculated amount of a microprocessor is reduced, and the utilization rate of a CPU is improved.
(2) The attitude data is processed by adopting a multi-innovation Kalman filtering algorithm, namely the current motion attitude of the self-balancing vehicle is considered, the motion attitude information before the target is utilized, and the appropriate innovation length can be selected according to the loads of different microprocessors, so that the attitude data with higher filtering precision and stability is obtained.
(3) The self-balancing vehicle carries out data communication with a mobile phone client through the wireless transmission unit, processes real-time attitude data by means of the processing capacity of the mobile phone to the data and adopting an ant colony algorithm to obtain an optimal PID parameter, and then feeds the optimal PID parameter back to the microprocessor to enable the control of the self-balancing vehicle to be more accurate and stable.
Drawings
Fig. 1 is a schematic circuit topology diagram of a self-balancing vehicle design scheme based on multi-innovation kalman filtering.
FIG. 2 is a flow chart of the implementation of the multi-innovation Kalman filtering algorithm.
Fig. 3 is a circuit diagram of a dc motor unit according to the present invention.
FIG. 4 is a system block diagram of an android app framework specification and response.
In the figure: 1. a microprocessor unit; 2. a power supply unit; 3. an attitude measurement unit; 4. a direct current motor unit; 5. an LED indicating unit; 6. a wireless transmission unit; 7. and (4) a mobile phone client.
Detailed Description
The technical solution of the present patent will be described in further detail with reference to the following embodiments.
As shown in fig. 1, the design scheme of a self-balancing vehicle based on a multi-innovation kalman filtering algorithm in the present invention includes: the device comprises a main control microprocessor unit 1, a power supply unit 2, an attitude measuring unit 3, a direct current motor unit 4, an LED indicating unit 5, a wireless transmission unit 6 and a mobile phone client 7.
The microprocessor unit 1 is mainly responsible for processing attitude data of the self-balancing vehicle and controlling task scheduling. Attitude data is obtained by the attitude measurement unit 3, and the attitude data is an attitude angle of an X/Y/Z axis. The control task mainly comprises: processing the attitude data by adopting a multi-innovation Kalman filtering algorithm; the running speed of the trolley is adjusted by controlling the duty ratio of the PWM wave; controlling an IO port connected with the LED indicating unit 5 to indicate the running and fault states of the self-balancing vehicle; the wireless transmission unit 6 is communicated with a serial port; and acquiring the straight-going, backward, left-turning and right-turning instructions and PID parameters of the self-balancing vehicle, and reporting the implementation attitude data.
The power supply unit 2 provides 3.3V working voltage for the microprocessor unit 1 and the attitude measuring unit 3, and provides 5V working voltage for the direct current motor unit 4 and the wireless communication unit 6.
And the attitude measuring unit 3 directly obtains attitude angle data of an X/Y/Z axis of the self-balancing vehicle by adopting MPU6050 sensing.
The direct current motor unit 4 comprises a direct current motor driving unit and two direct current motors. The direct current motor driving unit is responsible for independently and bidirectionally controlling the two direct current motors so as to ensure the movement of the self-balancing vehicle.
And the LED indicating unit 5 is responsible for indicating the operation and fault states of the self-balancing vehicle system. The LED indicator light flashes at a frequency of 1s to indicate system standby, flash for 2 times of 0.5s indicates data communication faults of the wireless transmission unit, flash for 3 times of 0.5s indicates abnormal driving of the motor 1, and flash for 4 times of 0.5s indicates abnormal driving of the motor 2.
The wireless transmission unit 6 adopts an ESP8266 module, adopts a serial port communication mode with the microprocessor unit, and is responsible for acquiring real-time attitude data and motor data; and transmitting the instruction data and the PID parameters issued by the mobile phone client by adopting the WIFI connection.
And the mobile phone client 7 is provided with an application program for controlling the self-balancing vehicle, wherein the application program is responsible for issuing an instruction for controlling the self-balancing vehicle and calculating an optimal PID (proportion integration differentiation) parameter on the one hand, and the optimization of the PID parameter adopts an ant colony algorithm.
As shown in fig. 2, the processing flow of the multi-innovation kalman filter algorithm on the attitude data is as follows:
s1: acquiring the attitude angle degree through an MPU6050 sensor in the attitude measurement unit 3, and reading attitude data by the microprocessor unit 1;
s2: selecting a proper innovation length according to the load of the current microprocessor unit 1;
s3: executing a multi-innovation Kalman filtering algorithm;
s4: obtaining a real-time value of the available attitude angle;
s5: and transmitting the attitude angle real-time value to the mobile phone client through the wireless transmission module.
According to the steps, the multi-innovation Kalman filtering algorithm completes the processing of the attitude angle data.
As shown in fig. 3, a specific circuit diagram of the unit 4 of the dc motor is shown. The method comprises the following steps: u1 module, P1 wiring interface and P2 wiring interface.
Further, the U1 module is implemented by TB6612FNG integrated chip, which is connected to the microprocessor unit 1 through PWM1 and PWM2, and to the power supply unit 2 through VCC5V and VCC 12V.
Further, pins a _ M1, a _ M2 and B _ M1, B _ M2 in the U1 module are connected to motor 1 and motor 2 through P1 and P2 wiring ports, respectively.
Further, pins AB _ EN, AA _ EN, BA _ EN, BB _ EN in the U1 module are connected to the motor 1 and the motor 2 through P1 and P2 connection ports, respectively. Through the high and low levels, AB _ EN and AA _ EN are responsible for forward and reverse rotation and stop of the motor 1, and BA _ EN and BB _ EN are responsible for forward and reverse rotation and stop of the motor 2.
Furthermore, a VCC5V power supply in the U1 module is connected with capacitors C14 and C20, and the capacitors C14 and C20 are used for filtering voltage ripples and ensuring power supply stability.
Furthermore, VCC5V connected to the P1 connection port and the P2 connection port is respectively connected to capacitors C16 and C17, so that the stability of power supply is ensured.
In summary, in the invention, the MPU6050 sensor is used for obtaining attitude angle data of the self-balancing vehicle, the multi-innovation kalman filtering algorithm is used for processing the attitude angle data, then the real-time available attitude angle data is sent to the mobile phone client through the wireless transmission module, the processing capability of the mobile phone client is used for obtaining the optimal PID parameter according to the ant colony algorithm, and the optimal PID parameter is further fed back to the microprocessor unit to control the running state of the self-balancing vehicle, so that a solution for the self-balancing vehicle is provided.
As shown in fig. 4, the android APP installed on the mobile phone client 7 sends a gesture command (function code, gesture data, CRC check) to the ESP8266 through the TCP server; the android APP receives attitude data returned by the intelligent trolley, and the attitude data is optimized by using a multi-innovation Kalman filtering algorithm again by utilizing the advantage of high operation speed of a mobile phone CPU; continuously updating the iterative optimization result by the android APP, continuously converging the attitude data along with the continuous increase of the operation time, and transmitting the optimization result to the ESP 8266.
Although the preferred embodiments of the present patent have been described in detail, the present patent is not limited to the above embodiments, and various changes can be made without departing from the spirit of the present patent within the knowledge of those skilled in the art.

Claims (9)

1. A self-balancing vehicle design scheme based on a multi-innovation Kalman filtering algorithm is characterized by mainly comprising the following steps: the system comprises a microprocessor unit (1), a power supply unit (2), an attitude measuring unit (3), a direct current motor unit (4), an LED indicating unit (5), a wireless transmission unit (6) and a mobile phone client (7); the power supply unit (2), the attitude measuring unit (3), the direct current motor unit (4), the LED indicating unit (5) and the wireless transmission unit (6) are all connected with the microprocessor unit (1), and the microprocessor unit (1) is connected with the mobile phone client (7) through the wireless transmission unit (6); the microprocessor unit (1) is responsible for processing attitude data of the self-balancing vehicle and scheduling control tasks; and the LED indicating unit (5) is responsible for indicating the operation and fault states of the self-balancing vehicle system.
2. The design scheme of the self-balancing vehicle based on multi-innovation kalman filtering according to claim 1, wherein the attitude measurement unit (3) adopts MPU6050 for sensing to obtain attitude angle data of X/Y/Z axes of the self-balancing vehicle.
3. The design scheme of the self-balancing vehicle based on multi-innovation kalman filtering is characterized in that the power supply unit (2) provides 3.3V microprocessor unit and attitude measurement unit working voltage; and provides a 5V wireless transmission unit operating voltage and a 12V motor operating voltage.
4. The design scheme of the self-balancing vehicle based on multi-innovation Kalman filtering is characterized in that the wireless transmission unit (6) adopts an ESP8266 module, and the ESP8266 module and a microprocessor unit adopt a serial port communication mode and are responsible for acquiring real-time attitude data and motor data; and transmitting the instruction data and the PID parameters issued by the mobile phone client by adopting the WIFI connection.
5. The design scheme of the self-balancing vehicle based on multi-innovation kalman filtering is characterized in that the mobile phone client (7) is provided with an application program for controlling the self-balancing vehicle, the application program is responsible for issuing an instruction for controlling the self-balancing vehicle and calculating an optimal PID parameter, and the optimization of the PID parameter adopts an ant colony algorithm.
6. The design scheme of the self-balancing vehicle based on multi-innovation kalman filtering is characterized in that the circuit of the direct current motor unit (4) comprises: the U1 module, the P1 wiring port and the P2 wiring port, the direct current motor unit (4) is responsible for independent two-way control two direct current motors, and the motion of the self-balancing vehicle is guaranteed.
7. The design scheme of the self-balancing vehicle based on multi-innovation kalman filtering, characterized in that the U1 module is TB6612FNG integrated chip, which is connected to the microprocessor unit (1) through PWM1 and PWM2, and to the power supply unit 2 through VCC5V and VCC 12V; pins A _ M1, A _ M2, B _ M1 and B _ M2 in the U1 module are connected with a motor A and a motor B through a P1 wiring port and a P2 wiring port respectively; pins AB _ EN, AA _ EN, BA _ EN and BB _ EN in the U1 module are respectively connected with a motor A and a motor B through a P1 wiring port and a P2 wiring port; through the high and low levels, AB _ EN, AA _ EN are responsible for the positive and negative rotation and stop of the motor A, and BA _ EN, BB _ EN are responsible for the positive and negative rotation and stop of the motor B.
8. The design scheme of the self-balancing vehicle based on multi-innovation kalman filtering of claim 6, wherein a VCC5V power supply in the U1 module is connected with capacitors C14 and C20, the capacitors C14 and C20 are used for filtering voltage ripples and ensuring power supply stability, and VCC5V connected with a P1 wiring port and a P2 wiring port is respectively connected with capacitors C16 and C17, which also ensures power supply stability.
9. A multi-innovation Kalman filtering algorithm is characterized by comprising the following steps:
s1: acquiring attitude angle degrees through an MPU6050 sensor in an attitude measurement unit, and reading attitude data by the microprocessor unit;
s2: selecting a proper innovation length according to the load of the current microprocessor unit;
s3: executing a multi-innovation Kalman filtering algorithm;
s4: obtaining a real-time value of the available attitude angle;
s5: and transmitting the attitude angle real-time value to the mobile phone client through the wireless transmission module.
CN202010532368.8A 2020-06-12 2020-06-12 Self-balancing vehicle design scheme based on multi-innovation Kalman filtering Withdrawn CN111722636A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010532368.8A CN111722636A (en) 2020-06-12 2020-06-12 Self-balancing vehicle design scheme based on multi-innovation Kalman filtering

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010532368.8A CN111722636A (en) 2020-06-12 2020-06-12 Self-balancing vehicle design scheme based on multi-innovation Kalman filtering

Publications (1)

Publication Number Publication Date
CN111722636A true CN111722636A (en) 2020-09-29

Family

ID=72566494

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010532368.8A Withdrawn CN111722636A (en) 2020-06-12 2020-06-12 Self-balancing vehicle design scheme based on multi-innovation Kalman filtering

Country Status (1)

Country Link
CN (1) CN111722636A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113220006A (en) * 2021-05-08 2021-08-06 中科芯集成电路有限公司 Self-balancing vehicle system based on multi-innovation Kalman filtering algorithm

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113220006A (en) * 2021-05-08 2021-08-06 中科芯集成电路有限公司 Self-balancing vehicle system based on multi-innovation Kalman filtering algorithm

Similar Documents

Publication Publication Date Title
CN103644915B (en) One directly drives optical fibre gyro stabilized platform structure and control method thereof
CN107462148B (en) A kind of door state detection method and device
CN103057712B (en) Integration flight control system for miniature flying robot
CN204989980U (en) Many rotor crafts of feather controller
CN109842345A (en) Method and device for driving steering engine
CN102814047A (en) Autonomous return system and control method of dual-rotor remote-controlled model helicopter
CN112276976B (en) Cloud control platform-based functional robot control system
CN206105880U (en) Robot control system
CN110806754A (en) Four-rotor aircraft attitude correction control system and method
CN111722636A (en) Self-balancing vehicle design scheme based on multi-innovation Kalman filtering
CN105490594A (en) Double low-voltage brushless DC motor drive control system and method
CN104459636A (en) Multi-radar antenna coordination control method
CN103246253A (en) Multi-motor distributed type control system under wireless network and multi-motor distributed type control method
CN106385209B (en) Motor angle control method, system and unmanned plane
CN113220006A (en) Self-balancing vehicle system based on multi-innovation Kalman filtering algorithm
CN107776436B (en) The control method and device of double-wheel self-balancing equipment
CN208239889U (en) A kind of intelligent vehicle control for detecting and three-dimension space image reconstructs
CN210889287U (en) Plunger pump liquid inlet system for fuel cell
CN107053169A (en) A kind of bus intelligent servo drive system, robot and method
CN113696328A (en) Control method and control device for adjusting feeding speed of sand making building and sand making building
CN208044348U (en) System and device is debated in a kind of rudder for ship system accuracy knowledge of unmanned pure electric vehicle ship
CN209980072U (en) Unmanned warning monitoring module bearing platform electrical system
CN105527995A (en) Remote temperature control system and using method thereof
Aadithya et al. Multifunctional Unmanned Ground Vehicle
CN220188887U (en) Laser navigation AGV controlling means

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
WW01 Invention patent application withdrawn after publication

Application publication date: 20200929

WW01 Invention patent application withdrawn after publication