Can't send alert message to Homeseer on same PC

General discussion about Blue Iris
Post Reply
Dewcal
Posts: 21
Joined: Sat Oct 19, 2019 11:25 am

Can't send alert message to Homeseer on same PC

Post by Dewcal »

Am using BI - latest v5 updated a few days ago - and have 14 cameras set up and functioning well on a dedicated i7 PC - about 9% CPU with substreams etc.
One of them is an EZVIZ DB1 which triggers an alert when people get into the relevant area. Some while ago I managed to configure an IFTTT / Webhooks to switch on a Tuya light in the porch. This invariably works - either instantly or with 40 second delay....

Last week I invested in Homeseer HS4 in the hope to be able to do things locally and all TUYA devices have been recognised - even though I seem to have no way of knowing if they are being controlled locally or not. I have created a manually triggered event to turn on the light required.

I have installed HS4 on the same PC as BI but cannot get my head around the syntax required to send a http command to HS4 to activate said light.
When pressing the BI alert test button - it reports "Web: error: No Stream: 12002". The other two alerts function correctly

I am trying the following - http://192.168.1.5/JSON?user=ME&pass=HS ... 5&value=on

I have also failed to get "control by event" to work.

Is there anything I should / should not be doing here? Am I correct in assuming I need an event rather than just have straight control of the device? I do NOT have the HS3 BI plugin installed - do I actually need it?

Any help would be appreciated as I think I am going around here in circles.
Dave
BI v 5.3.x.0 x64 as a service on Windows 10 Pro 1909 - i7-8700 @ 3.20GHz with 32Gb RAM
Mix of 8 IP POE cameras
User avatar
TimG
Posts: 2098
Joined: Tue Jun 18, 2019 10:45 am
Location: Nottinghamshire, UK.

Re: Can't send alert message to Homeseer on same PC

Post by TimG »

Hi, I presently have BI5 on one server pc sending messages to HS4 Pro on another server pc on the same LAN to turn on outside lights in the dark if motion is detected. Basically you don't need the plug in, but it does make it simpler when creating an event, as you can use menu's. Be aware that the plug in isn't being updated, but I am using it.

I can see you have the command http://192.168.1.5/JSON?user=ME&pass=HS ... 5&value=on

So:

1. Using the plug in, my front drive camera sends this to HS4 [url]user:pass@192.168.2.2:85/JSON?request=pluginfunction&function=Alert&plugin=Blue-Iris&P1=&CAM&P2=&TYPE[/url] which can then be used in events. Note non standard HS4 port in use, you don't need that. The event to trigger the lights includes a nightime virtual device "And If" with the trigger to prevent lights working unless it is dark.

2. Previously with HS3 and no plug in, this used to work http://192.168.2.2/JSON?request=control ... &value=100 but if I remember correctly HS4 changed things so that you needed the user/pass credentials. If you decide not to use the plugin, then maybe user:pass@192.168.2.2/JSON?request=controldevicebyvalue&ref=139&value=100 would work :? This would also need an event to control function in day/night. Change the ref to a virtual device if you do that.

3. HS4 - Have you enabled "Setup/Network/Enable Control with JSON (Required for Alexa/Google Home/IFTTT/Etc.)" ?

4. BI5 - Did you enable the On alert action ?

Baby steps required. I got this working with commands in a browser before I got BI5 to send the commands, but maybe my above scribblings above will help you sort it faster 8-) Hmm, browser test required.

This is working today from Chrome browser on a different pc on the LAN to turn lights on http://192.168.2.2:85/JSON?request=cont ... &value=100 Again, I had to add my non standard HS4 port (you should be able to delete ":85") but it didn't need user:pass. It may do when you add it to BI5 !

Let me know if that helps. It seems to wander all over the place, but should make sense at the end :lol:
Forum Moderator.
Problem ? Ask and we will try to assist, but please check the Help file.
Dewcal
Posts: 21
Joined: Sat Oct 19, 2019 11:25 am

Re: Can't send alert message to Homeseer on same PC

Post by Dewcal »

Tim,

Thanks for replying and I cna advise that I do have alerts and JSON enabled in the respective software.

Part of the problem I always have with new (to me) software is gettingmy old head around the terminology used!

I have just managed to get the alert to trigger the light with the following command

"http://192.168.1.5/JSON?request=control ... 5&label=On" ----I had been equating being "on" with a value....terminology!

I did NOT need to enter user & password (although it did work when I did). I was having "web failures" when I was trying https instead of http.

I do not have the plugin nor do I need an event to get the light on.

Hopefully this will continue to work - thanks again for help.
BI v 5.3.x.0 x64 as a service on Windows 10 Pro 1909 - i7-8700 @ 3.20GHz with 32Gb RAM
Mix of 8 IP POE cameras
User avatar
TimG
Posts: 2098
Joined: Tue Jun 18, 2019 10:45 am
Location: Nottinghamshire, UK.

Re: Can't send alert message to Homeseer on same PC

Post by TimG »

nor do I need an event to get the light on.
You only need an event if you want to prevent a light coming on in the daytime, or if you want to force the light off after a few minutes.

My front drive camera turns on three zigbee lights for five minutes, but only if it is dark outside.

IF
Camera Drive has a motion alert in zone ABCDEFG {This is how the plug in allows you to trigger an event}

AND IF
Virtual Devices System Darkness interlock Control has a value equal to On {"Darkness Interlock control" is a virtual device controlled by other events that is ON with sunset +15 minutes and goes OFF with sunrise minus 15 minutes. Prevents twilight weird switching which happened with the usual sunset/sunrise conditions}

THEN
Remove Delayed Device Actions for: Ground Garden Outside Garage Light RHS
Ground Garden Outside Garage Light LHS
Ground Garden Outside Light Front Door {This deletes any running timers and allows the new trigger to run for its specified time without being switched off prematurely. It also allows retriggering during the time the lights are ON, so they won't go OFF if there is continued motion}

Set Devices:
Ground Garden Outside Garage Light RHS Outside Garage Light RHS to On
Ground Garden Outside Garage Light LHS Outside Garage Light LHS to On
Ground Garden Outside Light Front Door Outside Light Front Door to On {Three lights ON}

Set Devices:
Ground Garden Outside Garage Light RHS Outside Garage Light RHS to Off
Ground Garden Outside Garage Light LHS Outside Garage Light LHS to Off
Ground Garden Outside Light Front Door Outside Light Front Door to Off
after a delay of 5 Minutes, 0 Seconds {And three lights OFF after 5 minutes unless retriggered}
Last edited by TimG on Thu Dec 16, 2021 12:36 pm, edited 1 time in total.
Forum Moderator.
Problem ? Ask and we will try to assist, but please check the Help file.
Dewcal
Posts: 21
Joined: Sat Oct 19, 2019 11:25 am

Re: Can't send alert message to Homeseer on same PC

Post by Dewcal »

Thanks Tim,

You mention the scenario I am trying to create - light only comes on in dark when triggered and goes off in x minutes. Will try to get my head around the logic and syntax!
Thanks again
BI v 5.3.x.0 x64 as a service on Windows 10 Pro 1909 - i7-8700 @ 3.20GHz with 32Gb RAM
Mix of 8 IP POE cameras
User avatar
TimG
Posts: 2098
Joined: Tue Jun 18, 2019 10:45 am
Location: Nottinghamshire, UK.

Re: Can't send alert message to Homeseer on same PC

Post by TimG »

My previous post is a text grab from HS4, so you should be able to follow it in HS4. I think it was Prade on the Homeseer forum who showed how to delete the previous timers; without that the lights would sometimes go OFF even if you were moving in front of the camera. It works very well 8-)

Following Black Friday, I can now say "Alexa, turn the outside lights ON/OFF.". That increases WAF which allows me to buy even more toys :lol:
Forum Moderator.
Problem ? Ask and we will try to assist, but please check the Help file.
Post Reply