As an addon remote for my enigma2 media player by @cinzas . I get into difficulties pressing physical remote at times especially timeshift key and then fast forwarding through adverts(tiny buttons in the dark). There are loads more command keys.
The list down the left side are just on an entities card and don’t need pressed more than once. There may be a simpler way of making the grid momentary switches if anyone can comment.
configuration.yaml
- platform: command_line
switches:
ok:
command_on: 'curl -k "http://192.168.0.5/web/remotecontrol?command=352"'
friendly_name: OK Press
reboot:
command_on: 'curl -k "http://192.168.0.5/web/powerstate?newstate=2"'
shutdown:
command_on: 'curl -k "http://192.168.0.5/web/powerstate?newstate=1"'
timeshift:
command_on: 'curl -k "http://192.168.0.5/web/remotecontrol?command=119"'
play:
command_on: 'curl -k "http://192.168.0.5/web/remotecontrol?command=207"'
forward:
command_on: 'curl -k "http://192.168.0.5/web/remotecontrol?command=208"'
backward:
command_on: 'curl -k "http://192.168.0.5/web/remotecontrol?command=168"'
stoptimeshift:
command_on: 'curl -k "http://192.168.0.5/web/remotecontrol?command=128"'
up:
command_on: 'curl -k "http://192.168.0.5/web/remotecontrol?command=103"'
down:
command_on: 'curl -k "http://192.168.0.5/web/remotecontrol?command=108"'
left:
command_on: 'curl -k "http://192.168.0.5/web/remotecontrol?command=105"'
right:
command_on: 'curl -k "http://192.168.0.5/web/remotecontrol?command=106"'
exit:
command_on: 'curl -k "http://192.168.0.5/web/remotecontrol?command=1"'
info:
command_on: 'curl -k "http://192.168.0.5/web/remotecontrol?command=358"'
record:
command_on: 'curl -k "http://192.168.0.5/web/remotecontrol?command=167"'
menu:
command_on: 'curl -k "http://192.168.0.5/web/remotecontrol?command=139"'
epg:
command_on: 'curl -k "http://192.168.0.5/web/remotecontrol?command=365"'
I use grid card to put switches on but it makes them latching switches so need to turn them off when next press any tile on the grid so you can press up and up rather than pressing tile to move up then press it again to unlatch the switch before pressing it again to move up.
Automations.yaml
- id: '1628539728475'
alias: enigma2 latching switches to off
description: when command line switches turned on then get turned off fast to allow
remote to work
trigger:
- platform: state
entity_id: switch.down
to: 'on'
- platform: state
entity_id: switch.up
to: 'on'
- platform: state
entity_id: switch.right
to: 'on'
- platform: state
entity_id: switch.left
to: 'on'
- platform: state
entity_id: switch.info
to: 'on'
- platform: state
entity_id: switch.exit
to: 'on'
- platform: state
entity_id: switch.ok
to: 'on'
- platform: state
entity_id: switch.menu
to: 'on'
- platform: state
entity_id: switch.record
to: 'on'
condition: []
action:
- service: switch.turn_off
target:
entity_id:
- switch.up
- switch.down
- switch.left
- switch.right
- switch.info
- switch.exit
- switch.ok
- switch.menu
- switch.record
mode: single