Traditional Culture Encyclopedia - Traditional customs - What are the functions of gyroscope and inclination sensor in self-balancing two-wheeled vehicle?

What are the functions of gyroscope and inclination sensor in self-balancing two-wheeled vehicle?

1. The role of gyroscope

The control system of two-wheeled self-balancing robot not only needs real-time inclination signal, but also needs angular velocity to give control quantity. Theoretically, angular velocity can be obtained by deducing the inclination angle measured by accelerometer, but in fact, the result obtained in this way is far lower than that measured by gyroscope, which has the advantage of good dynamic performance.

The direct output value of (1) gyroscope is the angular rate relative to the sensitive axis, and the angular rate can be integrated with time to get the angular value rotating around the sensitive axis. Because the system uses microcontroller cyclic sampling program to obtain gyro angular rate information, that is, sampling once every short time, the integration function is used to calculate the angular value.

(2) The angular velocity signal is measured by gyroscope, and the angle value can be obtained by integrating the angular velocity. However, due to temperature change, friction, unstable torque and other factors, gyro will produce drift error. However, no matter how small the constant drift is, infinite angle error will be obtained through integration. Therefore, gyroscope can not be used as an angle sensor of self-balancing vehicle alone.

2. The role of tilt sensor

(1) The accelerometer in the tilt sensor can measure the dynamic and static linear acceleration. The typical example of static acceleration is gravity acceleration, and the inclination angle can be determined by directly measuring the static gravity acceleration of an object with acceleration counting.

When the acceleration sensor is stationary, the acceleration sensor only outputs the value of gravity acceleration acting on the acceleration sensitive axis, that is, the component value of gravity acceleration. According to the component values of gravity acceleration on each axis, the inclination angles of objects in vertical and horizontal directions can be calculated.

(2) The accelerometer has slow dynamic response and is not suitable for tracking dynamic angular motion; If you expect a quick response, it will cause a lot of noise. Coupled with the limitation of its measuring range, it is not appropriate to use accelerometer alone to detect the inclination of the car body, and it needs to be used in conjunction with other sensors.

3. Principles

Its working principle is mainly based on a basic principle called "dynamic stability". The gyro and acceleration sensor inside the car body are used to detect the change of car body attitude, and the servo control system accurately drives the motor to make corresponding adjustments to maintain the balance of the system.