Nexawmr dimmer with pilight. Using no script, automation or input_number

Change the id and unit for your device.

Config for shell command, since dimlevel is not working with the pilight switches in home-assistant

shell_command: 
    nexawmr_252: /usr/local/bin/pilight-send -p {{protocol}} -i {{id}} -u {{unit}} --{{power}} {{dimlevel}}

Config for light

light: 
- platform: template
  lights:
    nexawmr_252:
      friendly_name: "LampLamp"
      turn_on:
      - service: shell_command.nexawmr_252
        data_template:
          protocol: kaku_dimmer
          id: 44444444 #change this
          unit: 0 #change this
          power: "on"
          dimlevel: "-d 15"
      turn_off:
      - service: shell_command.nexawmr_252
        data_template:
          protocol: kaku_dimmer
          id: 44444444 #change this
          unit: 0 #change this
          power: "off"
          dimlevel: ""
      set_level:
          - service: shell_command.nexawmr_252
            data_template:
              protocol: kaku_dimmer
              id: 44444444 #change this
              unit: 0 #change this
              power: "on"
              dimlevel: "-d {{ (brightness | float / (255/15)) | int }}"
1 Like

Thanks works great!!

1 Like