LG webOS change picture setting mode with scripts

Hi all,

i would like to share my solution. After digging deeper into GitHub - merdok/homebridge-webos-tv: Homebridge plugin for LG webOS TVs i found a way to set specific picture mode using pure HA services.
It’s a little bit tricky because it opens allert popup and then after click fires luna action :slight_smile:

This is my script:

living_room_lg_tv_picture_mode:
  sequence:
    - service: webostv.command
      data:
        entity_id: media_player.living_room_lg_tv
        command: system.notifications/createAlert
        payload:
          message: >-
            {{ picture_mode }}
          modal: false
          buttons:
            - label: "ok"
              focus: true
              buttonType: "ok"
              onClick: "luna://com.webos.settingsservice/setSystemSettings"
              params:
                category: "picture"
                settings:
                  pictureMode: >-
                    {{ picture_mode }}
          type: "confirm"
          isSysReq: true
    - delay: 0.6
    - service: webostv.button
      data:
        entity_id: media_player.living_room_lg_tv
        button: ENTER

as picture_mode you can pass supported picture mode.
Available picture modes (not all are available on all TVs):
cinema, eco, expert1, expert2, game, normal, photo, sports, technicolor,
vivid, hdrEffect, hdrCinema, hdrCinemaBright, hdrExternal, hdrGame,
hdrStandard, hdrTechnicolor, hdrVivid, dolbyHdrCinema,dolbyHdrCinemaBright,
dolbyHdrDarkAmazon, dolbyHdrGame, dolbyHdrStandard, dolbyHdrVivid, dolbyStandard

You can also play with time of delay.

And also worth to note that this approach can be used to modify other settings eg. energySaving

15 Likes