Jetson Nano Home Automation: Controlling Lighting with AI

Jetson Nano Home Automation: Controlling Lighting with AI

About
This proof of concept project demonstrates the use of Jetson Nano and OpenCV with a trained classification model to control lighting in a residential setting. The model is trained to distinguish between open and closed states of the entrance door, seamlessly integrated with Homebridge for easy operation. The application monitors the entrance door and adjusts the lighting accordingly. Note that the provided model is trained for a specific environment and may require retraining for optimal results in your environment.

Features

  • Turn on Lights on Opening Door
  • Turn off Lights on Closing Door

Technologies

  • PyTorch
  • OpenCV
  • Python
  • Homebridge

Requirements
Ensure Docker and Docker Compose are installed on your Jetson Nano. Refer to Jetson Interface Installer for setup details.

Starting

  1. Clone the project: $ git clone https://github.com/webnizam/home-automator
  2. Navigate to the project directory: $ cd home-automator
  3. Copy the example environment file: $ cp .example.env .env
  4. Edit .env values as needed
  5. Build the Docker image: $ run ./build.sh or bash build.sh
  6. Run the project: $ run ./run.sh or bash run.sh
  7. The server will initialize at http://{jetson-ip}:8000

References

License
This project is under the MIT license. See the LICENSE file for more details.

Conclusion
The Jetson Nano Home Automator showcases the power of AI in controlling lighting based on door states. With its open-source nature, this project is customizable to meet individual requirements and preferences.