How suyashagnihotri/smart-health-monitoring-system-using-iot works
1. Repository purpose
- This is an IoT health-monitoring project centered on real-time vital sign acquisition and wireless display.
- The core monitored signals are heart rate, SpO₂, and body temperature.
2. Hardware sensing layer
- The sensing node is implemented in nano_sensor_module.ino for an Arduino Nano.
- It reads from a MAX30100 sensor for pulse/oxygen-related measurements and an LM35 for temperature.
- This is the physical data-capture boundary of the system.
3. Gateway / connectivity layer
- nodemcu_health_monitor.ino runs on a NodeMCU (ESP8266).
- The Nano sends sensor data to the NodeMCU over serial communication.
- The NodeMCU acts as the networked gateway, bridging local sensor data to wireless access.
4. User-facing dashboard
- The README indicates the NodeMCU hosts a wireless dashboard for live monitoring.
- Architecturally, this is the main presentation layer: it receives the health readings and exposes them over Wi‑Fi for viewing.
5. Embedded communication boundary
- The main embedded data flow is:
- Sensors → Arduino Nano → serial link → NodeMCU → wireless dashboard
- This is a two-board design, separating sensor acquisition from connectivity/UI hosting.
6. Machine-learning / prediction subsystem
- The presence of disease_model.pkl, label_encoder.pkl, Health data.csv, a.py, and predict_app.py indicates a separate ML-based prediction pipeline.
- This appears to be an offline-trained model packaged for inference, likely used to predict a health/disease category from recorded health data.
7. Data assets for the ML pipeline
- Health data.csv is the dataset source.
- disease_model.pkl stores the trained model.
- label_encoder.pkl stores the class-label mapping used by the model.
- These files form the model artifact boundary, distinct from the embedded sensing path.
8. Python application layer
- predict_app.py is likely the runtime entry point for invoking the trained model.
- a.py is probably a supporting script for training, preprocessing, or experimentation.
- This part of the repo is separate from the Arduino/ESP8266 firmware and likely runs on a PC or server.
9. Repo structure and concerns
- The repository combines firmware, wireless monitoring, and ML prediction in one place, but they are logically separate subsystems.
- There is no obvious cloud backend, database server, or mobile app in the tree; the architecture is primarily edge device + wireless dashboard + local ML artifacts.
10. Documentation / visuals
- The images/ folder and its readme support the project diagram and presentation assets.
- The top-level README is minimal and mainly describes the sensing and wireless monitoring path.
11. Likely architectural diagram boundaries
- A clear diagram should show:
- Physical sensors
- Arduino Nano acquisition
- Serial link
- NodeMCU Wi‑Fi dashboard
- Python ML prediction component
- Trained model files / dataset
- The live monitoring path and ML prediction path should be shown as related but distinct flows.
12. Technology summary
- Embedded: Arduino Nano, NodeMCU/ESP8266, MAX30100, LM35
- Connectivity: serial + Wi‑Fi
- ML/runtime artifacts: Python scripts, pickle model files, CSV dataset
Main entry points: nano_sensor_module.ino Nano firmware · nodemcu_health_monitor.ino Gateway firmware · predict_app.py Predict app · a.py Train script
Components 15
Embedded monitoring
Hardware sensing and wireless dashboard path
- Vital sensors · Heart rate, SpO₂, and temperature sources
- Nano firmware · Reads MAX30100 and LM35, packages sensor values
nano_sensor_module.ino - Serial link · Transfers readings from Nano to NodeMCU
- Gateway firmware · Receives sensor data and serves the wireless monitor
nodemcu_health_monitor.ino - Wi‑Fi dashboard · Wireless presentation of real-time health readings
- Live readings · Real-time vital sign data produced by the embedded path
Prediction pipeline
Offline training artifacts and Python inference
- Health data · Training or source data for the ML subsystem
Health data.csv - Train script · Model-building or preprocessing logic
a.py - Predict app · Loads the model and runs health prediction
predict_app.py - Disease model · Serialized trained classifier
disease_model.pkl - Label encoder · Serialized class-label mapping
label_encoder.pkl - Prediction · Predicted disease or health category
Documentation
README and supporting visuals
- README · Top-level project overview
README.md - Predict notes · ML-specific usage notes
README_predictor.txt - Images notes · Documentation for visual assets
images/readme.md
Connections 16
- Vital sensors → Nano firmware: measure · Physical signals are sampled by the Nano firmware
- Nano firmware → Serial link: send · Arduino Nano forwards readings over serial
- Serial link → Gateway firmware: deliver · NodeMCU receives the sensor payload
- Gateway firmware → Wi‑Fi dashboard: serve · Gateway exposes live readings over Wi‑Fi
- Nano firmware → Live readings: emit · Firmware packages the live health readings
- Live readings → Gateway firmware: forward · Streaming data reaches the gateway boundary
- Health data → Train script: train · Dataset supports model building and experimentation
- Train script → Disease model: fit · Training produces the serialized classifier
- Train script → Label encoder: encode · Training persists the label mapping
- Disease model → Predict app: load · Inference app consumes the trained model artifact
- Label encoder → Predict app: load · Inference app uses the label encoding
- Predict app → Prediction: infer · Python runtime generates the predicted class
- README → Nano firmware: describes · Repository overview documents the embedded path
- README → Gateway firmware: describes · Repository overview documents the wireless gateway
- Predict notes → Predict app: documents · Predictor notes explain the Python inference flow
- Images notes → README: supports · Image documentation supplements the main README