Skip to content

Long press via automation #181

@knob2001

Description

@knob2001

Hi.

How could I simulate a long press button in automation? I'm not using the remote itself, but a webhook attached action.
LG allows quick shortcuts on number buttons by long press them. I'm trying to change the HDMI input from 1 to 2, so the easier way I found is do it thru the buttons shortcuts, which I've already configured and tested with the real remote.

I'm talking about adding something like this to every button as in homeisLongPress:

actions:
  - action: webostv.button
    metadata: {}
    data:
      entity_id: media_player.lg_webos_tv_oled42c44la
      button: "2"
      buttonisLongPress: true // SOMETHING LIKE THIS? (as in homeisLongPress:)
mode: single

Thanks!

EDIT:

I've finally done it thru an action command

action: webostv.command
target:
  entity_id: media_player.lg_webos_tv_oled42c44la
data:
  command: tv/switchInput
  payload:
    inputId: HDMI_2

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions