He 2024 J. Phys. Conf. Ser. 2731 012016

Download as pdf or txt
Download as pdf or txt
You are on page 1of 8

Journal of Physics: Conference

Series

PAPER • OPEN ACCESS You may also like


- Solar Water Heater of Absorption Type
Design and Implementation of Intelligent Water using Natural Black Rock
R Aungkurabrut and P Pathike
Heater Based on STC89C52 - Electrochemical Impedance Spectroscopic
Study of Passive Zirconium: II. High-
Temperature, Hydrogenated Aqueous
To cite this article: Ying He 2024 J. Phys.: Conf. Ser. 2731 012016 Solutions
Jiahe Ai, Yingzi Chen, Mirna Urquidi-
Macdonald et al.

- A novel testing and theoretical approach


for air-source heat-pump water heater with
View the article online for updates and enhancements. flash tank vapor-injection
Liu Xianglong, Hu Guang, Zeng Zhi et al.

This content was downloaded from IP address 103.124.10.79 on 11/08/2024 at 14:48


EPES-2023 IOP Publishing
Journal of Physics: Conference Series 2731 (2024) 012016 doi:10.1088/1742-6596/2731/1/012016

Design and Implementation of Intelligent Water Heater Based


on STC89C52

Ying He*
College of Electronic and Information Engineering, Xi 'an Siyuan University, Xi'an
Shanxi 710038, China
*Email: [email protected]

Abstract. Smart home appliances have penetrated into every household, and the water heater
industry is undergoing new changes. At this time, it is urgent to develop an automatic
thermostatic system to ensure that the water temperature remains stable. Intelligent water
heater using the STC89C52 can automatically adjust the water temperature, and the system
control is achieved through the keyboard. The system can set the temperature accurately to
0.1°C and display the temperature value on the display screen. When the temperature set by the
system is higher than the actual temperature, the single chip microcomputer controls the relay
to power on and heat it up. When the collected water temperature is higher than the set
temperature, the relay will turn off, stopping the heating of the water in the water tank. After
experimental verification, it is proved that the system has sufficient stability and reliability,
with the advantages of convenience, safety, and small size.
Keywords. STC89C52; LCD liquid crystal display; temperature sensor; relay.

1. Introduction
With the continuous development and progress of microcontroller technology, its application in
electronic toys, aerospace, military and other technology industries is becoming increasingly
widespread. The emergence of microcontrollers has greatly improved the level of intelligence in these
industries. Meanwhile, with the continuous development of new energy technology, intelligent water
heaters have also been widely applied. Intelligent water heaters can not only achieve precise
temperature control, but also achieve energy conservation and emission reduction, bringing more
convenience and comfort to human life. In the future development, with the continuous progress of
artificial intelligence technology, the control accuracy of intelligent water heaters will become more
and more accurate, which can better meet people's daily needs. In addition, with the continuous
development of Internet of Things technology, smart water heaters will achieve better
interconnectivity with smart home systems, bringing more intelligent experiences to people's lives.
Meanwhile, smart water heaters can also achieve more functions, such as remote control, voice control,
etc., making people's lives more convenient and comfortable [1]. By designing an intelligent water
heater based on STC89C52, precise temperature control, energy conservation and emission reduction,
intelligent control and other functions can be achieved, bringing more convenience and comfort to
people's lives.
Through computer technology, we can fully improve the waste of energy in people's daily life and
deal with things intelligently. The design takes single chip microcomputer as the main control system
to complete the temperature sensing and system control of solar water heater in the real environment.
The single chip microcomputer senses the water temperature through the temperature sensor in the

Content from this work may be used under the terms of the Creative Commons Attribution 3.0 licence. Any further distribution
of this work must maintain attribution to the author(s) and the title of the work, journal citation and DOI.
Published under licence by IOP Publishing Ltd 1
EPES-2023 IOP Publishing
Journal of Physics: Conference Series 2731 (2024) 012016 doi:10.1088/1742-6596/2731/1/012016

system, and feeds back the collected signal to the display module for display. At the same time, it uses
the key to set the temperature range, combined with the control function of the system to keep the
temperature in a constant range. This design is very convenient, compact, safe, and the data obtained is
also very accurate, so it is widely used. The research problems in this paper have prominent practical
value [2].

