introduction
Testing health status through body fluids is very mature in clinical applications and does provide valuable information for the diagnosis process. However, on the one hand, body fluid testing relies on testing reagents, which are expensive. On the other hand, most testing methods are based on "invasive" processes and are not suitable for high-frequency testing. As another way to reflect physical health, human respiratory gases (lung respiratory gases and digestive tract volatile gases) can also reflect some important physiological processes and metabolic information, and the detection method can make up for the shortcomings of the former to a certain extent.
The purpose of this design is to use the LPC2478 processor with ARM7TDMI-S as the core to control the electronic nose instrument system, analyze and identify the gas detection signal, and provide a friendly graphical user interface (GUI) without a PC, so that users can understand and record their own physical health status through their own operations.
The original intention of this design is to apply this system to the monitoring of the health signs of family members, and mainly focus on detecting the content of ethanol, aromatic hydrocarbon gas compounds in human respiratory gas, and gaseous sulfides and amines volatilized from the human digestive tract, so as to provide an intuitive and convenient check on the health status of alcoholics, smokers, and people with respiratory and gastrointestinal discomfort. The system realizes the principal component analysis (PCA) of the gas detection signal online, and because a large number of sample training processes are required, the system writes the raw data of the artificial neural network (ANN) for further analysis of the gas into the U disk through the USB Host to facilitate data transplantation, and copying the data to the SD memory card is convenient for archiving the results of the user's long-term observation.
System Implementation
The system detects human respiratory gases mainly through efficient gas circuits and their control. For the injected gas, the system has two different detection methods: for higher concentration gases, the stepper motor drives the six-way valve to switch to the "direct injection" state, that is, the gas enters the gas chamber from the injection port and contacts the metal oxide gas sensor array (Gas Sensor Array) in the heated state in the gas chamber; for lower concentration gases, the six-way valve will switch to the "adsorption injection" state, that is, after the gas enters the gas circuit from the injection port, it is enriched in the adsorption and desorption unit (EDU) (normal temperature), and after the enrichment process is completed, the carrier gas enters from the carrier gas port, takes the marker gas out of the EDU under PID temperature control state, and enters the gas chamber. This is the basic detection principle and process for this system to realize the gas detection function. In this process, LPC2478 is required to monitor and measure the gas circuit status (six-way valve switching, EDU temperature control, vacuum pump exhaust rate and gas sensor array signal sampling, etc.) throughout the process, and realize friendly interaction with users through TFT LCD and keyboard array.
After detecting the gas signal, LPC2478 needs to perform principal component analysis (PCA) on the data. Through mathematical modeling, this design improves the traditional PCA analysis algorithm and transforms the data into a "point group" in a two-dimensional principal component coordinate system. These point groups are used to cluster the principal components in the sample gas.
During the entire process of gas detection, it is necessary to provide power for the flow of gas in the gas path. This system uses the 10-bit DAC of LPC2478 to control the drive circuit of the vacuum pump. While adjusting the speed of the vacuum pump, it can also accurately control the flow rate of the gas in the gas path. On the one hand, it can adapt to the rate of gas adsorption during the "adsorption injection" process, and on the other hand, it can take into account the response time of the sensor when the gas is in full contact with the sensor.
Hardware Platform
The experimental prototype of the electronic nose for respiratory gas detection uses the SmartARM2400 development board produced by Guangzhou Zhiyuan Electronics Co., Ltd. and the expansion board made by the project team to realize the control of the gas circuit hardware module and the pre-processing of analog signals. The gas circuit hardware module includes an adsorption and desorption unit, a vacuum pump, a six-way valve, a solenoid valve, a stepper motor, a gas chamber (TGS series metal oxide gas sensor array) and a gas sampling bag. The hardware design block diagram of the system is shown in Figure 1.
The embedded system microcontroller used in the electronic nose instrument is the LPC2478 developed and produced by NXP, based on the ARM7TDMI-S core. It has 512KB on-chip Flash program memory, 98KB on-chip SRAM, dual AHB bus system, advanced vector interrupt controller (VIC), supports up to 32 vector interrupts, excellent true color LCD controller, supports STN and TFT display screens, and has serial interfaces including USB Host, USB OTG, 2-channel CAN, SPI, 2 SSP and 4-way UART controller, as well as 3 I2C bus interfaces and I2S audio interface. In addition, it also has SD/MMC memory card interface, 10-bit ADC, 10-bit DAC, 2 PWM modules, RTC with independent power supply, 4 general timer/counter modules and abundant GPIO pins with flexible configuration of pull-up/pull-down resistors. It can be said that the superior performance and flexible and diverse peripheral module design of LPC2478 have laid a solid foundation for its application in medical instruments and testing equipment.
In the system design, the main LPC2478 functional modules used are color LCD controller, RTC, PWM, USB Host, SD/MMC controller, ADC, DAC, UART, Timer, GPIO, etc. The control and input modules of LPC2478 are connected with the gas and temperature signal sampling circuits on the expansion board, D/A control vacuum pump drive module, PWM stepper motor control module, keyboard array module, EDU and gas sensor heating control module and solenoid valve control module to form the hardware foundation of the entire electronic nose detection instrument. The entire instrument is powered by a 220V switching power supply.
In the actual application of respiratory gas detection, the selection of gas sensors and the production of gas chambers are the key to the design of the instrument. Table 1 lists the metal oxide sensors used in the prototype design stage, the sensitive gases and the corresponding gas concentration detection range.
In actual human breath, the concentration of marker gas is relatively low. However, the application of electronic nose detection technology can significantly reduce the instrument's detection limit for marker gas to about 0.1-0.5ppm. When a single sensor cannot complete the detection of low-concentration gas, sensor array detection technology, EDU efficient enrichment and optimization of gas flow speed in the gas path can help the instrument complete the task of detecting breath gas.
Software Modules
The instrument software design mainly includes the gas sampling control process, PCA principal component analysis and judgment process, and data transmission control process. Figure 2 shows the specific process of software execution.
The gas injection control process includes direct injection process and adsorption injection process. The switching of the two processes is based on the qualitative judgment of gas concentration. At the same time, the gas path switching is achieved by LPC2478 controlling the stepper motor to drive the six-way valve.
Compared with direct injection, adsorption injection adds a temperature control process for EDU and detects low-concentration sample gas in stages. After the injection process is completed, the system will programmatically execute the "cooling delay" and "gas flushing" processes to prepare for the next injection.
At the end of the sampling process, the system will depict the response value output by the gas sensor array in real time on the T (time)-C (concentration) coordinate system of the TFT LCD screen. The sampling process is realized by the interruption generated by the Timer2 of the LPC2478. The sensor response curve will be reproduced on the first page of "Data Analysis", and the main component analysis will be performed on the data after a sampling. Based on the standard gas experiment, the main components in the sample breathing gas can be determined through this analysis process, and the results determined by the LPC2478 will be displayed on the LCD screen.
The embedded system microcontroller used in the electronic nose instrument is the LPC2478 developed and produced by NXP, based on the ARM7TDMI-S core. It has 512KB on-chip Flash program memory, 98KB on-chip SRAM, dual AHB bus system, advanced vector interrupt controller (VIC), supports up to 32 vector interrupts, excellent true color LCD controller, supports STN and TFT display screens, and has serial interfaces including USB Host, USB OTG, 2-channel CAN, SPI, 2 SSP and 4-way UART controller, as well as 3 I2C bus interfaces and I2S audio interface. In addition, it also has SD/MMC memory card interface, 10-bit ADC, 10-bit DAC, 2 PWM modules, RTC with independent power supply, 4 general timer/counter modules and abundant GPIO pins with flexible configuration of pull-up/pull-down resistors. It can be said that the superior performance and flexible and diverse peripheral module design of LPC2478 have laid a solid foundation for its application in medical instruments and testing equipment.
In the system design, the main LPC2478 functional modules used are color LCD controller, RTC, PWM, USB Host, SD/MMC controller, ADC, DAC, UART, Timer, GPIO, etc. The control and input modules of LPC2478 are connected with the gas and temperature signal sampling circuits on the expansion board, D/A control vacuum pump drive module, PWM stepper motor control module, keyboard array module, EDU and gas sensor heating control module and solenoid valve control module to form the hardware foundation of the entire electronic nose detection instrument. The entire instrument is powered by a 220V switching power supply.
In the actual application of respiratory gas detection, the selection of gas sensors and the production of gas chambers are the key to the design of the instrument. Table 1 lists the metal oxide sensors used in the prototype design stage, the sensitive gases and the corresponding gas concentration detection range.
In actual human breath, the concentration of marker gas is relatively low. However, the application of electronic nose detection technology can significantly reduce the instrument's detection limit for marker gas to about 0.1-0.5ppm. When a single sensor cannot complete the detection of low-concentration gas, sensor array detection technology, EDU efficient enrichment and optimization of gas flow speed in the gas path can help the instrument complete the task of detecting breath gas.
Software Modules
The instrument software design mainly includes the gas sampling control process, PCA principal component analysis and judgment process, and data transmission control process. Figure 2 shows the specific process of software execution.
The gas injection control process includes direct injection process and adsorption injection process. The switching of the two processes is based on the qualitative judgment of gas concentration. At the same time, the gas path switching is achieved by LPC2478 controlling the stepper motor to drive the six-way valve.
Compared with direct injection, adsorption injection adds a temperature control process for EDU and detects low-concentration sample gas in stages. After the injection process is completed, the system will programmatically execute the "cooling delay" and "gas flushing" processes to prepare for the next injection.
At the end of the sampling process, the system will depict the response value output by the gas sensor array in real time on the T (time)-C (concentration) coordinate system of the TFT LCD screen. The sampling process is realized by the interruption generated by the Timer2 of the LPC2478. The sensor response curve will be reproduced on the first page of "Data Analysis", and the main component analysis will be performed on the data after a sampling. Based on the standard gas experiment, the main components in the sample breathing gas can be determined through this analysis process, and the results determined by the LPC2478 will be displayed on the LCD screen.
Through the "data transmission" function, the response value of the sensor array to the sample gas can be recorded. Under the management of the USB HOST controller, the data values to be recorded are written to the USB device. These data can be used as the original data for PC artificial neural network (ANN) analysis. On the premise of providing training cases, it is also hoped that the PC can give more accurate diagnosis results through ANN analysis. The system can also read and write data to the SD card, which records the data of each sample gas analysis and the results of PCA analysis, which is conducive to forming a long-term medical record for users. Through UART, the system is connected to the PC, and the serial communication software developed by itself is used on the PC to monitor the operating status of the electronic nose instrument in real time, and manage these data in the form of a database.
When the above process involves specific operations, the system will use the powerful color LCD controller of LPC2478 to interact with the user, making the entire process of respiratory gas detection transparent. Users can monitor their health status through simple operations through system prompts. Figure 3 shows the main operation interface of the LCD display.
Conclusion
The universal human breath gas detection electronic nose instrument designed in this paper is positioned for home use. It is designed for people who have been drinking and smoking for a long time and suffer from respiratory and gastrointestinal discomfort as a result, as well as other user groups with physiological and pathological gastrointestinal discomfort or inflammation. The instrument uses the latest LPC2478 microprocessor developed by NXP, making full use of its color LCD controller, internal ADC, DAC, PWM, Timer and other functional modules to complete the detection of breath gas and PCA-based diagnostic analysis, and combines USB HOST and SD read-write controller to complete data transplantation and transmission, so that the function of the entire electronic nose detection instrument is improved. Figure 4 is an experimental prototype of the breath gas detection electronic nose instrument.
Before using the instrument to test their own respiratory gas, users only need to use the air bag to collect the "blown air" when fasting, and then follow the prompts of the system operation to complete the sampling and testing. It is easy to use and can complete the detection and recording of their own health status through a non-invasive and low-cost operation process.
Previous article:Low-cost, small-size pulse oximeter solution
Next article:Application of Microcontrollers with Hardware Vector Floating Point Units in Medical Electronics
- 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
- [ufun learning] Practical Part 1: "PWM control of DC motor acceleration, deceleration, forward and reverse rotation"
- Practical Power Supply Circuit and Charging Circuit Atlas
- [RVB2601 Creative Application Development] Transplant U8g2 Graphics Library + LCD Weather Display
- Share some problems encountered when using CCS
- Usage of CC6678 Digital Signal Processor (DSP)
- How to read and write EEPROM contents in PIC16F1938 chip
- STLINK cannot recognize the chip
- LSM6DSL motion sensor angular velocity data fluctuation problem
- MOS tube-MOS tube short circuit protection circuit and short circuit protection circuit schematic summary
- Help, has anyone encountered this problem using the Pickit 3 Programmer programming tool?