06-11-2024, 07:38 PM
(05-07-2024, 10:17 PM)admin Wrote: what LED driver you are using? you can use multi meter to test D16 output GREEN terminal, whether you change 0--100% whether is 0-10v dc output
Hi! I'm using one of your LED driver bought on AliExpress (12V). I've tested D16 output and it's totally accurate. When home assistant is at 50%, multimeter shows 5v, when at 100%, shows 10v.
Problem is that the light only change brightness when between 0-50%, from 50% to 100% brightnes remains the same (full brightness)..
Please confirm if this is accurate and how to fix:
- name: dimmer-2
unique_id: dimmer-2
schema: template
command_topic: 'dimmer/XXXXXXXXXXXXXXXXXXXXX/set'
state_topic: 'dimmer/XXXXXXXXXXXXXXXXXXXXX/state'
command_on_template: >
{%- if brightness is defined -%}
,{"dimmer2":{"value":{{(brightness / 255 * 100) | int - 1}}}
{%- else -%}
,'{"dimmer2":{"value":99}}'
{%- endif -%}
command_off_template: '{"dimmer2":{"value":0}}'
state_template: >
{%- if value_json.dimmer2.value == 0 -%}
off
{%- else -%}
on
{%- endif -%}
brightness_template: '{{(value_json.dimmer2.value / 99 * 255)| int}}'