CN107368081B - A kind of double-wheel self-balancing robot adaptive sliding mode variable structure control system - Google Patents

A kind of double-wheel self-balancing robot adaptive sliding mode variable structure control system Download PDF

Info

Publication number
CN107368081B
CN107368081B CN201710790443.9A CN201710790443A CN107368081B CN 107368081 B CN107368081 B CN 107368081B CN 201710790443 A CN201710790443 A CN 201710790443A CN 107368081 B CN107368081 B CN 107368081B
Authority
CN
China
Prior art keywords
sliding mode
speed
mode controller
double
information
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.)
Active
Application number
CN201710790443.9A
Other languages
Chinese (zh)
Other versions
CN107368081A (en
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.)
Hangzhou Electronic Science and Technology University
Original Assignee
Hangzhou Electronic Science and Technology University
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 Hangzhou Electronic Science and Technology University filed Critical Hangzhou Electronic Science and Technology University
Priority to CN201710790443.9A priority Critical patent/CN107368081B/en
Publication of CN107368081A publication Critical patent/CN107368081A/en
Application granted granted Critical
Publication of CN107368081B publication Critical patent/CN107368081B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G05CONTROLLING; REGULATING
    • G05BCONTROL OR REGULATING SYSTEMS IN GENERAL; FUNCTIONAL ELEMENTS OF SUCH SYSTEMS; MONITORING OR TESTING ARRANGEMENTS FOR SUCH SYSTEMS OR ELEMENTS
    • G05B13/00Adaptive control systems, i.e. systems automatically adjusting themselves to have a performance which is optimum according to some preassigned criterion
    • G05B13/02Adaptive control systems, i.e. systems automatically adjusting themselves to have a performance which is optimum according to some preassigned criterion electric
    • G05B13/04Adaptive control systems, i.e. systems automatically adjusting themselves to have a performance which is optimum according to some preassigned criterion electric involving the use of models or simulators
    • G05B13/042Adaptive control systems, i.e. systems automatically adjusting themselves to have a performance which is optimum according to some preassigned criterion electric involving the use of models or simulators in which a parameter or coefficient is automatically adjusted to optimise the performance

Abstract

The invention discloses a kind of double-wheel self-balancing robot adaptive sliding mode variable structure control systems, model the kinetics equation of following double-wheel self-balancing robot according to classical mechanics analytic approach and the Lagrange algorithm based on energy spectrometer and design Sliding Mode Controller according to the kinetics equation;Sliding Mode Controller includes speed Sliding Mode Controller and angle Sliding Mode Controller, speed Sliding Mode Controller and angle Sliding Mode Controller phase mutual feedback, back analysis equations are as follows: θr=β V;Self adaptive control is carried out to system using based on function approximation mode.Using technical solution of the present invention, make modeling process more simplify and comprehensively, the robustness of enhancing system, the response speed for improving system;Simultaneously because there are mutual feedback relationships for the speed and angle of system, when the inclination angle of system is excessive, system can automatic reduction of speed, while speed reduces, equilbrium position can be automatically returned to, in the case where facing different pavement conditions, system can adaptive external environment and the variation that loads on a large scale, to guarantee the safety and stablization of system.

Description

