A smart home system with customizable controls for lights, switches, temperature, and doors, featuring secure login, automatic database backup and error detection, and LSTM-based predictions every 10 minutes. Supports integrations with surveillance, voice-gesture control, and energy optimization systems for enhanced automation
- Predictive Analytics: Implements an LSTM-based model for accurate predictions every 10 minutes, optimizing system efficiency.
- Intuitive User Interface: Provides seamless control over lights, switches, temperature, and doors, ensuring ease of use.
- Customizable Modules: Allows personalized home automation configurations for tailored user experiences.
- Secure Authentication: Enforces password-protected login to safeguard user access.
- Database Management: Ensures automatic backups and error detection to maintain data integrity.
- Smart System Integrations: Supports:
- Secure Access Surveillance System for enhanced security monitoring.
- Voice Gesture Based Control System for hands-free smart home interaction.
- Energy Consumption Optimization System for efficient energy management.
- Run the following command to clone the required repositories:
git clone https://github.com/Smart-Home-Automation-System-Project/Edge-AI-Home-Automation
- Install Mosquitto and client tools:
sudo apt install -y mosquitto mosquitto-clients
- Enable and start the Mosquitto service:
sudo systemctl enable mosquitto sudo systemctl start mosquitto
- Navigate to
src
:cd Edge-AI-Home-Automation/src/
- Generate a password file for your system. Default username and password are
admin
and1234
. You can generate a new password file:Then enter a secure password when prompted.sudo mosquitto_passwd -c /config/passwordfile.txt [your_username]
- Install dependencies
pip install -r requirements.txt
- Start system
- Make executable:
chmod +x start-system.sh chmod +x backup-db.sh chmod +x start-mqtt.sh
- Modify 'config/.env' and update IPs,
JWT_SECRET_KEY
, username and passwords:MQTT_USERNAME=admin MQTT_PASSWORD=1234 MQTT_PORT=1883 JWT_SECRET_KEY=MTI3LjAuMC4xIC0gLSBbMjAvQXByLzIwMjUgMTA6NTU6MDFdICJHRVQgL2F UI_PASSWORD=abcd IP_SAS_SYSTEM=[IP OF Secure-Access-Surveillance-System] IP_ECO_SYSTEM=[IP OF Energy-Consumption-Optimization]
- Run the system:
./run.sh
- Make executable:
- Setup auto-start
- Create a systemd service
sudo nano /etc/systemd/system/ai-home.service
- Paste the following:
[Unit] Description=AI Home Automation Startup Script After=network.target [Service] ExecStart=/bin/bash [/path/to/start-system.sh] WorkingDirectory=[/path/to/] Restart=always User=[your_username] [Install] WantedBy=multi-user.target
- Create a systemd service
- Setup auto-backup and auto-train-model
- Open the crontab editor:
crontab -e
- Add these two lines at the bottom of the file:
# Backup DB daily at 4:00 AM 0 4 * * * [/full/path/to]/backup-db.sh # Train model every Monday at 12:00 AM 0 0 * * 1 /usr/bin/python3 [/full/path/to]/database/train.py
- Open the crontab editor:
- Install Mosquitto and client tools: https://mosquitto.org/download
- Add install directory to
PATH
setx PATH "%PATH%;[C:\path\to\install]"
- Navigate to
src
:cd Edge-AI-Home-Automation/src/
- Generate a password file for your system. Default username and password are
admin
and1234
. You can generate a new password file:Then enter a secure password when prompted.mosquitto_passwd -c /config/passwordfile.txt [your_username]
- Install dependencies
pip install -r requirements.txt
- Start system
- Modify 'config/.env' and update IPs,
JWT_SECRET_KEY
, username and passwords:MQTT_USERNAME=admin MQTT_PASSWORD=1234 MQTT_PORT=1883 JWT_SECRET_KEY=MTI3LjAuMC4xIC0gLSBbMjAvQXByLzIwMjUgMTA6NTU6MDFdICJHRVQgL2F UI_PASSWORD=abcd IP_SAS_SYSTEM=[IP OF Secure-Access-Surveillance-System] IP_ECO_SYSTEM=[IP OF Energy-Consumption-Optimization]
- Run the system:
run.bat
- Modify 'config/.env' and update IPs,