motion-detector Svelte Themes

Motion Detector

Desktop App and Server for Raspberry Pi to detect motion and configure actions

Motion Detector

Motion Detector

An Application that utilizes a sensor on a Raspberry Pi to detect motion and collect the data. It provides an App UI to configure actions, which will then be triggered by the sensor.

About The Project · Requirements · Server Installation · Tech Stack · Author


About The Project

https://user-images.githubusercontent.com/44963006/212476461-877e338d-739c-4798-a310-51b64a1e9e24.mp4

Requirements

  • Motion Detector App installed (MacOS, Windows, Ubuntu)
  • Raspberry Pi
    • 64-bit OS
    • Bun installed
    • Python 3 and GPIO zero installed
    • Server (RPi) must only be reached in local network
    • Raspberry Pi with Infrared Sensor connected on GPIO Pin

Server Installation

Raspberry Pi

  1. Clone the repository onto your Raspberry Pi:
git clone https://github.com/lukesthl/motion-detector.git

cd backend; bun i
  1. Setup the Environment:
cp .env.example .env

Edit SERVER_ORIGIN to your preffered name and change the GPIO_PIN to your connected sensor pin.

  1. Start Server:
bun run prod

Tech Stack

Frontend (App)

  • Tauri – Tauri is a framework for building tiny, blazingly fast binaries for all major desktop platforms
  • SvelteKit – SvelteKit is built on Svelte, a UI framework for making interactive webpages
  • Vite – Vite is a build tool for Frontends. It allows for faster development thanks to fast Hot Module Reload (HMR)
  • TailwindCSS - Tailwind CSS is basically a utility-first CSS framework for rapidly building custom user interfaces

Backend (Raspberry Pi Server)

  • Bun – Bun is a fast all-in-one JavaScript runtime like nodejs or deno
  • SQLite – SQL database engine (only one currently supported by bun)

Ideas

Known Limitations

Author

Top categories

Loading Svelte Themes