A kind of double-wheel self-balancing robot adaptive sliding mode variable structure control system
The application is application No. is the divisional application of 2015105060910 patent application, and the applying date of female case is 2015 On August 17, a kind of denomination of invention are as follows: double-wheel self-balancing robot adaptive sliding mode variable structure control method and system.
Technical field
The present invention relates to robot control field more particularly to a kind of double-wheel self-balancing robot adaptive sliding moding structures Control system.
Background technique
In recent years, as mobile robot research deepens continuously, application field is more extensive, the environment and task faced Also it becomes increasingly complex.Robot is frequently encountered workplace that is some narrow, and having many big corners, how at this Execution task in the more complicated environment of sample flexibly and fast becomes the problem that people are rather concerned about.Double-wheel self-balancing machine Device people's concept is exactly to put forward in this context.Double-wheel self-balancing robot technology is a kind of across the comprehensive of multiple subjects Conjunction technology, system model are the kinetic models of a considerably complicated nonlinear instability, and double-wheel self-balancing machine People's system structure is special, and adaptation to the ground changing capability is strong, and movement is flexible, the work that can be competent in some more complicated environment, So being concerned in control theory and engineering field, theoretical knowledge associated with it includes: point of 1. physical architecture Analysis;2. the building of kinematics analysis and kinetic model, the analysis including kinetic characteristics and drive lacking;3. simulation and emulation point Analysis;4. attitude detection technology and space orientation technique, zero point or temperature drift including overcoming inertial sensor, filtering algorithm Design and theory analysis, multisensor Data Fusion technology etc.;5. the theory of motion control and balance control and control method Research.
Simulation process is carried out to two-wheel self-balance robot system, it is necessary first to know the mathematical model of system, then It is possible to simulate system, the modeling pattern of double-wheel self-balancing robot is built using system mostly in the prior art The one of which of classical mechanics analytic approach or the Lagrange method based on energy spectrometer in mould mode individually uses classical mechanics The consequence of analytic approach modeling is that mechanical analysis process is excessively complicated;And when individually using the Lagrange method based on energy spectrometer Have ignored the situation of change of energy in system.The control algolithm of prior art double-wheel self-balancing robot is mostly PID control simultaneously Algorithm processed, LQR control algolithm, optimal control algorithm, FUZZY ALGORITHMS FOR CONTROL etc., these control algolithms are in double-wheel self-balancing robot This non-linear, natural time-dependent system is difficult to reach satisfied control effect, and robustness is not good enough, and response speed is not fast enough, When in face of biggish disturbance, system is unstable, cannot adaptive more complex external rings when the variation of external pavement conditions Border and the variation loaded on a large scale, whether the addition of load can not be detected automatically;It is not smart enough on data processing method; Speed control method only leans on the variation at inclination angle, and mode is excessively single;The buffeting of system is very big.
Therefore for drawbacks described above present in currently available technology, it is really necessary to be studied, to provide a kind of scheme, Solve defect existing in the prior art.
Summary of the invention
The purpose of the present invention is a kind of double-wheel self-balancing robot adaptive sliding mode variable structure control systems, make modeling process More simplify and comprehensively, enhancing system robustness, improve system response speed;Cope with biggish external disturbance;Energy Enough adaptive external environment and the variation loaded on a large scale;It can automatically detect the addition of load;The value of system parameters is more Add accurate;Speed control method diversification.
In order to overcome the shortcomings of the prior art, the technical solution of the present invention is as follows:
A kind of double-wheel self-balancing robot adaptive sliding mode variable structure control system, including power module, gyroscope, acceleration Degree meter, turn to potentiometer, control unit, first motor drive module, the second motor drive module, first motor, the second motor, First encoder and second encoder, wherein
The power module is used for system power supply;
The gyroscope is for detecting self-balance robot car body drift angle information, and it is single to send that information to the control Member;
The accelerometer is used to detect the acceleration information of self-balance robot, and sends that information to the control Unit;
The direction information for turning to potentiometer and being used to detect self-balance robot, and send that information to the control Unit;
First encoder and the second encoder are used to detect the velocity information of self-balance robot, and by the letter Breath is sent to described control unit;
Described control unit calculates output according to the drift angle information, acceleration information, direction information and velocity information Signal is controlled, and is sent to the first motor drive module and second motor drive module;
The first motor drive module and second motor drive module output PWM drive signal make first electricity Machine and second motor rotation;
Described control unit includes that Kalman's data fusion module, speed Sliding Mode Controller and angle sliding formwork become knot Structure controller, wherein
Kalman's data fusion module is used to the drift angle information and the acceleration information carrying out data fusion, And fuse information is sent to the angle Sliding Mode Controller;
The fuse information and institute that the angle Sliding Mode Controller is exported according to Kalman's data fusion module State the feedback information output control signal of speed Sliding Mode Controller;
The feedback information is determined by following back analysis equations:
θr=β V, wherein θrThe feedback letter of angle Sliding Mode Controller is fed back to for speed Sliding Mode Controller Breath, V are present speed, and β is constant, between the value range -0.15 of value to 0.15;
The output control signal of the angle Sliding Mode Controller is determined by following output equation:
Wherein Δ T is the sampling time,Y=β b2, Z=b1-βc2b2,For adaptive item;s2For angle Sliding variable, ε2For system perspective error constant item, λ2For speed real constant item, sat (s2) it is ramp function, eθFor angle mistake Difference,For the first derivative of car body drift angle,For the first derivative of angular error;
The speed Sliding Mode Controller is according to the velocity information and the angle Sliding Mode Controller Output control signal, exports the feedback information, output quantity U is determined by following equationWherein, s1For speed sliding variable, VrFor reference velocity,For ginseng Examine the first derivative of speed, evFor velocity error, ε1For system speed error constant, λ1For angle real constant item.
Preferably, the speed Sliding Mode Controller and angle Sliding Mode Controller are analyzed according to classical mechanics Method and Lagrange algorithm based on energy spectrometer are simultaneously established the kinetics equation (1) of following double-wheel self-balancing robot and are designed Out:
Wherein, U is that the output of Sliding Mode Controller controls signal, and θ is the car body drift angle of double-wheel self-balancing robot, ev=V-VrFor present speed V and reference velocity VrSpeed difference, a1、b1、c1、d1、a2、b2、c2、d2For double-wheel self-balancing robot Model parameter.
Preferably, the angle Sliding Mode Controller is self-adaptive controlled using being carried out based on function approximation mode System, adaptive item are as follows:Wherein For Laguerre basic function,For the parameter sets of orthogonal family of function Laguerre polynomials items,What it is for each is Number,For Laguerre basic function multinomial.
Preferably, in the angle Sliding Mode Controller and the speed Sliding Mode Controller, using oblique Slope functionWherein, Δ is known as boundary layer.
Preferably, the β value is -0.14.
Preferably, a1、b1、c1、d1、a2、b2、c2、d2Value determined by following formula:
Wherein,M is the quality of double-wheel self-balancing robot, and g is acceleration of gravity, and L is matter For the heart with a distance from wheel center, J is the rotary inertia of self-balance robot car body, VrFor reference velocity, KtIt is normal for motor torque Number, KeFor back EMF coefficient, RaFor both ends of the motor armature resistance.
Compared with prior art, the side Lagrange present invention incorporates classical mechanics analytic approach and based on energy spectrometer Method, avoids complicated mechanical analysis process, and in view of the variation of energy in system, simplifies modeling process more and entirely Face;Meanwhile the output of Sliding Mode Controller controls signal, it is contemplated that the relational expression θ between angle and speedr=β V leads to The value for choosing β is crossed, so that the speed of system and angle be enable to influence each other, when the inclination angle of system is excessive, system can be automatic Reduction of speed can automatically return to equilbrium position, to guarantee the safety and stablization of system while speed reduces.
Figure of description
Fig. 1 is the design cycle block diagram of double-wheel self-balancing robot adaptive sliding mode variable structure control system of the present invention;
Fig. 2 is the integral mechanical structure block diagram of double-wheel self-balancing robot;
Fig. 3-a is double-wheel self-balancing robot three-dimensional force diagram;
Fig. 3-b is double-wheel self-balancing robot two dimension force diagram;
Fig. 3-c is double-wheel self-balancing robot two dimension force simplified figure;
Fig. 4 is the hardware block diagram of double-wheel self-balancing robot control system;
Fig. 5 is the schematic diagram that signal is controlled in double-wheel self-balancing robot control system;
Fig. 6 is the analogous diagram of β value under different double-wheel self-balancing robot model parameters;
Fig. 7 is the analogous diagram of the β value under particular model parameter;
Fig. 8-a is speed of the double-wheel self-balancing robot in the case where speed reference signal is the adaptive sliding-mode observer of sinusoidal signal Spend aircraft pursuit course;
Fig. 8-b is double-wheel self-balancing robot speed in the case where speed reference signal is the adaptive sliding-mode observer of sinusoidal signal Error curve;
Fig. 8-c is angle of the double-wheel self-balancing robot in the case where speed reference signal is the adaptive sliding-mode observer of sinusoidal signal Spend error curve;
Fig. 8-d is that double-wheel self-balancing robot is bent in the adaptive sliding-mode observer output that speed reference signal is sinusoidal signal Line;
Fig. 9-a is speed tracing of the double-wheel self-balancing robot in the case where speed reference signal is the PID control of sinusoidal signal Curve;
Fig. 9-b is velocity error of the double-wheel self-balancing robot in the case where speed reference signal is the PID control of sinusoidal signal Curve;
Fig. 9-c is angular error of the double-wheel self-balancing robot in the case where speed reference signal is the PID control of sinusoidal signal Curve;
It is that controller under the PID control of sinusoidal signal is defeated that Fig. 9-d, which is double-wheel self-balancing robot in speed reference signal, Curve out.
Figure 10-a is double-wheel self-balancing robot in the case where speed reference signal is the adaptive sliding-mode observer of square-wave signal Speed tracing curve;
Figure 10-b is that double-wheel self-balancing robot is fast in the case where speed reference signal is the adaptive sliding-mode observer of square-wave signal Spend error curve;
Figure 10-c is double-wheel self-balancing robot in the case where speed reference signal is the adaptive sliding-mode observer of square-wave signal Angular error curve;
Figure 10-d is double-wheel self-balancing robot in the adaptive sliding-mode observer output that speed reference signal is square-wave signal Curve;
Figure 11-a is speed tracing of the double-wheel self-balancing robot in the case where speed reference signal is the PID control of square-wave signal Curve;
Figure 11-b is velocity error of the double-wheel self-balancing robot in the case where speed reference signal is the PID control of square-wave signal Curve;
Figure 11-c is angular error of the double-wheel self-balancing robot in the case where speed reference signal is the PID control of square-wave signal Curve;
It is that controller under the PID control of square-wave signal is defeated that Figure 11-d, which is double-wheel self-balancing robot in speed reference signal, Curve out.
Specific embodiment
Referring to Fig. 1, it show a kind of setting for double-wheel self-balancing robot adaptive sliding mode variable structure control system of the invention Count flow diagram, comprising the following steps:
Step 101: following two-wheeled is modeled certainly according to classical mechanics analytic approach and the Lagrange algorithm based on energy spectrometer The kinetics equation of balanced robot:
Step 102: and Sliding Mode Controller is designed according to above-mentioned kinetics equation;
Wherein, in kinetics equation, U is that the output of Sliding Mode Controller controls signal, and θ is double-wheel self-balancing machine The car body drift angle of people, ev=V-VrFor present speed V and reference velocity VrSpeed difference, a1、b1、c1、d1、a2、b2、c2、d2It is two Take turns the model parameter of self-balance robot, d1And d2For system interference.
Step 103: acquisition transducing signal and the input parameter in this, as Sliding Mode Controller, wherein two-wheeled is certainly The present speed information of balanced robot is one of the input parameter of Sliding Mode Controller.
Step 104: Sliding Mode Controller inputs parameter output control signal according to it;
Step 105: control signal being exported according to Sliding Mode Controller and potentiometer signal co- controlling motor is transported It is dynamic;Control signal is exported according to Sliding Mode Controller, system is balanced and speed control, and using turning to electricity Position device signal carries out course changing control to system;
Step 106: detecting the present speed information of double-wheel self-balancing robot, and fed back to Sliding mode variable structure control The input terminal of device, one of the input parameter as Sliding Mode Controller;
Step 103 is repeated to step 106, according to transducing signal parameter and feedback signal, Sliding Mode Controller is real When adjustment output control signal driving double-wheel self-balancing robot movement.
In above-mentioned steps 101, to the mathematical model of double-wheel self-balancing robot control system control system research In have considerable status, the performance of Yao Tigao system, it is necessary first to the mathematical model for knowing system is then possible to Simulation process is carried out to system, and then framework real system carries out simulation test.Referring to fig. 2, it show double-wheel self-balancing machine The integral mechanical structure block diagram of people, the mechanical structure of two-wheel self-balance robot system mainly by car body, left and right two driving wheels, Driving motor, encoder and sensor composition, sensor further comprise gyroscope, accelerometer, turn to potentiometer, speed Sensor etc. is spent, driving wheel movement is controlled according to sensor signal, the motion profile of robot is related with the two driving wheels.It is left Right two-wheeled is independently driven by respective motor and two-wheeled shaft axis is on same straight line, and robot car body can be around two-wheeled shaft certainly By rotating.When gyroscope detects that car body generates inclination, control system generates a corresponding torque according to the inclination angle measured, It is moved by control two wheels of motor driven towards the direction to be fallen down of vehicle body, to keep the dynamic of double-wheel self-balancing robot itself State balance.The movement of double-wheel self-balancing robot is mainly controlled by the rotating torque that the motor of two wheel rotations of driving generates System.
In the prior art, certainly flat to two-wheeled only with classical mechanics analytic approach or the Lagrange method based on energy spectrometer Weighing apparatus robot system is modeled, then the present invention is used and is based on first by the force analysis to double-wheel self-balancing robot The Lagrange method of energy spectrometer establishes the whole mathematical model of double-wheel self-balancing robot, and double-wheel self-balancing robot is whole Three-dimensional force analysis as shown in Fig. 3-a, it is contemplated that the movement of double-wheel self-balancing robot is realized by vehicle wheel rotation, this hair Bright technical solution is co-axially mounted using a pair and the identical tire of parameter, so the model of left and right wheels is the same, therefore only The two-dimentional stress condition for considering double-wheel self-balancing robot, as shown in Fig. 3-b, for the ease of mathematical derivation, by its further letter The form as shown in Fig. 3-c of chemical conversion.Parameter declaration involved in Fig. 3-a, Fig. 3-b and Fig. 3-c is as shown in table 1 below.
The symbol description of 1 double-wheel self-balancing robot model of table
The kinetics equation derivation process of double-wheel self-balancing robot of the invention described in detail below, wherein the present invention In used other symbol descriptions it is as shown in table 2.
The symbol description of 2 double-wheel self-balancing robot model of table
Firstly, equation (2) of the double-wheel self-balancing robot about momentum is obtained, according to energy according to principle of conservation of momentum Conservation principle is measured, equation (3) of the double-wheel self-balancing robot about energy is obtained.
(2) in formula and (3) formula: P0Indicate the initial momentum (Kgm/s) of double-wheel self-balancing robot, E0It is certainly flat for two-wheeled The primary power (J) of weighing apparatus robot, J are the rotary inertia (Kgm of car body2)。
Derivation is carried out to (2) formula and (3) formula respectively and obtains equation (4) formula about resultant force F and the equation (5) about power Formula:
(4) formula is substituted into (5) formula, obtains (6) formula:
When controlling the balance and movement of double-wheel self-balancing robot, control amount is the rotating torque of wheel, so needing Know the output torque of motor, the output torque expression formula in DC motor model is (7) formula:
K in formula (7)tFor the torque constant (NmA) of motor, KeFor back EMF coefficient (Vs), UaFor armature input Voltage (V), w are motor output angular velocity (rad/s), RaFor armature resistance (Ω).
Output torque expression formula in (7) formula motor model is melted into the form of (8) formula:
F=CuU-CvV (8)
Wherein:
(8) formula is updated to (4) formula and obtains (9) formula:
Since θ and w are smaller, so there is (10) formula:
Definition:
ev=V-Vr (11)
Wherein VrFor the reference velocity of V.
In conjunction with (5), (8), (9) and (10) formula, double-wheel self-balancing robot equation is finally obtained are as follows:
Wherein
In a step 102, the sliding formwork that double-wheel self-balancing robot is designed according to above-mentioned kinetics equation (formula 12) becomes Structure controller, detailed process is as follows:
It defines first:
eθ=θ-θr (13)
Wherein θrFor the reference angle of θ.
According to kinetics equation (12) formula of double-wheel self-balancing robot entirety, Sliding Mode Controller is designed, will be slided The equation of moding amount s is defined as (14) formula:
WhereinMeet Hurwitz stability criterion condition.
Sliding Mode Controller is designed by adopting the above technical scheme, and whole sliding variable is designed to that speed sliding formwork becomes The matrix form of amount and angle sliding variable composition, and speed sliding variable is designed to band integrated form, to play reduction The effect of buffeting.
Definition lyapunov energy function is (15) formula:
In formula (15)
To ensure that entire two-wheel self-balance robot system is stablized, i.e. the derivative of v is less than zero.Ensure double-wheel self-balancing simultaneously Robot is in speed and upright upper while stable, i.e. v1And v2Derivative be both less than zero.
v1Derivative be (16) formula.
It enables
Constant ε in formula (17)1> 0 indicates that the motor point of system levels off to the rate of diverter surface s=0.ε1It is smaller, approach speed Degree is slow;ε1It is bigger, then there is biggish speed, caused shake is also larger when motor point reaches diverter surface.
In a preferred embodiment, the expression formula of ramp function is (18) formula in formula (17).Ramp function conduct A kind of method of quasisliding mode control, its essence is outside boundary layer, using switching control, in boundary layer, using line Property feedback control, reduces the buffeting of system, to keep system more stable.
(17) formula is updated to (16) formula and obtains (19) formula.
Formula (19) shows to slide variable s1It is asymptotically stability, meets Lyapunov stability condition.
Change rate (20) formula about speed is obtained by (17) formula.
Due in system speed and angle signal have certain connection, in a preferred embodiment, define angle Spend reference signal θrRelational expression with speed V is (21) formula.
θr=β V (21)
Derivation is carried out to (21) formula and secondary derivation obtains (22) formula and (23) formula.
Derivation is carried out to angular error (13) formula and secondary derivation obtains (24) formula and (25) formula.
It enables
(26) formula is updated in (25) formula (27) formula that obtains.
(13) formula equation and (24) formula equation are arranged to obtain (28) formula and (29) formula.
eθ=θ-θr=θ-β (ev+Vr) (28)
(20) formula is updated to (29) formula and obtains (30) formula.
U is the laststate of double-wheel self-balancing robot controller in formula (30).
v2Derivative be (31) formula.
It enables
Constant ε in formula (32)2> 0 and ε1Effect as, the value of β must satisfy (33) formula.
It is (34) formula in conjunction with the value that (26) formula obtains β.
It is (35) formula by the final Sliding Mode Controller that (32) formula obtains double-wheel self-balancing robot.
In formula (35),
Y=β b3,
Z=b2-βa33b3.Its adaptive item isWherein For Laguerre Ball curve.
(32) formula is updated in (31) formula (36) formula that obtains.
Formula (36) shows to slide variable s2It is asymptotically stability, meets Lyapunov stability condition.In formula (35) Sliding Mode Controller U be theoretically correct.
In a preferred embodiment, in a step 102, by the defeated of the output control signal of Sliding Mode Controller Equation is set out are as follows:
Wherein, Δ T is the sampling time,Y=β b2, Z=b1-βc2b2,For adaptive item.
In step 103, transducing signal includes acquiring drift angle information by gyroscope and being added by what accelerometer acquired Velocity information in a preferred embodiment believes the drift angle information and the acceleration by Kalman filtering algorithm Breath carries out data fusion.Data fusion is carried out using Kalman filtering algorithm and mainly uses following formula, to make system control It is more accurate.
X (k | k-1)=AX (k-1 | k-1)+BU (k) (37)
P (k | k-1)=AP (k-1 | k-1) A'+Q (38)
X (k | k)=X (k | k-1)+Kg (k) (Z (k)-HX (k | k-1)) (39)
Kg (k)=P (k | k-1) H'/(HP (k | k-1) H'+R) (40)
P (k | k)=(I-Kg (k) H) P (k | k-1) (41)
Referring to fig. 4, it show the hardware principle frame for realizing the double-wheel self-balancing robot control system of above-mentioned control method Figure, including power module, gyroscope, accelerometer, steering potentiometer, control unit, first motor drive module, the second motor Drive module, first motor, the second motor, the first encoder and second encoder, other modules such as key module, display screen Deng details are not described herein.
Within the system, power module provides supply voltage for whole system;
Gyroscope sends that information to control unit for detecting self-balance robot car body drift angle information;Gyro The drift angle information of instrument is important parameter, and control unit controls output control signal as benchmark.
Accelerometer is used to detect the acceleration information of self-balance robot, and sends that information to control unit;
The direction information that potentiometer is used to detect self-balance robot is turned to, and sends that information to control unit;
First encoder and second encoder are used to detect the velocity information of self-balance robot, and send that information to Control unit;First encoder and second encoder are separately mounted on the first driving wheel and the second driving wheel, and detection first is driven The revolving speed of driving wheel and the second driving wheel.
Control unit calculates output control signal according to drift angle information, acceleration information, direction information and velocity information, And it is sent to first motor drive module and the second motor drive module;
First motor drive module and the second motor drive module control signal according to above-mentioned output and export PWM drive signal Rotate first motor and the second motor.
In a preferred embodiment, it referring to Fig. 5, show in double-wheel self-balancing robot control system and controls signal Schematic diagram, control unit further comprises Kalman's data fusion module and Sliding Mode Controller, sliding moding structure control Device processed includes speed Sliding Mode Controller and angle Sliding Mode Controller, wherein
Kalman's data fusion module is used to carry out drift angle information and acceleration information data fusion, and by fuse information It is sent to angle Sliding Mode Controller;
The fuse information and speed sliding formwork that angle Sliding Mode Controller is exported according to Kalman's data fusion module become The feedback information output control signal of structure controller;
In a preferred embodiment, the feedback information of speed Sliding Mode Controller output is by following back analysis equations It determines:
θr=β V, wherein θrThe feedback letter of angle Sliding Mode Controller is fed back to for speed Sliding Mode Controller Breath, V is present speed, and β is constant, by choosing the value of β, so that the speed of system and angle be enable to influence each other, when being When the inclination angle of system is excessive, system can automatic reduction of speed, speed reduce while, equilbrium position can be automatically returned to, to guarantee system Safety and stablization.
β is the stable important parameter of system, determines (partial parameters in table 1, table 2), β value by two wheel robot model parameters Selection by solve equationAnd it obtains, while must satisfy conditionSo finalThe present invention acquires the range of β value by way of emulation.Referring to Fig. 6, it show The analogous diagram of β value under different double-wheel self-balancing robot model parameters, between the value range -0.15 of β value to 0.15.
In a preferred embodiment, the output control signal of angle Sliding Mode Controller is by following output equation It determines:
Wherein, Δ T is the sampling time,Y=β b2, Z=b1-βc2b2,For adaptive item.
In a preferred embodiment, speed Sliding Mode Controller is according to velocity information and angle sliding moding structure The output of controller controls signal, exports feedback information.
In a preferred embodiment, further include speed regulating handle, throttle signal is exported by speed regulating handle, and by the letter Number it is sent to control unit.Throttle signal and reference velocity VrProportion relation, therefore made by throttle signal with reference to speed Spend VrValue change.Technical solution of the present invention is only compared by drift angle information control speed mode with existing, increases one Kind control mode, so that the speed control method diversification of system, while increasing the safety coefficient of system.
In a preferred embodiment, further include self-adapting load detection module, have the function of load detecting.Load inspection Survey module using sluggish function, by given threshold to determine whether there is load, i.e., when people station get on when indicator light Can be bright, threshold value is set according to the output quantity of encoder and motor.
In a preferred embodiment, further include wireless communication module, be connected with control unit, be used for and host computer End is communicated, and module is handled and analyzed to data by wireless communication, the accuracy and intelligence of the control of Lai Tigao system It can property.Wireless data receipt modules and sending module in wireless communication module use chip NRF24L01, RXF2401 radio frequency function Rate amplifier.
In a preferred embodiment, control unit uses 32 microcontroller MK60DN512ZVLQ10 of Freescale, speed It spends sensor and selects photoelectric encoder, the full bridge driving circuit that motor driven uses BTN7971B half-bridge driven chip to build, electricity Source module uses the chargeable nickel-cadmium cell of 24V, 14Ah.LPR510AL and MMA7260 is respectively adopted in gyroscope and accelerometer.
In a preferred embodiment, the driving motor of two-wheel self-balance robot system of the invention is watched using direct current Motor, the specifically servo motor of EC90M485500RGOL model are taken, this is because DC servo motor has excellent speed Control performance, it exports biggish torque, directly dragging load running, at the same it directly controlling for suspension control signal is turned again Velocity modulation section.The technical parameter of the direct current generator is as shown in table 3 below.
The technical parameter of 3 EC90M485500RGOL direct current generator of table
In conjunction with upper table 3, further according to UaIa=EaIa+Ia 2Ra, PI=PM+PCuaTwo equations and double-wheel self-balancing robot Inherent technology parameter measure the resistance R of both ends of the motor armature in systema, inductance La, time constant of electric motors Kt, viscous damping system Number B, back EMF coefficient Ke, rotor rotary inertia J, go out both ends of the motor armature inductance L in system by apparatus measuresa And the weight M of robot.Finally by following formulaCalculate two The parameter in self-balance robot system kinetics equation and sliding mode controller is taken turns, so that the control of system is more accurate.
System emulation is carried out to β value according to above-mentioned model parameter and show the β value under particular model parameter referring to Fig. 7 Analogous diagram;From figure 7 it can be seen that system tends towards stability, and the relationship between desired angle and speed meets when β value is -0.14 The value of setting.
In order to further verify the attainable technical effect of technical solution of the present invention institute, in same double-wheel self-balancing robot Under system model parameter, it is imitative that data are carried out to Sliding Mode Controller of the present invention and prior art pid algorithm controller respectively Very.Referring to Fig. 8-a, it show and is emulated in the case where speed reference signal is sine wave using the speed tracing of adaptive sliding-mode observer Figure, Fig. 8-b are the sliding formwork control velocity error analogous diagram in the case where speed reference signal is sine wave, and Fig. 8-c is to believe in speed reference Number for sliding formwork pilot angle degree error analogous diagram under sine wave, Fig. 8-d is the sliding mode controller in the case where speed reference signal is sine wave Output quantity can reach tracking effect well as can be seen that actual speed and angle error in tracking very little from analogous diagram The response speed of fruit, system is very fast, due to the balance moving principle in automatically controlling, will appear when speed tracing Phase shift phenomenon, Fig. 9 a-d are that double-wheel self-balancing robot uses prior art PID control in the case where speed reference signal is sine wave The performance curve of algorithm, from the comparison of Fig. 8 and Fig. 9 as can be seen that the adaptive sliding-mode observer of the design can be such that system responds Faster, robustness is stronger for speed, can be seen that from speed and angular error due to phase shift phenomenon, so using adaptive sliding mode Control, the speed tracing error of system is slightly bigger, but when equilbrium position, using PID control, system will appear gently Micro- jitter phenomenon, effect are obviously not so good as the effect using adaptive sliding mode controller, and using the angleonly tracking of PID control Error is bigger, in addition can be seen that from controller output quantity using adaptive sliding mode controller, and system is more stable, with the obvious advantage, In order to further verify the design sliding mode controller advantage, due to have in square-wave signal from 0 change to immediately 1 when It carves, can preferably verify the characteristics such as system robustness and response speed, Figure 10 a-d is in the case where speed reference signal is square wave Using the performance curve of adaptive sliding-mode observer, Figure 11 a-d is the performance that PID control is used in the case where speed reference signal is square wave Curve, as can be seen that system is when changing to 1 by 0 from Figure 10 and 11, system uses the response speed of adaptive sliding-mode observer more Fastly, speed tracing effect is more preferable, and robustness is stronger.
The above description of the embodiment is only used to help understand the method for the present invention and its core ideas.It should be pointed out that pair For those skilled in the art, without departing from the principle of the present invention, the present invention can also be carried out Some improvements and modifications, these improvements and modifications also fall within the scope of protection of the claims of the present invention.
The foregoing description of the disclosed embodiments enables those skilled in the art to implement or use the present invention. Various modifications to these embodiments will be readily apparent to those skilled in the art, defined in the present invention General Principle can realize in other embodiments without departing from the spirit or scope of the present invention.Therefore, this hair It is bright to be not intended to be limited to these embodiments shown in the present invention, and be to fit to special with principles of this disclosure and novelty The consistent widest scope of point.

