Object detection and alerts

noxcuses

n3wb
Joined
Mar 12, 2015
Messages
12
Reaction score
1
I'm planning on installing a camera in my garage and was wondering if it is possible to detect if a car is in one of two spaces? Not motion but just the presents of a car. If it detects a car, send some sort of output over Ethernet.

I want to use this output to set a home/away flag in my home automation system. Does a inexpensive fixed lense camera exist that can do this? Or can this be done in Blue Iris? I'm planning the system now but want to make sure I purchase what I need. Thanks for the help!
 

tangent

IPCT Contributor
Joined
May 12, 2016
Messages
4,338
Reaction score
3,519
I'm planning on installing a camera in my garage and was wondering if it is possible to detect if a car is in one of two spaces? Not motion but just the presents of a car. If it detects a car, send some sort of output over Ethernet.

I want to use this output to set a home/away flag in my home automation system. Does a inexpensive fixed lense camera exist that can do this? Or can this be done in Blue Iris? I'm planning the system now but want to make sure I purchase what I need. Thanks for the help!
Yes it's possible, but not easy. You'd need to use a camera that has built in video analytics like a Dahua with IVS. You'd set up intrusion regions or missing object detection. Then you'd have a programming project on your hands to subscribe to the cameras.

User @nayr has node version of the dahua http api that would be a good starting point, but it doesn't support IVS yet. You need a pretty new copy of the HTTP API reference for it to have anything on the IVS implementation.

It would probably be simpler to use a couple ultrasonic range finders hooked to an ESP or similar to detect vehicles.
 

noxcuses

n3wb
Joined
Mar 12, 2015
Messages
12
Reaction score
1
It would probably be simpler to use a couple ultrasonic range finders hooked to an ESP or similar to detect vehicles.
That was my original idea. I have a couple Sonoff TH units with a HC-SR04 ultrasonic sensors hot glued to the top. My plan was to stick those on each stall's garage door opener facing the floor. It would publish a Mqtt topic of a car being in the stall or not.

I wanted to check to see if something already existed first. I've used machine vision cameras quite a bit over the years in an industrial setting to inspect part features, presents/absents, measurements, and robot guidance. Dahua even makes a machine vision cameras ( very $$$). Most of those cameras come with built in software or Apps that have tools to configure image processing. I don't have the time for a in depth programming project, so I may go the sensor route.
 

tangent

IPCT Contributor
Joined
May 12, 2016
Messages
4,338
Reaction score
3,519
That was my original idea. I have a couple Sonoff TH units with a HC-SR04 ultrasonic sensors hot glued to the top. My plan was to stick those on each stall's garage door opener facing the floor. It would publish a Mqtt topic of a car being in the stall or not.

I wanted to check to see if something already existed first. I've used machine vision cameras quite a bit over the years in an industrial setting to inspect part features, presents/absents, measurements, and robot guidance. Dahua even makes a machine vision cameras ( very $$$). Most of those cameras come with built in software or Apps that have tools to configure image processing. I don't have the time for a in depth programming project, so I may go the sensor route.
You could probably get ultrasonic sensors working in an hour or two. IVS based detection, extending the node.js api would take me longer. It's a choice between more software and more hardware and a simpler vs more complicated system.

You might be able to do it in blue iris and that might be the simplest of all, but I'm not sure if you can do that type of detection in blue iris.
 

Fastb

Known around here
Joined
Feb 9, 2016
Messages
1,342
Reaction score
934
Location
Seattle, Wa
You could use a laser line (used at many retail store doors) for $30 or so. And wire that to the Alarm In on camera.
If you set the beam to be 5" above the garage floor, you'd get an alert when the tires broke the beam on a) the way in and b) the way out. Or set the beam 2' from the garage floor for a constant state of "alarm in" for presence/absence of cars....
 
Top