For whoever is looking for a full-screen video feed for “X” seconds after a certain action (doorbell or motion detection) that displays on the Fully Kiosk Browser (no matter the current state).
Here’s my little tutorial.
First make sure that external access is activated in the Kios Browser in order to receive commands.
[ 1 ]
Now you have to create a flow that publishes true or false in a certain topic.
Of course you can change this according to your own actions to trigger this event.
In here also is the trigger to hide the video feed after 60 seconds.
[ 2 ]
Then you have to create a new group in your tab.
Mine is called “Er is aangebeld” (translates to doorbell rings).
You can create this group on all of your tabs if you want this to work on all of your tabs.
Now it’s important this group is the first group in your tab, and the size is set up to be full screen on your dashboard (for example 24 blocks wide).
[ 3 ]
Once the group is created you can put your video feed in with a template node from the dashboard menu.
For example:
[{"id":"b9729ece.63eb6","type":"ui_template","z":"bbff3fe8.ed376","group":"93b4660d.f54d08","name":"Deurbel video","order":2,"width":20,"height":16,"format":"<iframe type=\"text/html\" frameborder=\"0\" align = \"center\" width=\"1100\" height=\"700\" src=\"//video.nest.com/embedded/live/XXXXXXXXXXX?autoplay=1\" allowfullscreen></iframe>","storeOutMessages":true,"fwdInMessages":true,"resendOnRefresh":true,"templateScope":"local","x":1820,"y":300,"wires":[[]]},{"id":"93b4660d.f54d08","type":"ui_group","name":"Er is aangebeld","tab":"8146c75c.872268","order":1,"disp":false,"width":"24","collapse":false},{"id":"8146c75c.872268","type":"ui_tab","name":"Huis","icon":"dashboard","order":1,"disabled":false,"hidden":false}]
[ 4 ]
In node red we first need to always hide this group at load.
[{"id":"25c2555a.8316aa","type":"inject","z":"bbff3fe8.ed376","name":"Hide Nest Hello at Load","props":[{"p":"payload"}],"repeat":"","crontab":"","once":true,"onceDelay":0.1,"topic":"","payload":"{\"group\":{\"hide\":[\"Huis_Er_is_aangebeld\"]}}","payloadType":"json","x":1410,"y":80,"wires":[["96251858.4edc08"]]},{"id":"96251858.4edc08","type":"ui_ui_control","z":"bbff3fe8.ed376","name":"","x":1660,"y":80,"wires":[[]]}]
- Change “Huis” to your own tab name, and change “Er_is_aangebeld” to your own group name.
[ 5 ]
Now you have to create an action for both Node-RED and the Kiosk browser.
A- To show the Node-RED group triggered by the action.
B- To stop the screensaver (if running)
C- To turn on the screen
D- To hide the group again after “X” seconds (time is set in the homey flow).
[{"id":"9ef4589d.288bb8","type":"ui_ui_control","z":"bbff3fe8.ed376","name":"","x":1900,"y":140,"wires":[[]]},{"id":"723c342b.42680c","type":"mqtt in","z":"bbff3fe8.ed376","name":"","topic":"homie/homey-topic/nest/doorbell","qos":"2","datatype":"auto","broker":"d094d3b7.a558a8","nl":false,"rap":true,"rh":0,"x":1410,"y":140,"wires":[["6a9e888b.416d48","743aaee2.dafeb","a4a6c4b.80b4c38"]]},{"id":"6a9e888b.416d48","type":"function","z":"bbff3fe8.ed376","name":"Show Nest Hello","func":"if(msg.payload === \"true\"){\n msg.payload = {\"group\":{\"show\":[\"Huis_Er_is_aangebeld\"]}}; \n}else{\n msg.payload = {\"group\":{\"hide\":[\"Huis_Er_is_aangebeld\"]}};\n}\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":1690,"y":140,"wires":[["9ef4589d.288bb8"]]},{"id":"743aaee2.dafeb","type":"http request","z":"bbff3fe8.ed376","name":"","method":"GET","ret":"txt","paytoqs":"ignore","url":"http://192.168.1.XX:2323/?cmd=screenOn&password=PASSWORD","tls":"","persist":false,"proxy":"","authType":"","x":1670,"y":180,"wires":[[]]},{"id":"a4a6c4b.80b4c38","type":"http request","z":"bbff3fe8.ed376","name":"","method":"GET","ret":"txt","paytoqs":"ignore","url":"http://192.168.1.XX:2323/?cmd=stopScreensaver&password=PASSWORD","tls":"","persist":false,"proxy":"","authType":"","x":1630,"y":220,"wires":[[]]},{"id":"d094d3b7.a558a8","type":"mqtt-broker","name":"Homey MQTT","broker":"192.168.1.77","port":"1883","clientid":"","usetls":false,"protocolVersion":"4","keepalive":"60","cleansession":true,"birthTopic":"","birthQos":"0","birthPayload":"","birthMsg":{},"closeTopic":"","closeQos":"0","closePayload":"","closeMsg":{},"willTopic":"","willQos":"0","willPayload":"","willMsg":{},"sessionExpiry":""}]
- In the function node, change “Huis” to your own tab name, and change “Er_is_aangebeld” to your own group name.
- In the http request node, change IP and Password according to the IP and Password of your Fully Kios Browser.
Then you should have something like this:
.
Yes I know my garden is a mess
, it will be redone next month… 