Claims (5)

1. a kind of double-wheel self-balancing robot adaptive sliding mode variable structure control system, which is characterized in that including power module, top Spiral shell instrument, accelerometer, turn to potentiometer, control unit, first motor drive module, the second motor drive module, first motor, Second motor, the first encoder and second encoder, wherein
The power module is used for system power supply;
The gyroscope sends that information to described control unit for detecting self-balance robot car body drift angle information;
The accelerometer is used to detect the acceleration information of self-balance robot, and it is single to send that information to the control Member;
The direction information for turning to potentiometer and being used to detect self-balance robot, and it is single to send that information to the control Member;
First encoder and the second encoder are used to detect the velocity information of self-balance robot, and the information is sent out Give described control unit;
Described control unit calculates output control according to the drift angle information, acceleration information, direction information and velocity information Signal, and it is sent to the first motor drive module and second motor drive module;
The first motor drive module and second motor drive module output PWM drive signal make the first motor and The second motor rotation;
Described control unit includes Kalman's data fusion module, speed Sliding Mode Controller and angle sliding moding structure control Device processed, wherein
Kalman's data fusion module is used to carrying out the drift angle information and the acceleration information into data fusion, and will Fuse information is sent to the angle Sliding Mode Controller;
The fuse information and the speed that the angle Sliding Mode Controller is exported according to Kalman's data fusion module Spend the feedback information output control signal of Sliding Mode Controller;
The feedback information is determined by following back analysis equations:
θr=β V, wherein θrThe feedback information of angle Sliding Mode Controller, V are fed back to for speed Sliding Mode Controller For present speed, β is constant, between the value range -0.15 of value to 0.15;
The output control signal of the angle Sliding Mode Controller is determined by following output equation:
Wherein Δ T is the sampling time,Y=β b2, Z=b1-βc2b2,For adaptive item;s2For angle Sliding variable, ε2For system perspective error constant item, λ2For speed real constant item, sat (s2) it is ramp function, eθFor angle mistake Difference,For the first derivative of car body drift angle,For the first derivative of angular error;
The speed Sliding Mode Controller is according to the output of the velocity information and the angle Sliding Mode Controller Signal is controlled, exports the feedback information, output quantity U is determined by following equationWherein, s1For speed sliding variable, VrFor reference velocity,For ginseng Examine the first derivative of speed, evFor velocity error, ε1For system speed error constant, λ1For angle real constant item;
The speed Sliding Mode Controller and angle Sliding Mode Controller according to classical mechanics analytic approach and are based on energy It measures the Lagrange algorithm of analysis and establishes the kinetics equation (1) of following double-wheel self-balancing robot and design:
Wherein, U is that the output of Sliding Mode Controller controls signal, and θ is the car body drift angle of double-wheel self-balancing robot, ev= V-VrFor present speed V and reference velocity VrSpeed difference, a1、b1、c1、d1、a2、b2、c2、d2For double-wheel self-balancing robot Model parameter.
2. double-wheel self-balancing robot adaptive sliding mode variable structure control system according to claim 1, which is characterized in that The angle Sliding Mode Controller is used and is carried out self adaptive control, adaptive item based on function approximation mode are as follows:Wherein For Laguerre basic function, For the parameter sets of orthogonal family of function Laguerre polynomials items,For the coefficient of each, For Laguerre basic function multinomial.
3. double-wheel self-balancing robot adaptive sliding mode variable structure control system according to claim 1, which is characterized in that In the angle Sliding Mode Controller and the speed Sliding Mode Controller, using ramp functionWherein, Δ is known as boundary layer.
4. double-wheel self-balancing robot adaptive sliding mode variable structure control system according to claim 1, which is characterized in that The β value is -0.14.
5. double-wheel self-balancing robot adaptive sliding mode variable structure control system according to claim 1, which is characterized in that a1、b1、c1、d1、a2、b2、c2、d2Value determined by following formula:
Wherein,M is the quality of double-wheel self-balancing robot, and g is acceleration of gravity, L be mass center from The distance of wheel center, J are the rotary inertia of self-balance robot car body, VrFor reference velocity, KtFor motor torque constant, Ke For back EMF coefficient, RaFor both ends of the motor armature resistance.
CN201710790443.9A 2015-08-17 2015-08-17 A kind of double-wheel self-balancing robot adaptive sliding mode variable structure control system Active CN107368081B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201710790443.9A CN107368081B (en) 2015-08-17 2015-08-17 A kind of double-wheel self-balancing robot adaptive sliding mode variable structure control system

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201710790443.9A CN107368081B (en) 2015-08-17 2015-08-17 A kind of double-wheel self-balancing robot adaptive sliding mode variable structure control system
CN201510506091.0A CN105116729B (en) 2015-08-17 2015-08-17 A kind of double-wheel self-balancing robot adaptive sliding mode variable structure control method

