Design of industrial control monitoring system based on FPGA

Publisher:MysticGlowLatest update time:2011-07-11 Keywords:FPGA Reading articles on mobile phones Scan QR code
Read articles on your mobile phone anytime, anywhere

introduction

When the whole machine is working, about 4% of the energy is consumed by various power electronic devices. This consumed energy is dissipated in the form of heat through the heat sink in each module.

In view of the above phenomenon, PT100 platinum resistance temperature sensor can be used to sense the temperature on the surface of the radiator to protect power electronic devices from damage due to operation at high temperatures. The resistance value of metal platinum (Pt) changes with temperature and has good reproducibility and stability. The sensor made using this physical property of platinum is called a platinum resistance temperature sensor. The commonly used platinum resistance temperature sensor has a zero-degree resistance value of 100Ω and a resistance change rate of 0.3851Ω/℃. Platinum resistance temperature sensor has the advantages of high accuracy, good stability, and a wide range of applications. It is the most commonly used temperature sensor.

Serial Peripheral Interface (SPI) is a high-speed synchronous serial input and output port. In recent years, SPI interface is widely used in the expansion of external devices such as external shift registers, DA converters, AD converters, serial EEPROM, LED display drivers, etc. SPI interface can be shared. Therefore, it is easy to form a system with multiple SPI interface devices. Its transmission rate is programmable, the number of connection lines is small, and it has good scalability.

AD7705 is a typical AD converter with SPI interface, which can easily communicate with the controller with SPI module. This paper adopts FPGA as the main controller, and uses its general I/O port to simulate SPI timing to collect two input signals (temperature signal and voltage signal) of AD7705, and sends the collected 16-bit temperature digital signal and 16-bit voltage digital signal to DSP for processing, and then restores the digital signal by algorithm, and finally displays the two actual signals on the 1602 LCD display, so as to realize the real-time monitoring of the temperature and voltage signals.

Hardware design

The main function of this system is to realize real-time dual monitoring of temperature signals and voltage signals of background devices in the field of industrial control. The temperature signal can be converted into a voltage signal of 0 to 2.5 V according to the linear relationship between the PT resistance value and the temperature change. Then it is sent to the 1st channel of AD7705. The voltage signal can be converted into a voltage signal of 0 to 2.5 V by a transformer and sent to the 2nd channel of AD7705, so as to realize the collection of temperature and voltage signals.

1.1 Characteristics of P11 resistor

The resistance value of PT can change with the change of temperature. At 0℃, the resistance value is 100Ω. When the temperature is less than 0℃, the resistance value decreases with the decrease of temperature; when the temperature is greater than 0℃, the resistance value increases with the increase of temperature. The relationship between the change of resistance value and temperature can be expressed by formula 1 and formula 2.

Where R1 is the resistance value of the PT resistor at temperature t, R0 is the resistance value of the PT resistor at 0°C, and equations (1) and (2) are mathematical expressions of the change of the PT resistance value with temperature when the temperature coefficient TCR = 0.003851, where the three coefficients A, B, and C are:

Since the coefficients of t2 and t3 are very small, it can be approximately considered that the resistance of the platinum resistor changes linearly with temperature. Because its temperature coefficient is TCR=0.003851, it can be directly calculated according to the temperature coefficient. If a PT100 platinum resistor is placed around the power device on the surface of the radiator, the temperature can be estimated based on the resistance value of the test point.

1.2 Temperature signal conversion circuit

FIG. 1 shows a temperature signal detection circuit in this system.

In the circuit of Figure 1, R14 is a platinum resistor placed on the surface of the radiator, which is used to sense the temperature of the radiator. The circuit can convert the resistance signal of the PT resistor that changes with the temperature signal into a voltage signal. In this way, the voltage signal of the PT resistor R14 can be converted according to the voltage value of the PTl00-V point. ref-V is the reference voltage signal. After ref-V passes through the differential amplifier circuit shown in Figure 2, it can be calculated according to the parameters of the components in the figure. The final transmitted voltage signal Va is 12 times the difference with the reference voltage.

Figure 3 shows an optocoupler isolation transmission circuit. After the voltage signal Va output by the differential amplifier circuit shown in Figure 2 passes through the optocoupler isolation circuit, it can be transmitted in the form of 1:1, that is, the voltage signal at point Vb is the same as the signal Va after differential amplification. Vb is sent to AD7705 for analog-to-digital conversion. It is then converted into a serial sequence and output to the FPGA for processing, and is also uploaded to the DSP controller.

[page]2 Software Design

The software design of this system is mainly based on the characteristics and operation timing of AD7705, using the general GPIO of FPGA to simulate the SPI timing. Figure 4 shows the main state flow chart of AD7705 in this system. After that, each submodule is written according to the flow chart to complete the real-time acquisition of the two-way signal of AD7705.

2.1 AD7705 Features and Operation Timing

AD7705 is an AD converter device that uses ∑-△ conversion technology to achieve 16-bit code loss-free performance. The device can directly receive low-level input signals from sensors and then generate serial digital outputs. AD7705 only requires a single power supply of 2.7 to 5.25 V, uses dual-channel fully differential analog inputs, and has a differential reference input. When the power supply voltage is 5 V and the reference voltage is 2.5 V, this device can process input signals in the range of 0 to 20 mA and 0 to 2.5 V, and can also process bipolar input signals of ±20 mV to ±2.5 V. Its serial interface can also be configured as a three-wire interface. Its gain value, signal polarity, and update rate selection can all be configured by software using the serial input port. In addition, the device also includes self-calibration and system calibration options to eliminate gain and offset errors of the device itself or the system.

The AD7705 includes six on-chip registers that can be accessed by the user through the serial port. The first of these is the communication register, which is used to manage channel selection, determine whether the next operation is a read or write operation, and which register to read or write next. All communication with the device must begin with a write to the communication register. After power-on or reset, the device will wait for a write operation on the communication register;

The second is the setup register, which is used to determine the calibration mode, gain setting, unipolar/bipolar input, and buffer mode;

The third is the clock register, which includes the filter selection bits and clock control bits;

The fourth is the data register, from which the device output data is read;

The fifth is the zero-scale calibration register. The AD7705 contains two independent zero-scale registers, each of which is responsible for one input channel. They are both 24-bit read and write registers.

The sixth is the full-scale calibration register. The AD7705 contains two independent full-scale registers, each of which is responsible for one input channel. They are all 24-bit read/write registers.

The write operation timing diagram of AD7705 is shown in Figure 5. After the chip select terminal CS is pulled low, data can be sent on the rising edge of the serial clock. When sending data, the high bit comes first.

The read operation timing diagram of AD7705 is shown in Figure 6. When a logic low level is detected at the DRDY signal pin of AD7705, it means that a new output word can be obtained from the data register of AD7705. When the read operation of a complete output word is completed, the DRDY pin immediately returns to a high level. If no data output occurs between two output updates, DRDY will return to a high level 500 input clock times before the next output update. When DRDY is at a high level, a read operation cannot be performed. When the data is updated, DRDY returns to a low level again.

2.2 FPGA interface software design

There are five interface pins between FPGA and AD7705, namely chip select pin CS, serial clock pin SCLK, serial data input pin DIN, serial data output pin DOUT and serial data request pin

DRDY.

Before reading the data register of AD7705, you need to set its clock register and setup register first. The following is a brief explanation using channel 1 as an example. First, send serial data 0x20 to AD7705, indicating that the next operation selects the clock register, then send serial data 0x0C, set the clock to 2 division, then send Oxl0, indicating that the next operation selects the setup register, then send serial data 0x44, indicating that the register mode is set to self-calibration, gain 1, unipolar, and unbuffered, then send 0x38 to AD7705, indicating that the data register of channel 1 can be read, and wait for the DRDY of AD7705 to become low, and then send 16 clocks to read the 16-bit conversion data of channel 1. The data reading of channel 2 is similar to that of channel 1. The data sent are 0x21, 0x0C,

0x11, 0x44, 0x39.

