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.
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
- Popular Resources
- Popular amplifiers
- Analysis and Implementation of MAC Protocol for Wireless Sensor Networks (by Yang Zhijun, Xie Xianjie, and Ding Hongwei)
- MATLAB and FPGA implementation of wireless communication
- Intelligent computing systems (Chen Yunji, Li Ling, Li Wei, Guo Qi, Du Zidong)
- Summary of non-synthesizable statements in FPGA
- Huawei's Strategic Department Director Gai Gang: The cumulative installed base of open source Euler operating system exceeds 10 million sets
- Analysis of the application of several common contact parts in high-voltage connectors of new energy vehicles
- Wiring harness durability test and contact voltage drop test method
- Sn-doped CuO nanostructure-based ethanol gas sensor for real-time drunk driving detection in vehicles
- Design considerations for automotive battery wiring harness
- Do you know all the various motors commonly used in automotive electronics?
- What are the functions of the Internet of Vehicles? What are the uses and benefits of the Internet of Vehicles?
- Power Inverter - A critical safety system for electric vehicles
- Analysis of the information security mechanism of AUTOSAR, the automotive embedded software framework
Professor at Beihang University, dedicated to promoting microcontrollers and embedded systems for over 20 years.
- 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!
- Rambus Launches Industry's First HBM 4 Controller IP: What Are the Technical Details Behind It?
- 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
- Current control scheme of three-phase four-wire active filter based on FPGA
- 2020-7-5-Abdominal breathing training coach (posted again because the previous post had a missing picture)
- Switching power supply spike suppression
- R&D investment of my country's top 100 electronic information companies
- Some Problems in Automobile CAN Communication
- Q&A on Connectivity: Mesh Networking and the Growth of IoT Devices
- Zener diode
- Problems with constant current source composed of op amp + MOS tube
- WeChat group voice Q&A at 2pm: Vicor power experts answer netizens' power design questions
- Ti's C28x series ADC experience