⚠️ Disclaimer: This is a simulated project developed for educational and demonstration purposes. It is not an actual implementation of the Fari Roobot hardware but is intended to showcase the core logic, design architecture in fall detection system.
A simulation-based implementation of an embedded system for real-time fall detection using smart polling, circular buffer analysis, and sensor data filtering. Designed for integration with ESP32, FreeRTOS, and ML-based classification logic.
This project demonstrates the design of an embedded AI system for detecting falls using motion data, combined with smart sensor polling, filtering, and lightweight analysis. It simulates how real-time data could be managed using FreeRTOS tasks, adaptive polling, and logic based on movement classification.
- Adaptive polling based on sensor thresholds
- Fall detection using jerk, mean, standard deviation
- Circular buffer logic for temporal data context
- Complementary filter integration
- Simulation of human activities: walking, running, sitting, idle, fall
- Modular structure with FreeRTOS-ready logic
- Expandable for camera-based confirmation module
fari-fall-detection/
│
├── 📁 data_simulation/
│ ├── fall_detection.py
│ |-- simulated_data.py
| └── fall_dataset.csv
│
├── 📁 embedded_logic/
│ ├── main.ino
│
├── 📁 model_training/
│ └── train_model.ipynb
│
├── 📁 images/
│ └── Circuit.png
│
└── Readme.md
Activity | Pattern | Peak Range | Notes |
---|---|---|---|
Walking | Smooth periodic ±0.8 to ±1.0 | < ±1.2 | Low stddev, low peaks |
Running | Faster periodic ±1.2 to ±1.5 + spikes | spikes ~2.0 | Higher stddev, occasional spikes |
Sitting Down | Gradual rise then drop + mild spike | ≤ 1.5 then 2.0 | Rising pattern with sudden transition |
Standing Idle | Low oscillation ±0.3 to ±0.5 | Very low | Almost flatline |
Fall | Sudden spike beyond ±1.8 | > ±1.8 | Sharp change, high stddev |
The simulated data includes sinusoidal inputs with spikes, slow transitions, and jitter that represent real-world motion captured from IMUs. This allows us to test logic without physical hardware.
- ESP32 (target hardware)
- C with FreeRTOS for real-time execution
- Python (NumPy, Matplotlib) for data generation and visualization
- Circular buffer for time-series analysis
- Filters (Complementary/Kalman)
- Optional: ML classification logic (Python)
- Integrate with actual MPU6050 or IMU
- Camera-based confirmation system
- Deploy trained model on MCU (TinyML)
- Add OTA updates and BLE interface
MIT License
- FreeRTOS documentation
- TinyML examples from Edge Impulse / TensorFlow Lite
- Research inspiration from fall detection healthcare systems