3 Conclusion

This paper uses a finite state machine to implement the interface application of the AD7705 AD converter with SPI interface on FPGA, and collects the two input signals of AD7705 in real time. In fact, the use of general I/O port to simulate SPI timing is simpler than the standard SPI interface IP core, which can save FPGA on-chip resources. Since AD7705 provides dual-channel, low-cost, high-resolution analog-to-digital conversion function, the use of ∑-△ structure to realize analog-to-digital conversion can make the device immune to interference in a noisy environment, so it is very suitable for industrial control applications.

Keywords:FPGA Reference address:Design of industrial control monitoring system based on FPGA

Previous article:Design of a high performance 32-bit shift register unit
Next article:Design of infrared remote control signal receiving module based on FPGA

Recommended ReadingLatest update time:2024-11-17 08:27

Research on Dynamic Aging Technology of FPGA Circuits
1 Introduction FPGA is the abbreviation of Field Programming Gate Array. Users can write programs to reconfigure the logic modules and I/O modules inside the FPGA to realize the logic functions of the chip. In recent years, FPGA chips have been widely used for their large scale, high integration, high r
[Embedded]
Research on Dynamic Aging Technology of FPGA Circuits
Design and implementation of a multi-channel micro-injection pump
Micro-injection pump is an instrument for long-term micro-injection, which is often used in clinical medicine and life science research. This instrument is mainly used for arteriovenous infusion, blood transfusion and precision chemical experiments. The main problem of micro-injection pumps at home and abroad today
[Medical Electronics]
Design and implementation of a multi-channel micro-injection pump
Design of Data Acquisition System Based on SOPC
With the continuous development of integrated circuits, programmable logic devices FPGAs are increasingly widely used due to their powerful functions, flexible design, and short development cycle. Therefore, the design method of the System On Programmable Chip (SOPC) is becoming more and more important. SOPC integrates
[Test Measurement]
Design of Data Acquisition System Based on SOPC
IGLOO's FPGA-based motor control solution
This article introduces the main features and advantages of the IGLOO series, the IGLOO series architecture block diagram, the main features of the motor control daughter board using AGL125, the stepper motor control logic block diagram, the BLDC motor control logic block diagram, and the motor control daughter boar
[Embedded]
IGLOO's FPGA-based motor control solution
A FPGA program loading method based on ARM-Linux
1. Introduction When the FPGA is powered on, the program to be run needs to be loaded from the outside. This process is called program loading. In most cases, the FPGA reads the program from an external dedicated EPROM. This method is slow and can only load fixed programs. Obviously, this method cannot be used
[Microcontroller]
A FPGA program loading method based on ARM-Linux
Design of a New Harmonic Analyzer Based on FPGA
 With the promotion of energy-saving technology and automation technology, the capacity and quantity of power electronic devices such as frequency conversion equipment and current conversion equipment are increasing day by day, making the harmonic pollution in the power grid increasingly serious, bringing harm to the p
[Test Measurement]
Design of a New Harmonic Analyzer Based on FPGA
FPGA manufacturer Anlu Technology plans to IPO on the A-share market and has received strategic investment from Silan Microelectronics/Shenzhen Capital Group
On January 21, the Shanghai Regulatory Bureau disclosed the basic information table of the coaching registration of Shanghai Anlu Information Technology Co., Ltd. (hereinafter referred to as Anlu Technology). It was disclosed that Anlu Technology plans to issue shares for the first time and list on a domestic stock
[Mobile phone portable]
FPGA manufacturer Anlu Technology plans to IPO on the A-share market and has received strategic investment from Silan Microelectronics/Shenzhen Capital Group
Design of real-time image compression system based on DSP and FPGA
The input signal of the image acquisition system currently used is usually a CVBS composite signal in PAL or NTSL format, with a compression rate of 25 frames/s (PAL) or 30 frames/s (NTSC). However, in the fields of industrial control, aerospace, and security, it is sometimes necessary to monitor fast-moving targets
[Embedded]
Design of real-time image compression system based on DSP and FPGA
Latest Embedded 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号