2. System Overall Structure


The overall design framework of the system consists of six core components: the minimum system of
the microcontroller, the LCD temperature display module, and the button module Block, temperature
sensor module, relay module, and heating control module. These six modules collaborate with each
other to achieve water temperature control. Accurate control. By independently designing and
optimizing each module, ensure the stability and reliability of the overall system performance.
The overall design framework of the system includes six parts: single chip microcomputer
minimum system, LCD temperature display, key module, temperature sensor, relay module and
heating control module. The six modules jointly realize water temperature control. The minimum
system of single chip microcomputer is the core of temperature detection and control system, which is
connected with data acquisition end, status display end and command control end; The display part is
composed of nixie tube display module. Its main function is to display the temperature value, which
can display the water temperature value within 0-100 ℃, and visually display the water temperature
value of the whole system; The keyboard module is mainly a temperature upper and lower limit key
control module, which realizes the setting of upper and lower limits of temperature manually; The
temperature sensor uses DS18B20 to measure the water temperature. The sensor has low cost and is
convenient for circuit implementation. The chip does not need additional ad circuit. It can be directly
connected to the single chip microcomputer to transmit the collected temperature information to the
single chip microcomputer to realize the transmission of temperature value; The relay control circuit
module is the control end of the system. Its control command comes from the single chip
microcomputer. It is triggered by the sensor sensing the water temperature. It is an important measure
to realize the automatic balance of water temperature. The system structure block diagram is shown in
figure 1.

Figure 1. System structure block diagram.

3. System Hardware Circuit Design


The MCU control circuit design of the system includes reset circuit and clock circuit. The pin of the
former is connected with pin 9 of the MCU, and the two pins of the latter are connected with pins 18
and 19 of the MCU [3]. These two circuits are the smallest units to ensure the normal operation of the
whole system. When designing the system, the selected capacitance is 30pf and the crystal oscillator
frequency is 12Mhz. The designed crystal oscillator circuit is bridged with the MCU interface in two

2
EPES-2023 IOP Publishing
Journal of Physics: Conference Series 2731 (2024) 012016 doi:10.1088/1742-6596/2731/1/012016

directions, and the crystal oscillator is transmitted in X1 and X2 to realize the regulation of the clock.
Generally, 11.0592MHZ is the more used crystal oscillator frequency.
The DS18B20 temperature sensor is a simple sensor widely used in various occasions, which only
requires two pins of VCC and GND to provide power. This chip is compact in size, but its temperature
measurement range is quite wide, covering a temperature range of -55 ° C to 125 ° C. When
conducting temperature detection, we can read real-time temperature through the DQ terminal
connected to the microcontroller data This DQ end is not only a channel for data transmission, but also
undertakes an important task of communication with microcontrollers. The single line communication
method adopted by DS18B20 enables data reception and transmission to be achieved through this port.
When the data received by the microcontroller is at a high level, it means that the output value of the
microcontroller is 0, and the transistor will show a low level state. At this time, the output value is 1,
bit high resistance value. Here, we can connect the pull-up resistor to the port and pull up the level
value, so that the output of the port is a high level [4]. DS18B20 adopts external power supply mode,
its VDD end is powered by 3-5.5v power supply, and DQ is connected to p3.5v of MCU 4 pin.
The main purpose of LCD is to view the temperature information of water heater clearly and
conveniently. The display module adopts character LCD LCD1602 for display, and the contrast
adjustment end is VO port [5]. By connecting a 10k resistance partial voltage, the LCD display has
appropriate contrast. The display screen is connected with the single chip microcomputer through the
data lines numbered D0 ~ D7 and connected to the P0 interface of the single chip microcomputer. At
the same time, a pull-up resistance is set outside the interface, and the actual resistance value is 10K;
P2 5, P2. 6, P2. 7 these three interfaces are connected with the RS, RW and en control pins of the
display screen in turn; Rv1 can control and adjust the gray scale of the display screen; As the Yin and
Yang poles in the backlight mode, BLK and Bla can adjust the brightness and darkness of the
backlight. The display circuit design diagram is shown in figure 2.