Related Parent Applications (1)

Application Number Title Priority Date Filing Date
CN201510506091.0A Division CN105116729B (en) 2015-08-17 2015-08-17 A kind of double-wheel self-balancing robot adaptive sliding mode variable structure control method

Publications (2)

Publication Number Publication Date
CN107368081A CN107368081A (en) 2017-11-21
CN107368081B true CN107368081B (en) 2019-07-30

Family

ID=54664748

Family Applications (2)

Application Number Title Priority Date Filing Date
CN201710790443.9A Active CN107368081B (en) 2015-08-17 2015-08-17 A kind of double-wheel self-balancing robot adaptive sliding mode variable structure control system
CN201510506091.0A Active CN105116729B (en) 2015-08-17 2015-08-17 A kind of double-wheel self-balancing robot adaptive sliding mode variable structure control method

Family Applications After (1)

Application Number Title Priority Date Filing Date
CN201510506091.0A Active CN105116729B (en) 2015-08-17 2015-08-17 A kind of double-wheel self-balancing robot adaptive sliding mode variable structure control method

Country Status (1)

Country Link
CN (2) CN107368081B (en)

Families Citing this family (21)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CZ307125B6 (en) * 2015-11-30 2018-01-24 Vysoká Škola Báňská-Technická Univerzita Ostrava Motion control of anthropomorphic robotic systems with many degrees of freedom based on principles of independent motion control in the direction of characteristic vectors of the linearized dynamic Lagrange equation and the anthropomorphic robotic system
CN105759823A (en) * 2016-04-27 2016-07-13 长江大学 Track-information-based control system and method for two-wheel self-balancing dolly
CN106078744B (en) * 2016-06-30 2018-07-20 杭州电子科技大学 A kind of double-wheel self-balancing robot Sliding Mode Adaptive Control system
CN106182000B (en) * 2016-06-30 2018-07-20 杭州电子科技大学 A kind of double-wheel self-balancing robot control method based on part known parameters
CN106452206B (en) * 2016-06-30 2018-09-11 杭州电子科技大学 A kind of Sliding Mode Adaptive Control device of double-wheel self-balancing robot
CN106239503B (en) * 2016-06-30 2018-07-20 杭州电子科技大学 A kind of double-wheel self-balancing robot control system based on part known parameters
CN106041934B (en) * 2016-06-30 2018-07-20 杭州电子科技大学 A kind of double-wheel self-balancing robot Sliding Mode Adaptive Control method
CN107562063A (en) * 2016-06-30 2018-01-09 沈阳新松机器人自动化股份有限公司 A kind of self-balance robot attitude control method and system
CN106154831B (en) * 2016-07-25 2018-09-18 厦门大学 A kind of intelligent automobile longitudinal direction neural network sliding mode control method based on learning method
CN107856762B (en) * 2017-11-13 2024-03-05 北京赛曙科技有限公司 Motorcycle type robot
CN108062024B (en) * 2017-12-15 2020-03-31 陕西理工大学 Sliding mode control method for inversion of mobile robot by considering resistance
CN109067264B (en) * 2018-09-17 2020-07-28 长安大学 Balance car system and control method thereof
CN109407689B (en) * 2018-12-19 2020-02-21 四川大学 Fuzzy control method and device for balance robot and balance robot
CN110109353B (en) * 2019-04-17 2022-01-11 杭州电子科技大学 Fuzzy self-adaptive sliding-mode control system of counteractive wheel balance bicycle robot
CN110109354B (en) * 2019-04-17 2022-01-07 杭州电子科技大学 Self-adaptive sliding mode control method for counteractive wheel balance bicycle robot
CN110275439B (en) * 2019-06-28 2020-05-26 四川大学 Control method of self-balancing trolley and design method and device of controller
CN112947072B (en) * 2021-01-28 2024-04-05 西安建筑科技大学 Mobile robot driving control method, system and equipment based on sliding mode variable structure
CN113238563B (en) * 2021-06-04 2022-07-22 重庆大学 High-real-time automatic driving motion planning method
CN113419433B (en) * 2021-07-23 2022-07-05 合肥中科深谷科技发展有限公司 Design method of tracking controller of under-actuated system of self-balancing electric wheelchair
CN114019825A (en) * 2021-10-08 2022-02-08 杭州电子科技大学 Sliding mode control method for balance bicycle based on observer and self-adaptive combination
CN115202371B (en) * 2022-09-19 2023-02-07 深圳市凯之成智能装备有限公司 Motion control method of flat plate cleaning robot and related device

