[OBSOLETE] BI Fusion v3.0 - Adds: Blue Iris Device Type Handler, Blue Iris Camera DTH, Motion Sensing

@JMZ , question for you. I finally got everything working the way I needed to with the camera motion and that whole scenerio a few months ago. I just came across a new issue, that I need your guidance on. I was hoping to have the ability to have a switch turn on or off when the blue iris mode changes. So if the mode changes to Armed turn on this switch if the mode changes to Disarmed turn off this switch. I do not see the ability to do this and was hoping this is something you can build in. Yes I can use webcore to do this but would much rather have it built directly into the app. What are your thoughts?

Thanks JMZ for the great work. I have updated, and can verify that the PTZ moves now work as intended. This Fusion app is such a great part of my total system now that it integrates in a more complete way my Blue Iris Camera system with my Smartthings automation. Thanks again for this valuable work.

1 Like

Hey, glad it’s been working! For your new project, let me make sure I understand. You want the Blue Iris profile (the computer server’s profile, not ST’s mode) to turn a switch on/off? Are you trying to and a layer of protection again BI Fusion’s profile integration failing? (e.g. Blue Iris is stuck in away mode despite ST switching to home and BI Fusion failing). Or are you happy with the mode as BI Fusion sees it? I’m asking because I’m not sure how adding a switch on/off when the mode switches in BI Fusion is going to help you a lot. You can use the built-in Smart lighting from SmartThings to control any light or switch, and can do that for mode changes. Same with webCoRe as you mentioned. Those would be easy to set up. I’m just not sure what you’re trying to accomplish if having the control in BI Fusion is going to make it that much better than what already exists. I should be able to add it no issues, but it’d take me a bit to do it and make sure it doesn’t frag something else out, while adding complexity to the already pretty complex set of preferences pages. If you can give some more detail on your objectives, lets see what we can come up with.

1 Like

I’ll start with the dumb questions- you went through the instructions in the initial post of this thread, and put the URLs from the OAuth preferences section of BI Fusion into the Alerts tab of your camera’s settings, right? That was a lot. Basically, in Blue Iris, make sure the URLs are in the Alerts correctly. When you click the “test” button, it should make your camera device in SmartThings stuck on motion active, and when you hit that button it should also give you feedback, like “ok” or an error message.

The second thing is to make sure you enabled OAuth for the BI Fusion smartapp in the IDE. Just go to that smartapp’s preferences in the IDE and make sure the box is checked.

We’ll start there. I see in your logs that you had the URLs posted in the debug log (the URL is just cut off in the pic, which is good, don’t post those codes publicly!), so that means BI Fusion is good. But there are no motion active entries in the log, so SmartThings isn’t getting anything from Blue Iris. That’s why we’re targeting the Blue Iris settings (and OAuth, that’s caught some other folks too!). Lemme know!

I think I’d missed the OAuth, then enabled it, but then the cams still wouldn’t work. So like I said, I went from scratch and did it properly, then it works = )

1 Like

To be honest what I have been doing is a lot of spring cleaning. Over the last 2 years any time I needed something done I just created a webcore piston. Well after 2 years I starting having some issues with a few things and found out that trying to track down what was wrong was dang near impossible. I had so many duplications that it was causing loops and what not. So I started to clean and clean and clean and ended up removing over 50 pistons. So now after 3 weeks of deep cleaning I have everything perfect. Now going forward my new idea is to try and have a smartapp do something rather than just build a piston. This way I have a much better Idea of where to start troubleshooting. Also, I am finding for my setup at least that using a smartapp has a faster response than webcore. So was just asking, rather than building another piston can this simply be added? Also, another Idea I had was when there is a trigger that activates the camera turn a light on, right now I use webcore to do that, but was thinking why not have it all in 1 location. Thoughts?

@JMZ after thinking about it maybe this is not needed. Have you gotten any feedback from anybody else on it?

On the configure web alert in BI, I am stumped what to enter for the “active” and “inactive” links? Can you help?

If you haven’t looked at it, steps 5-6-7 in the initial post describe how to do this. When you’re in the BI Fusion settings in the app, on the •Blus Iris Camera Installation” page at the bottom there is a place to tap view motion alert URLs. If it’s your first setup, you’ll need to select “do you want to (re)create the motion URLs” so that they generate first, then after you’ve viewed them be sure to turn that off again or they’ll change every time you open the settings. You can also view them on your computer but logging into the API and opening the live logging page, then go into settings and turn on “display URLs in API logs.” Then you can just copy/paste.

Thank you for that. I did read the instructions, but you explained it in more detail, so I was able to get it working. Thanks for writing the code for this! Very cool!

1 Like

sent a couple of beers, much appreciated!

1 Like

Thanks for writing this! It wasn’t too hard to set up and is saving me a lot of false positives from tree shadows. :beers:

1 Like

First, thanks for all the positive feedback! Makes me glad I can help out fellow home automation folks.

Second, if you haven’t seen the email or thread, SmartThings is apparently removing the Contact Book feature on the app:

While BI Fusion was already able to work without that, I just posted a new version (just for the BI Fusion app itself) that expands your options just a bit. Once Contact Book is gone, you’ll need to go into BI Fusion settings to update your push/SMS options. Unfortunately, if you want a push message it’ll go to everyone tied to your hub (not a very good spouse approval factor option), so I expanded the SMS option to include multiple phone numbers. So you can target your notifications when using SMS, and can send to more than just one number.

You’ll notice the phone entry doesn’t auto-format to the pretty “1 (123) 456-7890” but instead will just be “1234567890.” That is just how it’ll look because I changed the input type to a string so you can enter multiple numbers. If you want more than one, it’ll look like “12345678900;12345678909;12345678990”

Let me know if you have any issues.

1 Like

@JMZ if you add the below code to your Camera device handler, the device will show up in the new app as a motion sensor.

mnmn: “SmartThings”, vid: “generic-motion-3”

1 Like

Thanks! Can you point me to any docs or wikis that have info like this in them? Then I can make sure the few other apps I maintain stay up to to date for new app users (I’m in the classic app for now). If not, where do I put this code? Is it in with the rest of the basic info at the start (repository, author, etc)?

Nope. Just reverse engineering some updates they’ve been making to device handlers on their public GitHub.

I read through a good portion of this and I am curious on how this helped with false alerts from tree shadows?

I turned off Blue Iris’s video-based motion detection (well, I masked out the large areas where tree shadows gave me trouble) and set up external triggering based on a PIR motion sensor instead. Since the trees swinging in the wind don’t rapidly change temperatures of the ground / walls, the PIR sensor doesn’t see any motion and doesn’t trigger.

The PIR did still take some adjustment so that it didn’t get triggered by far away, hot car engines, but that wasn’t difficult.

@JMZ, long time ST user, first time with BI Fusion (which rocks btw!)

In the installation instructions in the original post, step 7 talks about setting up Motion Alerts in Blue Iris. When you get to the Alerts tab in Camera Properties, instruction #7 in the original post says to check the “Request from a web service” box. However, the latest version of BI, there is no such Action. Below is what I see. What do you suggest?

image

It looks like you have it right. I forgot I need to update the screenshots, but what you have selected in the image should be right. You’ll be “posting to a web address” for BI Fusion. They recently (well not so recent anymore) added the MQTT server capability, I didn’t even notice how they changed the alerts tab. Lemme know if it doesn’t work for you. A little interpretation may be required if the layout is a lot different, but the steps should outline the same outcome. Thanks for letting me know!

1 Like