1. Introduction
The liquid drip speed control system is a set of control equipment that can improve efficiency and service quality for large hospitals. In particular, the remote monitoring function enables the nurse station to monitor the patient's drip status in real time and adjust the drip speed according to the patient's status. There are many drip control systems on the market. The design point of this article is low cost. Only the cheapest 89C51 and ordinary components are used to realize the whole system.
2. System design requirements
2.1. Slave station design requirements
A. Detect the dripping speed at the drip bucket and use a digital display device to dynamically display the dripping speed (drops/minute).
B. The dripping speed can be controlled by changing the height of the drip bottle. The dripping speed can be set and displayed on the keyboard. The setting range is 20-150 (drops/minute). The control error range is +/-10%+/-1 drop of the setting value.
C. System adjustment time <= 3 minutes.
D. When the liquid level in the drip bottle is lower than the warning value, an alarm signal will be issued
2.2. System communication design requirements
Design and produce a wired monitoring system where the master station controls 16 slave stations
A. Master station function: It has two modes: fixed-point detection and patrol detection; it can display the slave station number and dripping speed transmitted by the slave station; during patrol detection, the master station can arbitrarily set the number of slave stations to be queried, the slave station number and the dripping speed of each slave station; after receiving the alarm signal sent by the slave station, it can sound and light alarm and display the corresponding slave station number; the alarm state can be manually released.
B. Slave function: can output slave number, drip speed and alarm signal; slave number and drip speed can be set arbitrarily; receive drip speed information set by the master station and display it; alarm for abnormal situations.
C. The communication method between the master station and the slave station is not limited, and the communication protocol is self-determined, but the number of signal transmissions should be minimized.
3. System design block diagram
Figure 1 System design diagram
4. Hardware design and demonstration
4.1. Drip speed detection scheme
This article uses a slot-type photocoupler. It is composed of a built-in amplifier and Schmidt integrated circuit of the photointerrupter LG-207 of KODENSHI Company and an indicator light of LITEON Company. The output signal port of the slot-type photocoupler is connected to a light-emitting diode. Because the coupler outputs a shaped pulse signal, the microcontroller can easily read it. The pulse also drives the indicator light-emitting diode, which can clearly and intuitively understand the detection of water droplets falling. Therefore, this device is very suitable for detecting the speed of water drops.
Figure 2 Schematic diagram of slot-type optocoupler circuit
4.2 Liquid level detection alarm solution
The photoelectric sensor is composed of a light-emitting diode and a photoelectric triode. The light-emitting diode and the photoelectric triode are fixed on both sides of the warning position to ensure that the infrared light emitted by the light-emitting diode and the receiving triode are level. The photoelectric triode can receive the infrared light emitted by the light-emitting diode. When the liquid level is normal (higher than the warning position), a high level of 4.2V is output. If the liquid level is lower than the warning position, the light spot triode outputs a low level of 0.2V. In both cases, the output voltage has a significant jump, and the low level emitted by the triode below the warning position can be directly sent to the single-chip microcomputer as an alarm signal.
4.3. Motor drive scheme
Solution 1: DC motor drive. The advantages of DC motors are: they can be self-locking, have strong load capacity, and run smoothly at a voltage of 12V. When the motor stops running, it can easily drag the infusion bottle and make it stop steadily at the corresponding position. This advantage is beneficial for adjusting the height ratio of the drip bottle. However, the DC motor inevitably causes a delay in the start and stop of the motor. Such dragging is somewhat disadvantageous for improving the positioning accuracy of the infusion bottle and the drip speed control. The control circuit uses a slow relay to control the opening or closing of the motor. As long as there is a voltage of 12V, the forward and reverse rotation of the motor can be adjusted by switching the switch. The circuit is simple and easy to implement.
Solution 2: 4-phase 8-beat stepper motor. Each time a pulse is sent to the stepper motor, the motor rotates 0.9 degrees (the stepping speed is 0.9 degrees/Step). Such performance is very beneficial for precise control. However, stepper motors also have obvious shortcomings: they cannot be self-locking, their load capacity is not as good as that of DC motors, their driving current is large, and they are prone to losing steps during operation. When the motor stops running, it cannot stop steadily because it is dragging a heavy load such as an infusion bottle, resulting in changes in the height of the drip bottle.
Taking all aspects into consideration, especially the load capacity of the motor, this paper decided to use a DC motor to drive the system.
4.4. Digital display solution
The character LCD (Liquid Crystal Display) display [3] can display relatively clear prompts using numbers, some symbols and English. It is relatively simple to implement and is sufficient to meet the requirements for the dynamic display of the drip speed of this system.
4.5. Setting scheme of dripping speed adjustment button
Each button switch is connected to a 10K lower resistor, so that it is in the off state and the output is low level, not floating state [4]. Before setting, you must first press the "Ctrl" button to output a high level to P0.5 of the microcontroller, indicating the start of setting. After that, if you press the button "++", a high level is output to P0.6 of the microcontroller; if you press the button "--", a high level is output to P0.7 of the microcontroller. To exit the setting, it is required to give P0.6 and P0.7 a high level at the same time, that is, you need to press the buttons "++" and "--" at the same time to explain the microcontroller.
4.6. System alarm
Sound and light alarm. Once the alarm signal is received, the bird call doorbell alarm circuit will be activated immediately
5. Software Design
5.1. MCU part
The single-chip minimum system uses the 89C51 processor, which is the core of the entire hardware system. It is mainly responsible for setting the speed and displaying it; reading the pulse of the on-site drip and detecting and displaying the on-site drip speed; receiving the alarm signal of the liquid level detection and realizing the alarm.
5.2. Measurement and display of dripping speed
Solution 1: Measure the dripping speed in units of 15 seconds (drops/15 seconds), and convert the speed value into the required speed in units of 1 minute (drops/minute). This solution is considered because the design requires adjustment to the set speed within 3 minutes. If (drops/minute) is directly used as the unit, there will not be enough adjustment time, and the speed in units of 15 seconds will not change too much, which is more stable for motor control.
Solution 2: Measure the time interval t between two consecutive drops of liquid, and then convert it into the number of drops per minute. Since the time interval between two drops of liquid will deviate, the final conversion result will have errors, so it is not adopted.
5.3 Software Flowchart
A. Speed Control Flowchart
Figure 3 DC motor control flow chart
B. Flowchart of the communication program between the PC master station and multiple slaves
Figure 4 Master-slave station communication monitoring process
5.4 Communication Protocol
The communication between the master and slave stations requires a certain communication protocol. The communication protocol used in this question is shown in Table 1.
For example, the master station wants to query a slave station for its current status: the master station sends a query command to the slave station every 0.2s: "machine number (30H~3FH) + query word (0A0H)"; the slave station sends back the status: "machine number + current dripping speed + whether there is an alarm".
6. System Testing
Through actual testing, the photoelectric coupler with its own shaping circuit can still accurately test each drop of liquid after passing through the transparent tube wall of the dropper. Through the pulley placed on the top of the dropper rack, the DC motor can completely control the lifting and lowering of the dropper bottle. Although the control accuracy of the DC motor is not as accurate as that of the stepper motor in theory, through the PI algorithm and making the DC motor only travel 1/2 of the overshoot value each time, the system can still reach the required droplet stability value in 3 minutes.
7. Conclusion
The system uses a motor to control the liquid level and changes the pressure to change the drip speed in the drip tube. Coupled with remote monitoring by the main station, it can effectively reduce the pressure on medical workers. This system can be implemented at a low cost and equipment space. In addition, if an Ethernet interface is added, this system can fully meet the needs of large hospitals.
Previous article:Implementation of serial communication between PC and single chip microcomputer based on duplex mode
Next article:Design of digital thermometer based on AT89C2051
Recommended ReadingLatest update time:2024-11-16 19:35
- Popular Resources
- Popular amplifiers
- Wireless Sensor Network Technology and Applications (Edited by Mou Si, Yin Hong, and Su Xing)
- Modern Electronic Technology Training Course (Edited by Yao Youfeng)
- Modern arc welding power supply and its control
- Small AC Servo Motor Control Circuit Design (by Masaru Ishijima; translated by Xue Liang and Zhu Jianjun, by Masaru Ishijima, Xue Liang, and Zhu Jianjun)
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
- Today at 10:00 am | TI Award Live Broadcast [DIY Home Monitoring Edge AI Box]
- [Raspberry Pi Pico Review] - Start compiling the program 2
- USB2.0 Transactions
- Characteristics of voltage-type electrostatic breakdown of MOS tubes
- EEWORLD University Hall----Live Replay: Protecting Clean Water Sources-ADI Water Quality Monitoring Solutions
- Share: How to convert C program from floating point to fixed point
- MicroPython major historical versions
- Hello, second half of 2020
- Basic knowledge of 5G standards
- How to Reduce Waveform Noise When Measuring with an Oscilloscope