Skip to content

Instantly share code, notes, and snippets.

@tmarquespt
Last active February 2, 2021 23:26
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save tmarquespt/e18bf9f5676312c6199a1a71082057db to your computer and use it in GitHub Desktop.
Save tmarquespt/e18bf9f5676312c6199a1a71082057db to your computer and use it in GitHub Desktop.
hyperion-on-off-with-source-selection-v3
[{"id":"1a80ca9e.94dd45","type":"tab","label":"hyperion","disabled":false,"info":""},{"id":"48849958.8ab3a8","type":"server-state-changed","z":"1a80ca9e.94dd45","name":"Shield Sala Status","server":"2998c139.aa476e","version":1,"exposeToHomeAssistant":false,"haConfig":[{"property":"name","value":""},{"property":"icon","value":""}],"entityidfilter":"media_player.living_room_nvidia_shield","entityidfiltertype":"exact","outputinitially":false,"state_type":"str","haltifstate":"","halt_if_type":"str","halt_if_compare":"is","outputs":1,"output_only_on_state_change":true,"for":0,"forType":"num","forUnits":"minutes","ignorePrevStateNull":false,"ignorePrevStateUnknown":false,"ignorePrevStateUnavailable":false,"ignoreCurrentStateUnknown":false,"ignoreCurrentStateUnavailable":false,"x":150,"y":160,"wires":[["34cb201b.bfdfa"]]},{"id":"9f0a9c7b.2c255","type":"api-call-service","z":"1a80ca9e.94dd45","name":"wld-pwr-off","server":"2998c139.aa476e","version":1,"debugenabled":false,"service_domain":"switch","service":"turn_off","entityId":"switch.smart_plug_mss310_main_channel_2","data":"","dataType":"jsonata","mergecontext":"","output_location":"","output_location_type":"none","mustacheAltTags":false,"x":910,"y":120,"wires":[["23916314.5bb69c"]]},{"id":"a028c2a3.98cbd","type":"api-call-service","z":"1a80ca9e.94dd45","name":"wld-pwr-on","server":"2998c139.aa476e","version":1,"debugenabled":false,"service_domain":"switch","service":"turn_on","entityId":"switch.smart_plug_mss310_main_channel_2","data":"","dataType":"jsonata","mergecontext":"","output_location":"","output_location_type":"none","mustacheAltTags":false,"x":570,"y":180,"wires":[["7ee75f85.cda98"]]},{"id":"cff7cba0.808048","type":"api-call-service","z":"1a80ca9e.94dd45","name":"hyperion-on","server":"2998c139.aa476e","version":1,"debugenabled":false,"service_domain":"switch","service":"turn_on","entityId":"light.wled_tv","data":"","dataType":"jsonata","mergecontext":"","output_location":"","output_location_type":"none","mustacheAltTags":false,"x":910,"y":180,"wires":[["27fc772c.b1d998","77eb1547.08ee44"]]},{"id":"7ee75f85.cda98","type":"delay","z":"1a80ca9e.94dd45","name":"","pauseType":"delay","timeout":"3","timeoutUnits":"seconds","rate":"1","nbRateUnits":"1","rateUnits":"second","randomFirst":"1","randomLast":"5","randomUnits":"seconds","drop":false,"x":740,"y":180,"wires":[["cff7cba0.808048"]]},{"id":"34cb201b.bfdfa","type":"switch","z":"1a80ca9e.94dd45","name":"status","property":"payload","propertyType":"msg","rules":[{"t":"eq","v":"paused","vt":"str"},{"t":"eq","v":"idle","vt":"str"},{"t":"eq","v":"off","vt":"str"},{"t":"eq","v":"running","vt":"str"},{"t":"eq","v":"playing","vt":"str"}],"checkall":"true","repair":false,"outputs":5,"x":350,"y":140,"wires":[["65ea9253.3b7f3c"],["65ea9253.3b7f3c"],["9f0a9c7b.2c255"],["9f0a9c7b.2c255"],["d015ba3.16baf48","173a3680.8d2c5a"]]},{"id":"65ea9253.3b7f3c","type":"stoptimer","z":"1a80ca9e.94dd45","duration":"30","units":"Second","payloadtype":"num","payloadval":"0","name":"","x":590,"y":100,"wires":[["9f0a9c7b.2c255"],[]]},{"id":"d015ba3.16baf48","type":"change","z":"1a80ca9e.94dd45","name":"Stop","rules":[{"t":"set","p":"payload","pt":"msg","to":"stop","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":550,"y":140,"wires":[["65ea9253.3b7f3c"]]},{"id":"27fc772c.b1d998","type":"switch","z":"1a80ca9e.94dd45","name":"Source","property":"data.old_state.attributes.app_name","propertyType":"msg","rules":[{"t":"eq","v":"YouTube","vt":"str"},{"t":"eq","v":"Plex","vt":"str"},{"t":"eq","v":"Netflix","vt":"str"},{"t":"eq","v":"Disney+","vt":"str"}],"checkall":"true","repair":false,"outputs":4,"x":360,"y":280,"wires":[["23916314.5bb69c"],["23916314.5bb69c"],["26b1b683.7fe9da"],["26b1b683.7fe9da"]]},{"id":"26b1b683.7fe9da","type":"api-call-service","z":"1a80ca9e.94dd45","name":"hyperion VL4","server":"2998c139.aa476e","version":1,"debugenabled":false,"service_domain":"light","service":"turn_on","entityId":"light.wled_tv","data":"{\"effect\":\"V4L\"}","dataType":"json","mergecontext":"","output_location":"","output_location_type":"none","mustacheAltTags":false,"x":570,"y":300,"wires":[[]]},{"id":"23916314.5bb69c","type":"api-call-service","z":"1a80ca9e.94dd45","name":"hyperion APP","server":"2998c139.aa476e","version":1,"debugenabled":false,"service_domain":"light","service":"turn_on","entityId":"light.wled_tv","data":"{\"effect\":\"GRABBER\"}","dataType":"json","mergecontext":"","output_location":"","output_location_type":"none","mustacheAltTags":false,"x":580,"y":240,"wires":[[]]},{"id":"173a3680.8d2c5a","type":"time-range-switch","z":"1a80ca9e.94dd45","name":"","lat":"","lon":"","startTime":"12:00","endTime":"08:00","startOffset":0,"endOffset":0,"x":370,"y":207,"wires":[["a028c2a3.98cbd"],[]]},{"id":"77eb1547.08ee44","type":"debug","z":"1a80ca9e.94dd45","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","statusVal":"","statusType":"auto","x":780,"y":340,"wires":[]},{"id":"2998c139.aa476e","type":"server","name":"Home Assistant","legacy":false,"addon":true,"rejectUnauthorizedCerts":true,"ha_boolean":"y|yes|true|on|home|open","connectionDelay":true}]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment