ControllerX. Bring full functionality to light and media player controllers

Hi @mama_mia ,

I just released fix into ControllerX v4.26.0. I have added a patch as a workaround, you can read more about it in:

EDIT:
I am having problems to use the patch with the AppDaemon addon, I will need to keep looking for a better solution.

Regards,
Xavi M.

Hi @mama_mia again,

I just released ControllerX v4.26.1 with a fix for AppDaemon addon.

Let me know if it works for you.

Regards,
Xavi M.

1 Like

Hi,

Just tested it, and it’s working.
Awesome!!

Thank’s!!

1 Like

Hi @xaviml New Ikea Remote !

ZHA Events

  endpoint_id: 1
  cluster_id: 6
  command: toggle
------------------------------------------
  command: move_with_on_off
  args:
    - 0
    - 255
  params:
    move_mode: 0
    rate: 255
------------------------------------------
  command: move
  args:
    - 0
    - 255
    - 0
    - 0
------------------------------------------
  command: move_with_on_off
  args:
    - 1
    - 255
  params:
    move_mode: 1
    rate: 255
------------------------------------------
  command: move
  args:
    - 1
    - 255
    - 0
    - 0
------------------------------------------
  command: step
  args:
    - 1
    - 1
    - 0
    - 0
    - 0
  params:
    step_mode: 1
    step_size: 1
    transition_time: 0
    options_mask: 0
    options_override: 0
------------------------------------------
  command: step
  args:
    - 0
    - 1
    - 0
    - 0
    - 0
  params:
    step_mode: 0
    step_size: 1
    transition_time: 0
    options_mask: 0
    options_override: 0
------------------------------------------
  command: shortcut_v1_events
  args:
    - 1
    - 1
  params:
    shortcut_button: 1
    shortcut_event: 1
------------------------------------------
  command: shortcut_v1_events
  args:
    - 2
    - 1
  params:
    shortcut_button: 2
    shortcut_event: 1


1 Like

Thank you @Canaletto , I will look into it when I have time.

New AppDaemon version got release today with the fix for the template rendering. I will remove my patch when I have some more time again.

In case latest version is not working, v4.25.0 can be used since it does not contain the patch, and should work with latest AppDaemon version.

Regards,
Xavi M.

Thank you. Always something so simple with other eyes on it!

1 Like

Am I the only one using this integration with the Tuya Smart knob?? LOL

Blockquote
Has anyone here successfully setup ControllerX with the Tuya Smart Knob?

https://xaviml.github.io/controllerx/controllers/TuYaERS10TZBVKAA/

It seems to connect and I can see the state changes however I get the following error in Zigbee2MQTT:

entity

However if I use the same entity with the Ikea E1744 Smart Knob in ControllerX, it works just fine. I’m pulling my hair out here! Any help you be GREATLY appreciated! Below is my apps.yaml config:

office_dimmer:
  module: controllerx
  class: TuYaERS10TZBVKAAZ2MLightController
  integration:
    name: z2m
    listen_to: mqtt
  controller: SmartKnob
  light: light.switch_office

and here is what’s in the Z2M config for the Tuya:

'0x003c84fffeb13c00':
  friendly_name: SmartKnob

Thank you. it is working now.

For informations… but I prefer ZHA :wink:

Hi Xavi,
Congratulations for great job and building so flexible automation system for appdaemon!

I’m quite new here, but already managed to integrate few different IKEA Tradfri controllers with full success. Thanks to your well designed system.
I decided to post here, because I have stuck with my shelly 2.5 lab-solution (input-0 only, detached switch) controlling half of my chandelier (group of two z2m bulbs).
Spending few hours, I cannot understand the reason, but I have no appdaemon logs for that, nor any state change of the bulbs.

I tried this config:

pokoj_zyrandol:
    module: controllerx
    class: Shelly25LightController
    integration: shelly
    controller: shellyswitch25-C45BBE6B4D2E
    light: light.pokoj_zyrandol
    actions:
        - single_push_1
        - long_push_1
        - btn_up_1
        - double_push_1
    merge_mapping:
        long_push_1: hold_brightness_toggle

For testing purposes I also simplified above config by removing “actions” and “merge_mapping” blocks.
then this one:

pokoj_zyrandol:
    module: controllerx
    class: LightController
    controller:
        - shellies/shellyswitch25-C45BBE6B4D2E/input_event/0
    light: light.pokoj_zyrandol
    integration:
        name: mqtt
        key: event
    mapping:
        "S": "on"
        "L": "off"

No appdaemon application logs, no action. What can be the root of the issue?

my mqtt brocker reports correctly:

maj 25 18:56:19 shellies/shellyswitch25-C45BBE6B4D2E/input/0 1
maj 25 18:56:20 shellies/shellyswitch25-C45BBE6B4D2E/longpush/0 1
maj 25 18:56:20 shellies/shellyswitch25-C45BBE6B4D2E/input_event/0 {“event”:“L”,“event_cnt”:49}
maj 25 18:56:20 shellies/shellyswitch25-C45BBE6B4D2E/input/0 0
maj 25 18:56:21 shellies/shellyswitch25-C45BBE6B4D2E/input/0 1
maj 25 18:56:21 shellies/shellyswitch25-C45BBE6B4D2E/longpush/0 0
maj 25 18:56:21 shellies/shellyswitch25-C45BBE6B4D2E/input_event/0 {“event”:“S”,“event_cnt”:50}
maj 25 18:56:21 shellies/shellyswitch25-C45BBE6B4D2E/input/0 0

