Tuesday at 08:06 PM5 days I have a massive Blue Iris system. While it is not prefect I figured I would help it out a bit with IoX triggers. Example. I have a camera pointed at a door. Blue Iris fails to see someone at the door for what ever reason. At the door I have a motion sensor to turn the light on at might when someone shows up after porch light hours. So I have the IoX fire off a Blue Iris trigger any time the motion sensor goes off. It works really nice. I have other things like this setup. Like when the mail man opens my mailbox. Smile mail man! (Normal status shown below)Here is the problem. For what ever reason "Server Status" or "Node Server Online" may change state to "Disconnected". This causes the triggers to stop working. Clicking "Re-Connect" on Blue Iris Plugin will fix either disruption. So I figured I would write a few programs.Blue Iris Reconect - [ID 00FE][Parent 0001]If 'Blue Iris' NodeServer Online is Disconnected Then Set 'Blue Iris' Re-Discover Wait 5 minutes Else - No Actions - (To add one, press Action')And this second programBlue Iris watchdog - [ID 0100][Parent 0001]If 'Blue Iris' Server Status is DisconnectedThen Set 'Blue Iris' Re-Discover Wait 5 minutes Else - No Actions - (To add one, press 'Action') These programs never run. Maybe it runs once and never again? I have to go in and manually click "Re-Discover". Do I have to set these to run at startup? Maybe set my wait to 1 minute?
Tuesday at 10:54 PM4 days There conditions besides "disconnected" that will be there when it is disconnected. Like "red". Anyway, use backward logic. Blue Iris Re-Discover - [ID 00F9][Parent 0172][Run At Startup]If 'Blue Iris' NodeServer Online is not Connected Or 'Blue Iris' Server Status is not Green Then Wait 1 minute Repeat Every 1 hour Send Notification to 'apo' content 'Blue Iris Disconnected' Set 'Blue Iris' Re-Discover Else - No Actions - (To add one, press 'Action') This works for me.Problem for whatever reason is if Blue iris goes offline (reboot the computer, power outage, or some hiccup), either Blue Iris needs to restart or you need to rediscover. This is a bug in the node server that they can't seem to correct.
Wednesday at 02:42 PM4 days Author @apostolakisl Thanks for the the reply. Seems you have made this routine bullet proof and repetitive. I am trying to better understand the logic.Run on start up, why? Shouldn't the if 'Blue Iris' NodeServer Online is not Connected Or 'Blue Iris' Server Status is not Green be enough? I thought of run on startup too, but didn't know why. Then if the logic is true, it runs every hour; sending a notification and Re-Discover for ever?I changed mine to combine 2 programs in to 1 using reverse logic as suggested, changed the duration and position of the wait and added the run on start up. I didn't add the repeat as I was unsure what it was repeating. Thanks for you helpBlue Iris watchdog - [ID 0100][Parent 0001][Run At Startup]If 'Blue Iris' NodeServer Online is not Connected And 'Blue Iris' Server Status is not GreenThen Wait 1 minute Set 'Blue Iris' Re-Discover Else - No Actions - (To add one, press 'Action')
Wednesday at 11:38 PM3 days Solution 8 hours ago, CPrince said:@apostolakisl Thanks for the the reply. Seems you have made this routine bullet proof and repetitive. I am trying to better understand the logic.Run on start up, why? Shouldn't the if 'Blue Iris' NodeServer Online is not Connected Or 'Blue Iris' Server Status is not Green be enough? I thought of run on startup too, but didn't know why.Then if the logic is true, it runs every hour; sending a notification and Re-Discover for ever?I changed mine to combine 2 programs in to 1 using reverse logic as suggested, changed the duration and position of the wait and added the run on start up. I didn't add the repeat as I was unsure what it was repeating. Thanks for you helpBlue Iris watchdog - [ID 0100][Parent 0001][Run At Startup]If'Blue Iris' NodeServer Online is not ConnectedAnd 'Blue Iris' Server Status is not GreenThenWait 1 minuteSet 'Blue Iris' Re-DiscoverElse- No Actions - (To add one, press 'Action')It only repeats every hour if it fails to be connected. So if something is wrong with Blue Iris that keeps being wrong, it will keep trying to reconnect. I also get an email every hour pestering me to go find out what is up with Blue Iris.The program will only trigger on a change of status of BI. This is why you need the run at startup (and also why you need the repeat). You need to get the repeat every hour thing going if at boot of ISY BI is offline. Edited Wednesday at 11:39 PM3 days by apostolakisl
Thursday at 04:28 PM3 days Author 16 hours ago, apostolakisl said:The program will only trigger on a change of status of BI. This is why you need the run at startupGlad I asked. Now I know why some of my programs don't work till the next day after a reboot. Keep forgetting about change of state. I will add in the repeat.
Thursday at 04:46 PM3 days Regarding Triggers, I took a different approach.I use BI Alerts to set a variable thru Rest on the EISY which triggers an Outdoor Lights Program. The program turns on the outdoor lights then Waits 5 minute then turns them off. Improved lighting helps BI recordings as I don't use IR, just ambient light. For example:user:password@192.168.0.106:8080/rest/vars/set/2/38/1I been using this combo for about 15 yrs and it works flawlessly, especially since BI's recent incorporation of AI.Of course, this was all done well before PG3 and the BI node plugin, so this is new to me.BTW if you use the UNIFI Protect ecosystem, the Unifi Protect doorbell and cams can trigger the eisy/insteon lighting nicely using their webhooks. Edited Thursday at 04:51 PM3 days by mmb
Thursday at 06:14 PM3 days Author @mmb I hate learning new stuff! It seems you are using BI to trigger EISY. We are using EISY to trigger BI. This is interesting. I have done some research and see that REST is an API. I think i figured this out. I was able to set a variable in EISY through a browser with this knowledge. I like this.So now I assume:192.168.0.106 is the EISY. (I thought it was BI)/rest calls the API/vars is the variable location on EISY/set is to set a variable/2 is state variable /38 is your variable/1 is the data
Thursday at 08:01 PM3 days You assume correct, in BI select Settings / Alerts /On Alerts / + (lower left) then create new alert.Then create the EISY Program. Something like this: Motion Cam LtsIf $Motion_Cam_Detect is 1 And From 9:05:00PM To 5:00:00AM (next day)Then Set 'Outside Front and Side Lts' On $Motion_Cnt += 1 Wait 10 minutes Set 'Outside Front and Side Lts' Off $Motion_Cam_Detect = 0Else $Motion_Cam_Detect = 0
Thursday at 11:08 PM2 days 4 hours ago, CPrince said:@mmb I hate learning new stuff! It seems you are using BI to trigger EISY. We are using EISY to trigger BI. This is interesting. I have done some research and see that REST is an API. I think i figured this out. I was able to set a variable in EISY through a browser with this knowledge. I like this.So now I assume:192.168.0.106 is the EISY. (I thought it was BI)/rest calls the API/vars is the variable location on EISY/set is to set a variable/2 is state variable/38 is your variable/1 is the dataYou can have REST commands do just about anything. Change the status of a node, query a node, run programs (then/else/whatever) . . .
Friday at 12:18 AM2 days Author I figured there is a lot more to this. So where can I go to learn more about this?
Friday at 02:47 AM2 days 2 hours ago, CPrince said:I figured there is a lot more to this. So where can I go to learn more about this?The wiki gives you all the REST commands that are possible. From there it is just having something that can send a REST command. Anything that can ping a URL. For the most part, you would want to keep it to things inside your LAN, otherwise you would have to open ports which is generally not a good idea. Apple phones (and I think Android) have the ability to give a voice command to Siri and send a URL. For example, I set my daughters phone up so she can use Siri to voice a command and that will trigger the REST command to open the garage door. Otherwise you would have to open an app and whatnot vs just a voice command to an otherwise idle phone. BI of course works great with motion activations. Raspberry pi or Arduino. But I will tell you that with node servers the need to use REST is much less. REST is also a one way street whereas node servers mostly keep things in sync. Using BI with REST to notify you of motion for example is a great use of REST since it is just a momentary event. But most stuff isn't like that.
Create an account or sign in to comment