Figure 2. Display circuit diagram.

The relay has the functions of automatic regulation, safety protection, conversion circuit, etc. What
the system needs to control is a group of relay switches to realize the "heating" function [6]. The relay
is connected with the triode, and its input signal is driven by the PNP triode. To control the on-off of
the relay, the single chip microcomputer only needs to output a high and low level to the triode
through the pin to trigger its output level transformation, so as to control the closing and opening of
the relay. When the triode is turned on, it will output a signal to make the relay pull in, and the LED
indicator light connected in parallel with the relay will turn on, indicating that the relay can drive the
load at this time [7]. The design diagram of heating circuit is shown in figure 3.

3
EPES-2023 IOP Publishing
Journal of Physics: Conference Series 2731 (2024) 012016 doi:10.1088/1742-6596/2731/1/012016

Figure 3. Heating circuit design.


The key circuit design selects the independent keyboard, which is controlled by judging the change
of MCU pin voltage when the button is pressed. K2 key function: setting mode selection. K3 key
function: the upper or lower limit of temperature increases. K4 key function: the upper or lower limit
of temperature is reduced [8]. The key circuit design is shown in figure 4.

Figure 4. Key circuit design.

In the alarm circuit of the system, because the pin output current of the single chip microcomputer
is small, the triode 8550 is used to drive it. P14 is the corresponding pin of the single chip
microcomputer. It turns on the triode by the low level output of the single chip microcomputer. At this
time, the current flows from the + 5V power supply to the ground through the buzzer and the CE pole
of the triode. If there is current flowing through the buzzer, an alarm will sound. Normally, an upper
negative diode needs to be connected between the triode and the negative pole of the buzzer to prevent
the buzzer from burning due to excessive current. LED lamp and MCU P1 1 connection [9]. The
design diagram of alarm circuit is shown in figure 5.

Figure 5. Alarm circuit design diagram.

4. System Software Design


In order to make the program more concise and clear, the system adopts a modular design
approach[10]. Firstly, perform system initialization and then activate the temperature detection
function. Compare the actual temperature with the preset system value. If the actual temperature is

4
EPES-2023 IOP Publishing
Journal of Physics: Conference Series 2731 (2024) 012016 doi:10.1088/1742-6596/2731/1/012016

below the lower limit, the relay will conduct to start heating. If the actual temperature is between the
lower and upper limits, the relay will disconnect to stop heating. Compare the temperature values
again: If the temperature is still below the lower limit, the relay will conduct to add water; If the
temperature is between the lower and upper limits, the relay will disconnect to stop adding water.
Then, call the display subprogram and the key subprogram. At this point, the main program has been
executed. The main program flowchart is shown in figure 6.

Figure 6. Main program flow chart.

5. Integrated Debugging
Debug the design through keil tool. In the simulation link, first check whether the model and
specification of components are correct, then check whether there are errors in the connection of lines,
and then debug with the software after eliminating obvious simulation faults in the system. Firstly, the
designed program is loaded into STC89C52, and the extension of the program is HEX. The simulation
software uses proteus. After loading the program, click the start button in the simulation software. The
whole simulation starts to run, then observe whether the LCD starts normally, adjust the sliding
rheostat, and observe whether the LCD displays the proportional value of combustible gas. When the
display and measurement functions are normal, test whether each button can achieve the expected
function in the simulation software. After continuous debugging of simulation software, find the bug
in the program, and finally complete the design of the whole system.
Function debugging of LCD LCD1602. By connecting the circuit board, the display can display the
current temperature and humidity normally, and the background light can be adjusted normally. At the
beginning of power on, the data displayed by LCD1602 is the first line "cur_tem: 21.4 ℃" and the
second line "H: 28 ℃ L: 18 ℃". When the temperature sensor detects a temperature change, the
content displayed by LCD1602 changes. The second line displays the upper and lower temperature
limits set by the current system, and the first line displays "the currently collected temperature value is
21.4 ℃. After power on, the display content of LCD1602 is shown in figure 7.

5
EPES-2023 IOP Publishing
Journal of Physics: Conference Series 2731 (2024) 012016 doi:10.1088/1742-6596/2731/1/012016