Family Cites Families (15)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP4515407B2 (en) * 2006-04-03 2010-07-28 川崎重工業株式会社 Control method for variable valve timing mechanism, control device, and motorcycle including the control device
CN100491083C (en) * 2007-07-27 2009-05-27 北京工业大学 Flexible double-wheel self-balancing robot posture detecting method
CN201228037Y (en) * 2008-06-16 2009-04-29 周惠兴 Two-wheel self balancing electric motor vehicle
US8041456B1 (en) * 2008-10-22 2011-10-18 Anybots, Inc. Self-balancing robot including an ultracapacitor power source
US8160747B1 (en) * 2008-10-24 2012-04-17 Anybots, Inc. Remotely controlled self-balancing robot including kinematic image stabilization
CN101554726B (en) * 2009-05-15 2011-01-19 北京工业大学 Flexible two-wheel self-balance robot system and motion control method thereof
US9020639B2 (en) * 2009-08-06 2015-04-28 The Regents Of The University Of California Multimodal dynamic robotic systems
CN103019236B (en) * 2011-09-26 2015-07-08 东莞易步机器人有限公司 Two-wheel car self-support running method
JP5981827B2 (en) * 2012-09-28 2016-08-31 本田技研工業株式会社 Air-fuel ratio control device
CN102874356B (en) * 2012-10-30 2014-11-26 王野 Two-wheel self-balance vehicle control system and two-wheel self-balance vehicle
CN103019239A (en) * 2012-11-27 2013-04-03 江苏大学 Trajectory tracking sliding mode control system and control method for spraying mobile robot
CN103529850B (en) * 2013-10-28 2016-11-16 华南理工大学广州学院 Double-wheel self-balancing car control method
CN104317299B (en) * 2014-11-11 2017-01-25 东南大学 Mixed control method based on trace tracking of wheeled mobile robot
CN104749955B (en) * 2015-03-19 2017-05-10 杭州电子科技大学 Finite time self-balance control method of single-wheel robot
CN204536780U (en) * 2015-04-13 2015-08-05 金华市伊凯动力科技有限公司 A kind of intelligent balance vehicle control

