My friend is highly intrigued by the Particle products and projects he’s seen but has a problem he needs help figuring out. I’m constantly telling him to get a few photons and mess around but am not sure how to adress his needs. He has two large dogs and a cat. At night the dogs go upstairs and make a racket or get into stuff and he wants some sort of “alarm” to tell him when they are going upstairs. This alarm shouldn’t care if the cat goes up or if he or his wife go upstairs. Just the dogs and when the alarm is armed or after a certain time at night (I can handle the arm/schedule piece).
What sensors would you use to determine that it’s one of the dogs so they can catch them in the act and train them to stop it?
Seriously is for a friend, my dog goes anyplace she wants.
Do they climb the stairs faster than him or his wife?
Two break-beam sensors could capture the speed of ascent on the stairs… position higher than the cat (i’m thinking his dogs are taller)
if ( Speed > && Speed > )
The best pseudo code I’ve ever seen. I think that might work if speed is a repeated difference. If not I was kind of thinking 3 beams.
If 1 beam.broken = cat
If 3 beam.broken = human
If 2 beam.broken = dog
That’s my bad pseudo code but your idea gave me the idea on how to determine cat/dog/human.
Place a dog treat on a force-sensitive resistor. When the treat goes missing, sound the alarm!
That could work if the dogs are significantly larger than the cat. I was wondering if you could read RFID tags from far enough away to detect them on the stairs? Or maybe a Hall effect sensor, with magnets on the dog collars? Another possibility might be iBeacons.
I don’t think the cheap rfid readers have the range. I looked into it and think it’d be hard to tune an antennae to get the ranged needed. I beacon seems like it might work but can it tell if the dog is at the bottom of the staircase or actually on it? I like that best cause it’s just a fob on the collar and simple “wall wart” maybe half way up. If it can be limited to a 3-4 foot radius…that seems fairly clean. I’ll do some research on the Hall effect, if I can tune the range that just might work. Thanks!
Photon on the dog’s collar in deep sleep most of the day. At night past a certain time it wakes up every 5 minutes (or faster if you have a really bad dog) or wakes up based on an interrupt from an ultra low power accelerometer (2uA so just leave it connected to 3.3V all of the time). Now for the tricky bit, with a router in the basement or even first floor, the reading on WiFi.RSSI() downstairs will be higher (stronger) than the reading upstairs by maybe 10-20dB (a guess). If the reading is noticeably lower than the averaged reading (which you are saving to EEPROM) during the beginning of the “night” mode ( -ddB/dt ), then push-notify the authorities Maybe you have to charge it every 10-20 days for a 950mAh LiPo.
or… you could just add a latching baby gate at the bottom of the stairs, but then you wouldn’t have a reason to make something cool and impress your friends
Second idea if you want a cheaper dog collar. IR transmitter collar that pulses out some random non-TV RC-5 sequence every 10 seconds, then sleeps. Each dog could have a unique ID. This could last for months on a couple AA’s or AAA’s even without turning it on only at night.
Photon with IR demodulator running RC-5 decoder packaged up into a wall wart that doesn’t have to be this small:
Dog walks upstairs and alerts the via push notification as easy as turning on a
I like the last one a lot. Is that a hacked up wall wart or is it 3d printed? If printed…where can I get the STLs!!! I think that’s really doable and could even be used all over the house to track movement in general. Throw in an IR transmitter, PIR, maybe a temp/humidity sensor and for a few hundred $$ you have whole home sensing modules with IR blisters in every room.
Pretty sure with a beacon, you should be able to get a rough signal strength measurement which can translate to an equally rough distance. Just set a reasonable threshold value for when the pooch passes within really close range.
I like @BDub’s IR transmitter idea, too.
I really think the best solution is going to be something like this, with a transmitter on the dogs themselves. Whether it’s Bluetooth, IR, WiFi, magnetic, ultrasonic (might annoy the dogs), or whatever.
I also wonder if you could use a PixyCam with its color tag feature, and a corresponding tag on their collars. That might depend on how hairy the dogs are, how fast they run up the stairs, lighting conditions, etc. But my tests with the PixyCam demo app were pretty responsive…
To @dougal’s point, with a beacon you can get some decent signal strength measurements which can tell you distance. You can also set the transmit power to a something fixed, high or low, so you can set your range and sensitivity of the system pretty easily. Battery life will last forever.
Ultimately, I think something RF is better than IR. IR needs line of sight, so if the collar gets turned around or something blocks the LED or receiver, it stops working.
Will Bluz be able to support this kind of use? Essentially a fixed gateway on the steps and a bluz on a battery shield in a case on the collar. When they see eachother…alarm.
Yup. Bluz can act as a beacon, that is easy. You could then modify the gateway code to only scan for beacon packets, get the RSSI, then hand it to the Photon over SPI and do whatever you need with it. We are adding wrapper support for a lot of the S120 SDK (the central device in Nordic world) so I can add this type of use case to our list so the wrapper functions cover it (though you can always do it with the native SDK as well).