1 Robot Platform
The mobile robot used in this experiment is the AS-U32 AbilityStorm robot produced by Shanghai Guangmaoda Company. This robot is an upgraded version of AS-UⅡ. The main upgraded component is the microcontroller. AS-UⅡ uses Motorola's single-chip microcomputer 68HC11, while AS-U32 uses Philips' RAM7 LPC2103, which makes the robot have more powerful processing capabilities. AS-U32 has the following characteristics:
(1) Autonomous wheeled mobile robot, an intelligent system that is highly open to the external environment. It uses left and right wheels for driving, and the front and rear wheels follow. The driving mode is differential driving, that is, two different or independent movements are combined into one movement. When the movements of two motors are combined into one movement, it is differential driving. If the robot is to walk in a straight line, the speeds of the left and right wheels must be equal; if the robot is to walk in an arc, the speeds of the left and right wheels must be unequal.
(2) The robot has a dedicated software development environment, namely the graphical interactive C language (abbreviated as VJC). VJC consists of two parts: the compilation environment (including interactive command line editing and debugging functions) and the robot operating system. VJC implements a subset of the C language, which includes control statements (for, while, if else), local variables and global variables, arrays, pointers, structures, 16-bit and 32-bit integers, and 32-bit floating-point numbers. One of the major advantages of VJC is that it supports the running of multi-task programs.
(3) The robot is equipped with a certain number of sensors and has a certain ability to perceive the surrounding environment. The sensors include 2 infrared transmitters and 1 infrared receiver module, 2 light sensors and 4 collision sensors. In addition, it also includes a rotary angle encoder and a microphone. The infrared sensor can determine objects within about 120° in front and within a range of 10 to 50 cm; the light sensor can determine the intensity of light; the collision sensor is installed on the collision ring outside the robot and can sense collisions in 8 directions; the microphone has no directionality and can sense the intensity of sound; the rotary encoder is used to measure the angle of rotation of the wheel.
(4) The robot uses LPC2103 to complete data processing. Although the processor has powerful processing capabilities, it is not enough for feedback control, so it must be completed by a PC. The robot has a 4-pin SCI bus, which can facilitate the expansion of the robot [3].
2 Wireless communication hardware platform between PC and robot
2.1 Wireless communication module Considering the characteristics of autonomous mobile robots, wireless communication is an ideal communication method for computers and robots. The CC1000
single-chip RF wireless transceiver module is used in the experiment . The main performance of this module is as follows: (1) The transmission power is 10 mW. (2) The operating frequency is in the ISM band and no application point is required. (3) Interference ability and bit error rate: Based on the FSK modulation method, the efficient forward error correction channel coding technology is adopted to improve the data's ability to resist burst interference and random interference. When the channel bit error rate is 10~2, the actual bit error rate can be 10.5~10.6. (4) Transmission distance: In the case of line of sight, the antenna height is >3 m and the reliable transmission distance is >300 m. (5) Multi-channel, multi-rate: The standard configuration of the wireless communication module provides 8 channels to meet the user's various communication combinations; it can provide multiple baud rates such as 1200 b/s, 2400 b/s, 4800 b/s, 9600 b/s, and the interface baud rate is the same as the wireless transmission baud rate to meet the customer's equipment needs for different baud rates. (6) Dual serial ports, 3 interface modes: The wireless communication module provides 2 serial ports and 3 interface modes. COM1 is a TTL level UART interface, and COM2 is customized by the user as a standard RS-232/RS-485 interface. The available hardware can be configured into 7 different channels, and different interface modes and different verification methods can be selected [3]. 2.2 Overall design framework of robot wireless communication Based on the characteristics of the robot and the wireless communication module, the overall framework of the designed wireless control robot is shown in Figure 1.
3 Design of feedback control system composed of PC and robot
The software used in this experiment PC (host computer) is VC++6.0. There are many ways to use VC for serial communication: you can use the control MSComm or the Win32 API serial communication function. This article chooses the CSerialPort class for serial communication programming (belongs to Win32 API serial communication programming). This programming method is a multi-threaded serial port programming class. Compared with the MSComm control, CSerialPort does not need to add other files when packaging, and the functions are open and transparent, allowing modification. In addition, there is no need to understand data types that are difficult to master [4]. For a detailed introduction in this regard, please refer to reference [4]. The following mainly introduces how the feedback control system is designed.
Open-loop control of the controlled object cannot achieve the ideal control effect, so the robot must be closed-loop controlled. The entire feedback control system is shown in Figure 2.
As can be seen from Figure 2, the controlled object must first be modeled, the relationship between the input and output of the left and right motors of the robot is measured through experiments, and then MATLAB is used to simulate to obtain the model diagram of the controlled object as shown in Figure 3.
As can be seen from the figure, the left and right wheels of the robot have nonlinear characteristics. When the input parameter of the motor is greater than 60, the actual output rate is basically saturated. Therefore, PID control must be added to overcome the nonlinear characteristics of the robot.
In a continuous control system, the control law of the PID control algorithm can be written as follows:
Wherein, u(t) is the output of the PID controller, also known as the control input of the controlled object; ε(t) is the deviation; Kp
is
the proportional coefficient; Ti
is
the integral time constant; Td
is
the differential time constant. In order to implement PID control in a digital control system, the continuous PID control law needs to be converted into a discrete PID control law, that is, expressed by a differential equation. For this purpose, T0 is taken
as
the sampling period. Since the sampling period is much smaller than the period of signal change, the integral action in equation (1) can be approximated by the matrix area summation method, and the differential action can be approximated by the backward difference method. Then equation (1) can be converted into:
Equation (4) is called the recursive formula of the PID controller. Applying equation (4) to calculate the controller output u(k) at the sampling time k can greatly save computer memory space and calculation time, making real-time control possible.
The actuators of many control systems have a memory function. For example, a stepper motor as an actuator has the function of maintaining a historical position. When the controller gives an incremental signal, the actuator moves a certain position from the original position to reach a new equilibrium position. In this case, it is necessary to use an incremental PID control algorithm. Assume that the control input increment of the controlled object is Δu(k), that is:
Formula (5) is called the incremental PID control algorithm.
The incremental PID and position PID control algorithms are essentially the same, with only some differences in the calculation method. The incremental algorithm is generally used for objects such as stepper motors. However, since the motor of the robot used in this paper is not a stepper motor, the control quantity it inputs should be an absolute value. Therefore, this paper adopts the position PID algorithm [5].
There are various methods for adjusting the three PID parameters. In this experiment, the trial and error method is mainly used. The trial and error method must also follow certain rules. Generally speaking, increasing the proportional coefficient Kp will speed up the system response speed and reduce the system static error, but it will directly affect the stability of the system. Increasing the integral time constant Ti is conducive to improving the stability of the system, but it also increases the adjustment time of the system to eliminate the steady-state error. The differential control effect will improve the dynamic performance of the system.
In the design of the entire feedback system, another important issue is the sampling time T of the system. The sampling time of this system cannot be set too short. Since the robot's speed measurement is completed by a photoelectric encoder, and the code disk stripes used in the experiment are only 66 equal parts, the time is too short and the speed measurement is inaccurate. At the same time, due to the enhanced differential effect, the speed value jitters greatly. In addition, the robot itself has nonlinear characteristics, so it is necessary to choose a suitable sampling time. After experiments, when the sampling time is ≥ 0.5 s, the speed of the robot's feedback is relatively stable and the jitter is significantly reduced. The program flow chart of the entire feedback control system is shown in Figure 4.
4 Analysis of simulation results
By adjusting the three parameters of PID, recording the speed value output by the robot each time, and then simulating with MATLAB, the simulation diagram of the actual data measured is shown in Figure 5.
The wireless real-time feedback control of the robot by the PC proposed in this paper can be realized within a distance of 20 m, and the real-time performance is good. The PC can process the data fed back in each sampling time in a timely manner and send it back to the robot, so that the robot receives the data and the motion state after PID correction in real time, so the robot can walk according to the pre-set state, thus achieving the purpose of control.
Previous article:Sensorless BLDC motor control based on PSoC3 chip
Next article:SA60 and LMD18245 drive DC motor circuit
- Popular Resources
- Popular amplifiers
- Molex leverages SAP solutions to drive smart supply chain collaboration
- Pickering Launches New Future-Proof PXIe Single-Slot Controller for High-Performance Test and Measurement Applications
- CGD and Qorvo to jointly revolutionize motor control solutions
- Advanced gameplay, Harting takes your PCB board connection to a new level!
- Nidec Intelligent Motion is the first to launch an electric clutch ECU for two-wheeled vehicles
- Bosch and Tsinghua University renew cooperation agreement on artificial intelligence research to jointly promote the development of artificial intelligence in the industrial field
- GigaDevice unveils new MCU products, deeply unlocking industrial application scenarios with diversified products and solutions
- Advantech: Investing in Edge AI Innovation to Drive an Intelligent Future
- CGD and QORVO will revolutionize motor control solutions
- Innolux's intelligent steer-by-wire solution makes cars smarter and safer
- 8051 MCU - Parity Check
- How to efficiently balance the sensitivity of tactile sensing interfaces
- What should I do if the servo motor shakes? What causes the servo motor to shake quickly?
- 【Brushless Motor】Analysis of three-phase BLDC motor and sharing of two popular development boards
- Midea Industrial Technology's subsidiaries Clou Electronics and Hekang New Energy jointly appeared at the Munich Battery Energy Storage Exhibition and Solar Energy Exhibition
- Guoxin Sichen | Application of ferroelectric memory PB85RS2MC in power battery management, with a capacity of 2M
- Analysis of common faults of frequency converter
- In a head-on competition with Qualcomm, what kind of cockpit products has Intel come up with?
- Dalian Rongke's all-vanadium liquid flow battery energy storage equipment industrialization project has entered the sprint stage before production
- Allegro MicroSystems Introduces Advanced Magnetic and Inductive Position Sensing Solutions at Electronica 2024
- Car key in the left hand, liveness detection radar in the right hand, UWB is imperative for cars!
- After a decade of rapid development, domestic CIS has entered the market
- Aegis Dagger Battery + Thor EM-i Super Hybrid, Geely New Energy has thrown out two "king bombs"
- A brief discussion on functional safety - fault, error, and failure
- In the smart car 2.0 cycle, these core industry chains are facing major opportunities!
- The United States and Japan are developing new batteries. CATL faces challenges? How should China's new energy battery industry respond?
- Murata launches high-precision 6-axis inertial sensor for automobiles
- Ford patents pre-charge alarm to help save costs and respond to emergencies
- New real-time microcontroller system from Texas Instruments enables smarter processing in automotive and industrial applications
- 【National Technology N32G430】05 The page is initially displayed, system composition
- Introduction to RF5 Architecture
- Can the input voltage Vi of a logic device be higher than the supply voltage Vcc?
- Share some free ADI high-quality materials and prize-winning activities, welcome everyone to actively participate in the download!
- Please help me with the formatting of articles copied from the official account to Word
- Waveform conversion problem
- Let's take a look at what this circuit does and help analyze it.
- Inverter air conditioner outdoor unit control system based on Zhongying SH32F205
- Common Verilog Syntax for FPGA Design
- The interfaces of LED unit boards are all HUB75E, so they cannot be used interchangeably by different brands?