Figure 7. LCD1602 display after power on.


Key function debugging. Key debugging is to debug the three keys on the circuit board. Click the
first button to enter the setting mode. Click the second button to enter the increase of upper or lower
temperature value. The same is true for the adjustment of the lower temperature limit. Key function
debugging is shown in figure 8.

Figure 8. Key function debugging.

The water temperature function commissioning is mainly carried out through the relay. When the
detected water temperature is lower than the lower limit, the relay starts to work to heat the feedwater.
When it is detected that the water temperature is higher than the upper limit, the relay stops working.
Stop heating when the water temperature exceeds the upper limit.
Alarm function debugging. When one of the collected humidity values is lower than the lower
temperature limit or higher than the upper temperature limit, the circuit board LED lamp and buzzer
will alarm. It shows that the current water temperature is 33.2 ℃, and the upper temperature limit is
28 ℃. Water temperature function commissioning and alarm function commissioning are shown in
figure 9. The hardware diagram of the system is shown in figure 10.

Figure 9. Water temperature function


commissioning and alarm function
commissioning.

Figure 10. Physical drawing of system hardware.

6. Conclusion
The research object of this paper is the intelligent control of intelligent water heater based on single
chip microcomputer. This system closely follows the current market demand and uses single chip

6
EPES-2023 IOP Publishing
Journal of Physics: Conference Series 2731 (2024) 012016 doi:10.1088/1742-6596/2731/1/012016

microcomputer to convert the collected water temperature information into discontinuous and
intermittent information for display, so as to facilitate diversified control of water temperature.
Especially in the current intelligent development background, the traditional water temperature control
system is relatively rough, and the control of water temperature can not meet the current requirements
of high accuracy. The system realizes the high-precision water temperature control of the water heater
through the control of single chip microcomputer. Whether from the self-development of the whole
water temperature control system or from the current living needs of people, convenience, quickness
and safety are the intelligent standards in recent years. This design is applied to environments such as
homes, offices, or cars. On the road to future development, the coverage of intelligence will become
increasingly high, and artificial intelligence will gradually replace manpower. Therefore, with the
development of technology, the accuracy of temperature control for intelligent water heaters will
become more and more accurate. The development of future water heater products will focus on
improving user experience, which can be roughly divided into six aspects: comfort, artistry,
refinement, intelligence, health, and scenario oriented. Considering the user's living environment, it is
recommended to target various user groups and explore different demand scenarios when developing
and designing products.

Acknowledgements
This work is supported by 2021 project of the "14th five year plan" of Educational Science in Shaanxi
Province (Grant No. SGH21Y0322).

References
[1] Li Y Y and Liu Y Z 2021 Design of intelligent water leakage alarm system for solar water
heater based on STM32 Equipment Manufacturing Technology (07): 142-144.
[2] Cui J F and Gao W 2020 Design of intelligent water heater based on goal orientation Furniture
41(02): 39-43.
[3] Chen Q M and Liao H F 2023 A Microcontroller based hot water prediction and control system
for electric water heater Household Appliance (04): 63-67
[4] Huang X D and Zheng Y 2020 Design of a solar water heater control system based on a
microcontroller Era Agricultural Machinery 47(04): 88+93
[5] Jiang J H and Zeng Y H 2022 Research on the design and promotion of hot and cold water
valves for water heaters - based on microcontroller intelligent control technology Modern
Commerce and Industry 43(01): 189-191
[6] Cui K L and Tian J 2022 Design of a microcontroller based water heater control system
Electronic Quality (07): 89-95
[7] Wang E B and Li M Q 2023 Design of water level and temperature controller for solar water
heater based on microcontroller Neijiang Technology 44(01): 52-53
[8] Dong T and Liu J Y 2022 Design and implementation of an anti freezing device for solar water
heaters Electronic Technology and Software Engineering (20): 113-116
[9] Tian L and Shi S Y 2022 Research and design of self diagnostic solar water heater control
system Electrical Technology (10): 6-8
[10] Liu H F 2017 Design of remote intelligent household electric water heater control system
Electronic World (10): 45 + 47.

You might also like