Design of three-phase electrical signal data acquisition system based on LPC2103

Publisher:BlossomBeautyLatest update time:2014-08-26 Source: 互联网Keywords:LPC2103 Reading articles on mobile phones Scan QR code
Read articles on your mobile phone anytime, anywhere

  Hydraulic equipment driven by three-phase asynchronous motors has been widely used in production practice due to its many advantages in operation, and more and more research has been carried out on the safe and stable operation of hydraulic systems. Among the various characteristic signals that can reflect the operating status of such equipment, the three-phase electrical signal of the motor can fully reflect its hydraulic fault and motor fault [1], and the three-phase electrical signal is stable and not easily interfered with. Therefore, according to the needs of the application, it is very important and meaningful to develop a three-phase electrical signal data acquisition system with high portability and practicality to complete the real-time and accurate collection and storage of the three-phase electrical signal in the operation of hydraulic equipment, so as to realize the state monitoring and fault diagnosis of hydraulic equipment driven by motors.

  1 System hardware development

  According to the application environment of the three-phase electrical signal data acquisition system, the hardware part of the data acquisition system developed in this paper consists of four modules: analog signal acquisition and conditioning unit, data acquisition and processing unit, and data storage and data communication. The principle of the system is shown in Figure 1.

  

 

  1.1 Main control chip unit

  The main control chip is the core part of the entire data acquisition system. According to the design requirements of the application, the following aspects should be considered when selecting the main control chip:

  (1) Small size and rich internal resources to reduce external expansion and the size of the data acquisition system hardware module;

  (2) It has a higher computing speed and improves the accuracy of real-time data;

  (3) Low power consumption and high cost performance.

  Based on the above problems, this design chooses LPC2103 as the main control chip. The minimum system is shown in Figure 2.

  

 

  LPC2103 uses an external crystal oscillator, which consists of CX1, CX2 and a 11.0592MHz crystal oscillator, which is then multiplied by 4 through the internal PLL to provide the chip's internal working clock. CX3, CX4 and Y2 are the real-time clock crystal oscillator parts [2?3].

  1.2 Signal acquisition unit

  The data acquisition system developed in this design acquires signals including three-phase voltage and three-phase current. The relevant hardware design is carried out according to the characteristics of these two signals.

  1.2.1 Three-phase voltage acquisition

  The rated working voltage of the three-phase asynchronous motor driving the hydraulic equipment is mostly 380 V, and the AD chip used in this design is the built-in 10-bit A/D module of LPC2103, which requires the voltage range of the input analog signal to be 0~3.3 V. Therefore, under the premise of achieving accurate measurement, taking into account the convenience of use, the design implementation cycle and economic issues, the three-phase voltage is obtained by resistive voltage division, and the schematic diagram is shown in Figure 3.

  

  The voltage divider circuit is composed of RV1 and Rin1 to divide the collected voltage. Considering the power of the resistor and the volume of the circuit board, the resistance values ​​of the two voltage divider resistors in the application are as follows:

  RIN1 = 75 kΩ, the power is calculated as:

  PRIN1 = 1.87 W. In practice, a voltage divider resistor of PRIN1 = 1.5 × 1.87 W ≈ 3 W will be selected; RV1 = 1 kΩ. The power is calculated as:

  PRV1= 25 mW, so choosing an ordinary resistor can meet the usage requirements.

  At this time, the voltage on RV1 is 0~5 V. The rectifier module composed of op amps U2C and U2D converts the voltage into 0~3.3 V. When using integrated op amps to build signal operation circuits, the principles for selecting the input resistor Rin and feedback resistor Rf of the op amp should be:

  

 

  In summary, the relevant resistors are selected as: R3 = R4 = R5 = 20 kΩ, R6 = 5.1 kΩ. In order to ensure that the conditioning circuit accurately adjusts the +5 V signal to 3.3 V, the feedback resistor R8 of the inverting proportional circuit is 10 kΩ, and the input resistor R7 is implemented by a potentiometer.

  The voltage follower circuit composed of U2A bridges the voltage divider circuit and the rectifier circuit so that they do not affect each other.

  1.2.2 Three-phase current acquisition method

  Since the premise of using the data acquisition system is not to affect the normal operation of the equipment, the three-phase current is obtained by using a perforated Hall current sensor to achieve non-contact measurement. In order to achieve accurate measurement results, the parameters of the Hall sensor are selected according to the rated current of the motor being measured. Among them: Since the impact current of the motor at the moment of starting is 5 to 7 times the rated current, the test shows that the impact current will last for more than ten milliseconds. Considering the safety of the subsequent measurement circuit, a limiting circuit is designed to ensure that the measurement signal is always within the range of ±5 V. The current acquisition circuit is shown in Figure 4.

  

 

  As with voltage measurement, a voltage follower circuit is used to reduce signal attenuation and loss. The limiting circuit consists of RC1, U3B, U3C and diodes D1 and D2, where RC1 is a current limiting resistor. When the input signal Ui is in the range of [-5 V, 5 V], the outputs of U3B and U3C are both positive saturation voltages, at which time D1 and D2 are both cut off, and the output signal Uo = Ui. When the input signal Ui is not in the range of [-5 V, 5 V]:

  (1) When the input signal Ui>5 V, the output of U3C is a negative saturation voltage. At this time, D1 is turned on, U3C becomes a follower circuit, and the output signal Uo=5 V.

  (2) Similarly, when the input signal Ui<-5 V, the output of U3B is a low-level saturation voltage. At this time, D2 is turned on, U3B becomes a follower circuit, and the output signal Uo=-5 V. Therefore, the limiting circuit limits the input signal to the range of [-5 V, 5 V], and the signal will not be distorted.

  Similar to the voltage acquisition circuit, the signal is rectified after the limiting circuit and then sent to the A/D sampling link of the core processor.

  1.3 Data acquisition and storage module

  The data acquisition part uses the built-in 10-bit A/D of LPC2103, and provides the conditioned three-phase electrical signal to its A/D pin.

  According to the design requirements of the data acquisition system, the data acquisition system developed by this design will be able to save a large amount of real-time data in the lower computer when it is inconvenient to communicate with the upper computer. Since the acquisition module uses the built-in 10-bit A/D of LPC2103, its A/D data register is a 32-bit register. In order to save data calculation time and increase the sampling frequency, the result of each sampling is retained in the lower 16 bits, that is, the data of each sampling point is 16 b=2 B. The system sets the sampling frequency to 1 024 Hz. At such a sampling frequency, the amount of data collected by 8 channels in 1 s is: 1 024 × 8 × 2 B = 16 KB. Considering the large amount of data under long-term acquisition and the high transmission rate during data storage, the data storage is completed using an SD card.

  There are two interface modes for communication between SD card and microcontroller: SD and SPI [4]. Since LPC2103 has a serial peripheral SPI bus inside and using the SPI bus can save the I/O resources of the main controller, this design uses the SPI interface to realize the communication between SD card and the main controller. The interface circuit is shown in Figure 5.

  

 

  Configure LPC2103 as the host and SD card as the slave to complete data transmission in SPI mode. Connect the GPIO port P0.9 of the controller to the SD card select line SD_CS; connect the master controller clock signal line SCK0 to the SD card SCK pin to ensure clock synchronization between the master and slave devices; connect the controller's host output slave input line MOSI to the SD card's data input; connect the controller's host input slave output line MISO to the SD card's data output signal line.

  2 System Software Development

  The user selects the data acquisition system operation mode by pressing the button. In operation mode 1, the system collects three-phase electrical signals and sends real-time data to the host computer through the serial port; in operation mode 2, the system collects three-phase electrical signals and saves real-time data to the SD card without communicating with the host computer. The main program flow chart is shown in Figure 6.

 

  The initialization of the program mainly includes six modules: GPIO port, timer module, A/D module, SPI interface unit, UART interface unit, and SD card. The operation of the SD card is completed by sending the corresponding command to the SD card through the main controller according to its data manual. In SPI mode, the instruction of the SD card consists of 6 B. When the main controller sends instructions to the SD card, the high byte is in front and the low byte is in the back. The operation flow is shown in Figure 7.

  

 

  This design uses an SD card with a FAT16 file system. The system partition of the FAT16 file system consists of four parts: the boot sector, FAT table, FDT table, and file data area. Data reading/writing is done in sectors. Since the first three parts of the SD card system partition are very important, data cannot generally be written into the sectors where these three parts are located, otherwise the SD card will not be recognized by the computer. Therefore, before writing data to the SD card, you must first find the location of the boot sector and calculate the starting address and size of the FAT, FDT, and data cluster based on the content. To save the memory of LPC2103, set the SD card write data to single block write mode. Writing to SD also follows the SD card write block timing.

  3 Test Results

  The host computer data test software of this design is developed in the LabVIEW environment. Different developments are performed for the data sent by the serial port and the real-time data stored in the SD card. The data results are shown in Figure 8. The data test software converts the data sent by the serial port to [-5 V, 5 V] for display. In the figure, through calibration conversion, the data acquisition results are accurate and effective.

  

 

  Therefore, the three-phase electrical signal data acquisition system designed in the scheme can lay a good data platform for the research on operating status monitoring of hydraulic power systems based on motor traction.

  4 Conclusion

  This paper proposes a design scheme for a three-phase electrical signal data acquisition system based on LPC2103. The three-phase electrical signal data acquisition system designed with LPC2103 as the core adopts Hall sensors to accurately and safely obtain voltage and current signals. The data storage adopts a combination of SD card storage and serial port data transmission to the host computer storage mode, which increases the application flexibility of the data acquisition system and gives a detailed software and hardware development process. Through the calibration conversion of the test software, the data acquisition results are accurate and effective, which verifies that the three-phase electrical signal data acquisition system designed in the scheme can lay a good data platform for the research on the operating status monitoring of the hydraulic power system based on motor traction.

Keywords:LPC2103 Reference address:Design of three-phase electrical signal data acquisition system based on LPC2103

Previous article:Open FPGA increases test flexibility
Next article:Design of current protection system based on GSM

Latest Power Management Articles
Change More Related Popular Components

EEWorld
subscription
account

EEWorld
service
account

Automotive
development
circle

About Us Customer Service Contact Information Datasheet Sitemap LatestNews


Room 1530, 15th Floor, Building B, No.18 Zhongguancun Street, Haidian District, Beijing, Postal Code: 100190 China Telephone: 008610 8235 0740

Copyright © 2005-2024 EEWORLD.com.cn, Inc. All rights reserved 京ICP证060456号 京ICP备10001474号-1 电信业务审批[2006]字第258号函 京公网安备 11010802033920号