Also Published As

Publication number Publication date
CN105116729A (en) 2015-12-02
CN107368081A (en) 2017-11-21
CN105116729B (en) 2017-11-07

Similar Documents

Publication Publication Date Title
CN107368081B (en) A kind of double-wheel self-balancing robot adaptive sliding mode variable structure control system
Dai et al. A two-wheeled inverted pendulum robot with friction compensation
Hehn et al. A flying inverted pendulum
Park et al. Development and control of a single-wheel robot: Practical Mechatronics approach
Costa et al. Simtwo realistic simulator: A tool for the development and validation of robot software
CN105159083B (en) A kind of high-precision friciton compensation control method of double-frame magnetic suspension CMG frame systems
Jamil et al. Modeling, control of a two-wheeled self-balancing robot
Shaoqiang et al. Modeling and simulation of robot based on Matlab/SimMechanics
CN103853050A (en) PID optimization control method of four-rotor aircraft
Lam Gyroscopic stabilization of a kid-size bicycle
CN103780188B (en) Based on the permanent magnetism spherical rotor adaptive control system of dynamic frictional compensation
CN106452206A (en) Sliding mode adaptive controller with built-in brushless DC motor current loop control for two-wheeled self-balancing robot
González et al. Real-time attitude stabilization of a mini-uav quad-rotor using motor speed feedback
Lupashin et al. Adaptive open-loop aerobatic maneuvers for quadrocopters
CN106078744B (en) A kind of double-wheel self-balancing robot Sliding Mode Adaptive Control system
CN102141814A (en) Balance control method, balance control device and robot
CN107121940A (en) A kind of parafoil four-degree-of-freedom semi-physical emulation platform
Adeel et al. Autonomous dual wheel self balancing robot based on microcontroller
CN110109354B (en) Self-adaptive sliding mode control method for counteractive wheel balance bicycle robot
Zawiski et al. Modelling and optimal control system design for quadrotor platform–an extended approach
Geist et al. The wheelbot: A jumping reaction wheel unicycle
Tamami et al. Proportional Derivative Active Force Control for" X" Configuration Quadcopter.
CN109202883A (en) A kind of position control method of self-balance robot
CN104331082A (en) Two-wheel intelligent vehicle design method for attitude detection error
Morales et al. Mixed energy model for a differential guide mobile robot

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
GR01 Patent grant
GR01 Patent grant
EE01 Entry into force of recordation of patent licensing contract

Application publication date: 20171121

Assignee: HANGZHOU KONXIN SOC Co.,Ltd.

Assignor: HANGZHOU DIANZI University

Contract record no.: X2021330000826

Denomination of invention: An adaptive sliding mode variable structure control system for two wheeled self balancing robot

Granted publication date: 20190730

License type: Common License

Record date: 20211221

EE01 Entry into force of recordation of patent licensing contract