Posts

Showing posts from March, 2021

Motion / person detection with Frigate

 Just a quick update on my progress migrating from MotionEye to Frigate for my IP camera motion detection / camera feeds. Setting up Frigate was super easy. I had it processing the camera feeds and detecting people in just a few minutes offloading all of the heavy ML pieces to the Google Coral USB. The bit that I've just spent a couple of hours toying with is changing my Home Assistant Lovelace dashboards over to using the Frigate camera feeds. Setting it all up was easy, installed the Frigate HA integration which created all of the HA devices etc, updated my Lovelace cards to show the camera feeds and it all appeared to work. The bit I'm pulling my hair out over at the moment is that the live camera feeds really lag on my phone and PC (phone connected via WiFi, PC on a wired LAN connection). My gut feel atm is that it's because of the image sizes (2 of my cameras are 2k resolution) so I'm going to see if there's a way to downscale them for the dashboards. I'll

Google Coral USB Edge TPU

 My Google Coral Edge TPU arrived today which I'm hoping will make person detection on my CCTV fast and simple, and reduce the number of false positives I get currently. Here's a quick unboxing video. And if you're thinking to yourself "What the heck is that??" then here's a little blurb: The Coral USB Accelerator adds an Edge TPU coprocessor to your system. It includes a USB socket you can connect to a host computer to perform accelerated ML inferencing. The on-board Edge TPU is a small ASIC designed by Google that provides high performance ML inferencing with a low power cost. For example, it can execute state-of-the-art mobile vision models such as MobileNet v2 at almost 400 FPS, in a power-efficient manner. In simple terms (that I can almost understand) it takes Machine Learning (ML) tasks and runs them much faster than the HA Blue can do on its own. This means my little HA Blue can do things like detect people and vehicles in a CCTV video feed quickly an

Migration to HA Blue

Image
 I'll post a longer update once I've tidied up a few things and have time to write a more complete evaluation, but today I migrated from a Proxmox VM running hassio over to  my shiny new Odroid HA Blue! The process was painless, create a full snapshot, fire up the Blue and upload/restore. Shut down the old instance, change the IP on the new to match (to avoid having to change MQTT device configs) and reboot the Blue to pick up the correct IP address. I also had to move the ConBee II dongle from the Proxmox server to the Blue, and plugged in the Google Coral Accelerator that arrived today (keep an eye out for an unboxing video). Once I'd confirmed the core functionality was working fine I installed Frigate and created a simple 2 camera config to test that it was working (and using the Coral device, which it was). Result is that I now have the start of an improved CCTV solution that detects people/vehicles and doesn't just record any old motion event.

IP Camera Image Recognition

I've been using MotionEye running in a VM for about a year now and, apart from the occasional moments when it stops showing the camera outputs (I've not had time to dig into understanding why, but it's capturing video/motion events etc in the background) it mostly does what I expected it to do. One of the things I want to experiment with is using ML (Machine Learning) to make sense of the motion events. To this end I've started looking at Frigate  which gave me an excuse to order a Google Coral Accelerator (I've just ordered one from OKdo  if you're looking for a UK supplier). At some point over the next couple of weeks I plan to get this all hooked up and test it out.

It's arrived!

Yay, my HA Blue low-power computer arrived this morning. Here's an unboxing video to whet your appetite until I get time to try it out.

Incoming Home Assistant Blue!

Image
I was looking for a low-power dedicated server to run my Home Assistant instance on so last week I ordered a Home Assistant Blue. This is an ODROID N2+ with a fancy home-assistant branded housing. I just had notice that it's shipped and will arrive tomorrow!!! Can't wait to get it set up and migrate my HA config over to it.

Welcome!

Image
The first time I experimented with home automation was back in the late 80s when I used a simple reed switch connected to a joystick port on a Commodore Amiga 500 to create a basic alarm for my bedroom door. Since then things have moved on and my current setup is powered by Home Assistant controlling smart lighting (mostly Philips Hue) and includes features such as presence detection, voice notifications, CCTV with motion detection and a bunch of other stuff. I've started this blog to share some of my experiments and learnings in the hope that it helps and inspires others.