Design and implementation of a single-chip microcomputer-based intelligent bathroom monitoring system
TL;DR
The results indicate that a camera-free embedded terminal can provide low-cost safety assistance for small bathrooms while reducing privacy concerns.
Abstract
An intelligent bathroom monitoring system based on the STM32F103C8T6 microcontroller is designed and implemented for small bathrooms that are enclosed, humid, slippery, and usually used by one person at a time. The system integrates Digital Humidity and Temperature sensor 11 (DHT11) temperature-humidity sensing, photoresistor-based illumination detection, dual through-beam infrared entry/exit recognition, bathing timing, safety confirmation, local audible-visual warning, voice/key interaction, and 4G Short Message Service (SMS) and phone-call rescue. The software organizes standby, monitoring, warning, confirmation, and rescue states through a finite-state process. When the infrared trigger sequence indicates that a user has entered the bathroom, the timer starts automatically. If the preset time expires without safety confirmation, or if the user issues a help command, the device activates the buzzer and RGB ring warning before sending an SMS and calling a preset contact. The controller checks the DHT11 data frame, normalizes the illumination sampling value, determines movement direction from the trigger times of the two infrared sensors, and decides whether to start rescue according to timeout, confirmation, exit, and active-help flags. Prototype tests show entry/exit recognition accuracy of 98.3%, voice-command execution success of 95.0%, average local-alarm response time of 0.34 s, SMS success of 95.0%, and phone-call success of 97.5%. The results indicate that a camera-free embedded terminal can provide low-cost safety assistance for small bathrooms while reducing privacy concerns.