and HA events look like:

event_type: shelly.click
data:
  device_id: d80542b9527d96bcb6688b882b7b3c1a
  device: shellyswitch25-C45BBE6B4D2E
  channel: 1
  click_type: single
  generation: 1
origin: LOCAL
time_fired: "2023-05-25T16:27:56.771676+00:00"
context:
  id: 01H19VT1F39N4H4NZAJ0TKFQ0C
  parent_id: null
  user_id: null

For sure I overlooked something. Could you advice what I could mess up, please?
I wrote few short lines in python using mqtt API and “the appliance” works correctly. I intend to integrate the automation with your great unified solution.

Please help me here. Big thanks in advance!
Marek

I am not sure what I am doing wrong, hope someone can help.

Using a Philips Hue dimmer (v2, the one with the HUE button), the brightness up/down doesn´t seem to be working by default. I have to explicitly define brightness up and down, it doesn´t work without that.

hue_dimmer_ouderslaapkamer1:
  module: controllerx
  class: Philips929002398602Z2MLightController
  controller: sensor.hue_dimmer_slaapkamer1_action
  integration: z2m
  light: light.bed_1
  update_supported_features: true
  merge_mapping:
    on_press_release:
      service: light.toggle
      data:
        entity_id: light.bed_1
    on_press_release$2:
      service: light.toggle
      data:
        entity_id: light.ouderslaapkamer_plafond
# I can only change brightness (up) when I define it like below. 
# Without this code, the brightness does not change when I press the 'brightness up' button.
    up_press_release:
      service: light.turn_on
      data:
        entity_id: light.bed_1
        brightness_step_pct: 10

Why is is the default behavior for brightness up not working in this example? Is this a bug or am I doing something wrong?

Hello Xavi

Firstly, thank you very much for your amazing work. It’s just so easy to understand how to add devices, also for a newbie like me.

Now I’m looking for a solution to add the Innr RC 250 and to use it with ZHA. Could you add the device? If yes, what information do you need from me?

I was able to configure the main button with the E1743 integration, I wondering know if it’s possible to find an existing integration to use the device?

Greetings

Lukas

Hey, new ControllerX user here.

I was able to get everything setup and running using the ICTCG1 controller and Z2M. The only stumbling block I am having is that the bulb I am controlling must be on before I can dim it. What I would like to do is to use the quick rotations to issue a light.turn_on/off command. Is this something that is supported when using Z2M?

Hi all,

First of all thanks a lot @xaviml, it’s been 3 years that I am using and enjoying your tool!
I am trying to add a condition to select the light to be controlled, and the following code doesn’t seem to work:

LightLivingRoom:
  module: controllerx
  class: E1810Controller
  controller: sensor.remote_living_room_action
  integration: z2m
  light: |
      [[[
        if (states['input_boolean.check'].state == 'off')
         return "light.lights_living_room_A";
        return "light.lights_living_room_B";
      ]]]
  excluded_actions:
    - toggle
    - toggle_hold

Any idea how to make it work?

Hi @Alex95 ,

You can use “constrain_input_boolean” from AppDaemon. You find some examples of it in the Examples page:

https://controllerx.netlify.app/controllerx/examples/#advanced

Regards,

That worked, thanks!!

Hi, I have been using the integration and its perfect.
I am using the 4 button IKEA controller (it doesn’t have the middle on/off button).

I am trying to map a 2 click action and 3 click action to toggle the individual lights.
The issue is that i don’t know how to define which button should be listen to for the double click (as there is no middle button).

This is what i have:

lounge_lights_4button:
  module: controllerx
  class: E2002Z2MLightController
  integration: z2m
  controller: sensor.lounge_remote_4button_action
  light: Lounge Lights
  merge_mapping:
    toggle$2:
      service: light.toggle
      data:
        entity_id: light.lounge_lamp_1
    toggle$3:
      service: light.toggle
      data:
        entity_id: light.lounge_lamp_2

Double and Triple clicks do nothing. All other features work ok (on/off, temperature, brightness)
How can i define which button should be listened to?

Thank you!

@xaviml
With addon-appdaemon V 0.15.2 the addon has been moved into a different folder outside the HA config folder. Hence the ControllerX config file is not accessable anymore under /config/appdaemon/apps/apps.yaml.

Do you have any advise how to deal with it and can tell us the implication for the ControllerX Project? Not sure if her in the comminity or on github discussion forum is the right place to talk about it.

Good source for those having issues because they missed to consider the braking change of path to secrets.yaml in appdaemon.yaml.

Thanks in advance!

I reported a bug for this one;
https://github.com/xaviml/controllerx/issues/875

I can not fix this issue