In view of the requirements for the development of analgesic circuits and the characteristics of the human body's physiological response to low electrical frequencies, a medical device analgesic instrument with high precision, stability and reliability, strong anti-interference ability, low power consumption and strong scalability is designed based on LabVIEW and AVR microcontrollers.
1 System Overview
This system includes a host computer module, a communication module and a slave computer module. The host computer uses a human-computer interaction interface written in LabVIEW software, which is easy to use, has good visualization and scalability; the communication part uses a plug-and-play USB communication module, which has a fast data transmission rate and can meet the requirements of real-time feedback of the slave computer monitoring data; the slave computer module is mainly composed of a pulse generation circuit, a boost circuit and a complementary symmetrical pulse output circuit. The main control chip uses Atmega128 from ATMEL, which can receive host computer control commands, complete precise modulation of pulse intensity in various modes, and control symmetrical treatment pulse output. The boost circuit uses the MAX1771DC/DC boost chip from Maxim Integrated Products and the AD52 41 series digital potentiometer from AD to achieve precise and adjustable digital boost. The system function block diagram is shown in Figure 1.
2 System hardware and software and their components
2.1 Host computer LabVIEW human-computer interaction interface
The host computer software is used for user information management and real-time control of the system. This includes real-time display of data collected by the lower computer, as well as storage of user treatment data. The software is written in a graphical programming language, which has a short development time, strong versatility, accurate and simple data processing, strong portability, and a user-friendly interface design, making it easy to operate, with good visualization and scalability. The host computer flow chart is shown in Figure 2.
[page]
The host computer can provide functions for managing patient information, selecting treatment modes, and controlling treatment intensity. It can also display treatment waveforms in real time, so that patients and medical staff can see the treatment status at a glance. Before the system is run, relevant patient information must be entered. The system will automatically generate a record report of the patient's treatment status after the treatment is completed, and provide a printing function, which can be used for medical comparative analysis and evaluation of the treatment effect of this system. Medical staff can choose the mode suitable for the patient from the seven treatment modes currently provided by the system according to the patient's condition, and control the stimulation intensity under different modes to achieve the best treatment effect. The operation interface is shown in Figure 3.
In addition, the system also has a series of modules such as music auxiliary module, timing function module, help system and extended function for users to choose, so as to maximize the operation efficiency.
2.2 Implementation of USB serial communication module
USB (Universal Serial Bus) interface is a new interface technology applied in the PC field in recent years. It is based on a single bus interface technology to meet the needs of various application fields; its plug-and-play, hot-swap support, easy expansion and other features greatly facilitate the use of users, and has gradually become the development trend of modern data transmission. The portability and high data transmission speed of USB are very suitable for this system.
The USB controller uses CH376, which can work in both host and device working modes, and the device working mode is fully compatible with CH372. It has a convenient built-in firmware mode and a flexible external firmware mode. In the built-in firmware mode, the relevant USB protocols are shielded, and the standard USB enumeration configuration process is automatically completed. The local controller does not need to do any processing at all, which simplifies the firmware programming of the single-chip microcomputer. The chip integrates major components such as PLL multiplier, USB interface SIE, data buffer, passive parallel interface, command interpreter, and general firmware program. It has 5 physical endpoints inside. The upload endpoint 2 is used as the sending endpoint of bulk data, and the download endpoint 2 is selected as the receiving endpoint of bulk data. In this case, the buffers of the upload and download endpoints each occupy 64 bytes.
[page]
This paper uses the general driver NIVISA that comes with LabVIEW as the underlying driver of the USB device, and uses the block transfer nodes in the program, namely VISA READ and VISA WRITE, to easily realize the transmission and reception of data and complete the communication requirements between the upper computer and the lower computer.
2.3 Lower computer master boost output circuit
The lower computer controls the pulse generation module and the boost module to perform corresponding operations according to the control commands received from the upper computer, and feeds back information to the upper computer.
With the Atmega128 microcontroller as the lower computer control core, the program outputs PWM stimulation pulses with variable frequency and variable duty cycle. The Atmega128 chip has a PWM wave output pin, and programming it can achieve high-quality PWM wave output. Programming TWI to control the output resistance of the AD5241 chip to modulate the MAX1771 DC-DC boost circuit to achieve multi-level adjustable boost, and the symmetrical pulse module can achieve the output of a stable pulse wave. The output pulse is captured by the built-in AD of Atmega128. Considering that the amplitude of the output signal is between 12 and 100V, and the reference voltage selected by the AD module is 5.0V, the output voltage is connected to the analog input channel through a resistor divider, and then the collected analog voltage value is transmitted to the host computer and multiplied by the corresponding multiples to achieve the reproduction of the output intensity. The function realization flow chart of the lower computer is shown in Figure 5.
3 Output pulse waveform
The upper computer operation interface is connected to the lower computer system through the USB module for system testing. The upper computer control interface is used to send corresponding control instructions to the lower computer to achieve digital boost intensity adjustment and symmetrical pulse waveform output. Figure 6 shows the output waveform of mode 2 (100Hz square wave, 0.2ms pulse width) captured by two channels of Tektronix TDS2014 oscilloscope.
4 Conclusion
This system is based on the combination of the PC-based upper computer control interface and the waveform-generating lower computer, realizing precise and adjustable digital boost and real-time controllable mutually symmetrical pulse output. The adjustment of the pulse output waveform and voltage range can meet the needs of different users. The use of digital potentiometers instead of analog potentiometers makes the control of the system more flexible and convenient. The complementary symmetrical output circuit can ensure the stability of the output voltage and the safety of the user. USB communication makes the connection between the upper computer and the lower computer more convenient and fast, which is conducive to the rapid response and intelligent diagnosis and treatment of the system. This system has good stability, high security, easy-to-operate interface, and broad application prospects.
Previous article:Tire mold inner diameter measurement system based on AVR microcontroller
Next article:Design and implementation of a robot fish voice control system based on AVR and 51 single-chip microcomputer
Recommended ReadingLatest update time:2024-11-16 17:48
- Popular Resources
- Popular amplifiers
- 100 Examples of Microcontroller C Language Applications (with CD-ROM, 3rd Edition) (Wang Huiliang, Wang Dongfeng, Dong Guanqiang)
- Arduino Nano collects temperature and humidity data through LabVIEW and DHT11
- Power Electronics Technology 3rd Edition (Edited by He Yikang and Pan Zaiping)
- Modern Testing Technology and System Integration (Liu Junhua)
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!
- 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
- 【Share】WB-Alibaba Cloud IoT Device Simulator
- Temperature problems solved for you (I) Basic principles of temperature sensing
- Generate PCB files using Altium Designer software
- Multi-level low frequency
- Celebrate the birthday of Infineon Tmall flagship store|【Browse and get gifts】【Order 100% gifts】
- Posted and Non-posted PCIE communication debugging between ARM and DSP
- [Ateli Development Board AT32F421 Review] + Buttons are coming
- Uncover the secrets of the internal components of the power supply. Have you learned it?
- STEVAL-IDB008V1M Bluetooth evaluation board information
- Which Hall sensor 49E is used for steering of children's electric stroller?