1 Project Introduction
Digital display thermometer and hygrometer is an environmental monitoring device widely used by various manufacturing enterprises today. This project is designed based on the STC15W408AS single-chip microcomputer to collect and detect the temperature and humidity of the environment.
2 Overall Scheme
The overall scheme system block diagram is shown in Figure 2-1. The digital display thermometer and hygrometer based on the STC15W408AS single-chip microcomputer consists of a power supply circuit, an STC15W408AS single-chip microcomputer, a temperature and humidity detection circuit, a digital tube display circuit, and a button setting circuit.

3 Circuit Principle
The power supply part adopts a 5V DC power connection socket and a Micro USB interface sink board design, and the power supply is controlled by a self-locking button.
The DHT11 temperature and humidity sensor is used to collect the real-time temperature and humidity of the detection environment. The STC15W408AS single-chip microcomputer reads the collected temperature and humidity data, and outputs it to the digital tube through the 74HC595 shift register. The three buttons correspond to the setting, addition and subtraction functions. The user can set the upper and lower limits of the collected temperature and humidity through the buttons.
The program download interface reserves a 1x4Pin 2.54mm spacing pin header, which can be used to burn the program using a USB-TTL tool. Use 4 M3 copper column screws to fix the board.

Figure 3-1 Schematic diagram of digital display thermometer and hygrometer based on STC15W408AS
4 Bill of Materials No.
Position
No.
Parameter
Package
Quantity
Item No.
1
R1~R8
510Ω
RES-TH_1/4W
8
C173025
2
R9~R12
2KΩ
RES-TH_1/4W
4
C58593
3
R13~R14
10KΩ
RES-TH_1/4W
3
C61299
4
R16
4.7KΩ
RES-TH_1/4W
1
C173023
5
C1~C3
104
CAP-TH_2.54mm
3
C353909
6
Q1~Q4
S8050
TO-92-3
4
C717453
7
SW1~SW3
K4-6×6_TH
KEY-TH-6×6mm_4P
3
C136684
8
SW4
PB22E09071
SW-TH_6P
1
C194405
9
LED1
FJ5461AH
LED-SEG-TH_12P
1
C54396
10
U1
STC15W408AS
SOP-16
1
C54946
11
U2
74HC595
DIP-16
1
C112387
12
U3
DHT11
SIP-4
1
C117051
13
DC1
DC005-2.0MM
DC-IN-TH_DC005
1
C431533
14
USB1
Micro USB
MICRO-USB-SMD_5P
1
C40957
15
H1
4P Pin Header
2.54mm_1×4P
1
C124378
16
TP1~TP4
Copper Pillar Screw
M3×10+6
4
C551322
17
—
PCB blank
—
1
—
5 Soldering


assembly Figure 5-2 Digital display temperature and humidity meter based on STC15W408AS