Design and Realization of a Controller for Electric Railing Machine

The electric railing machine is a mechatronics equipment, which is not only used in highways, bridges and ports, but also widely used in prohibited management occasions in various fields. The technical level of the electric railing system design has a great influence on the power consumption, life and reliability of the product. At present, each lane of highway toll stations in my country is equipped with an electric handrail. The fast and stable operation of the electric railing is very important for vehicles to pass through the toll station quickly.

1 Introduction

The electric railing machine is a mechatronics equipment, which is not only used in highways, bridges and ports, but also widely used in prohibited management occasions in various fields. The technical level of the electric railing system design has a great influence on the power consumption, life and reliability of the product. At present, each lane of highway toll stations in my country is equipped with an electric handrail. The fast and stable operation of the electric railing is very important for vehicles to pass through the toll station quickly.

Most of the traditional electric railing machines adopt the structure of relay control with large reduction ratio deceleration asynchronous motor. Most electric railings need to be networked with the host computer. , and detect the travel switch installed on the electric railing machine to control the lifting and falling travel. Due to the instability of the computer and the unreliability of the system, the reliability of the electric fence machine is reduced, and the poor traffic flow on the expressway caused by the failure of the electric fence machine is not uncommon. In addition, the use of a computer as the controller greatly increases the cost of the electric fence machine, and the reason for choosing a computer is only to network with the host computer. Therefore, designing an embedded electric fence machine controller with an Ethernet bus not only solves the problem of reliability And stability problems, but also make the total cost of the system greatly reduced.

2. Overall structure

The electric railing machine designed in this paper uses a low-speed brushless motor to directly drag the railing mechanism. The controller adopts STM32 as the main controller, and the PWM waveform generated by the internal PWM module of STM32 drives the conduction of the power devices in the intelligent power module (IPM). and off to drive the operation of the brushless motor. The controller detects the Hall signal of the brushless motor to calculate the stroke. In the process of electric operation, only the maximum position is lifted as the origin, and the origin detection is realized by detecting the current change of the brushless motor. This solution can not only adapt to the application of different electric handrails, but also can be networked with various lane controllers, and its running comfort has also been greatly improved.

3. Hardware structure

3.1 Hardware circuit

The electric railing machine adopts full digital control method, which greatly reduces the complexity of the hardware circuit. Its hardware circuit consists of power supply circuit, STM32 control circuit, IPM drive circuit, position signal processing and communication circuit and other peripheral circuits. In order to reduce costs and improve product competitiveness, the electric railing machine is designed in a non-isolated way.

3.2 Power Design

The main device of the electric fence machine is a brushless motor. In order to reduce the interference of the motor magnetic field to the power supply and improve the electromagnetic compatibility of the system, the power input channel is designed as a standard two-stage EMI filter, and the front stage is a common mode filter and a rear stage differential mode filter. filter.

3.3 Main control chip

The controller adopts a 32-bit embedded controller based on Cortex-M3 core-STM32F107, which is a microprocessor that is very suitable for network communication. It integrates MAC controller, CAN bus controller and multiple serial communication interfaces on-chip. In addition, this chip also integrates a complete motor control module, which can flexibly control brushless DC motors and other AC and DC motors.

3.4 Position Detection

In order to realize the rapid operation of the electric railing and prevent the impact in place, the Hall sensor is used to detect the stroke of the mechanism, and the internal integrated encoder interface of STM32 can suppress the jitter during rotation.

3.5 Ethernet interface

The STM32F107 integrates a MAC controller, which can output a 25MHz or 50MHz clock signal, can drive an external Ethernet physical layer (PHY) chip, and supports MII and RMII, improving the flexibility of designers to choose the best PHY chip.

In this design, DP83848 is used as PHY chip, which can realize some functions of CSMA/CD.

3.6 Other Communication Interfaces

In order to run with the bus lane controller or network with other systems, in addition to the Ethernet interface, the electric barrier machine also designs the CAN bus interface and the 485 communication interface.

3.7 Ground Sensing Coil Interface

In order to realize the anti-smashing function, the railing machine has a ground-sensing coil interface, and the STM32 timer connection is used to detect the oscillation frequency of the LC oscillation circuit to determine whether there is a car passing by and the speed of the passing. When a car completely passes the barrier position, the barrier will automatically drop.

4. Software Design

The main function of the electric fence machine is to complete the control of the drive of the brushless motor, and to detect the ground induction coil signal. The running and speed parameters of the motor are controlled by the bus. The whole software program adopts the modular design idea, which is written in ANSI C, and combines the functions according to the needs of users to meet the application in different occasions. The system software adopts the Keil MDK development environment.

4.1 ModBus/TCP message structure

The communication between the electric railing machine and the host computer adopts the Ethernet connection and the ModBus/TCP communication protocol, and the railing machine is used as the protocol slave station. The ModBus/TCP packet structure is to package ModBus data into TCP packets. The specific packet structure is shown in Table 1.

4.2 Register Definition

In the communication protocol, the register is defined as the communication protocol between the master and slave stations. For example, the 4001 register is the speed of the guardrail, and the 4002 register is the retarding distance of the guardrail.

5. Operating characteristics

The principle prototype of the electric railing machine controller designed this time is a brushless motor with a power of 60W, a rotor pole number of 100 poles, and a rated motor speed of 100rpm. By testing the railing when the railing is opened to 80 degrees, it can reach 0.3s to 2.0s. speed, and the speed is adjustable.

6 Conclusion

At present, most imported electric railing machines also use similar technology, but the price is several times that of domestic equipment. This design of this electric railing machine controller has the characteristics of simple structure, reliable performance, strong compatibility, etc. It is especially suitable for many Electronic non-stop toll collection system with networked lanes.

The Links:   AA104VC07 MCO500-16IO1