Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Levoit Classic 300S Humidifier #124

Open
Scope666 opened this issue Jan 31, 2024 · 1 comment
Open

Levoit Classic 300S Humidifier #124

Scope666 opened this issue Jan 31, 2024 · 1 comment

Comments

@Scope666
Copy link

Scope666 commented Jan 31, 2024

Hi,

I mostly have this card working, I just can't figure out how to control the night light.

It's a separate entity_id in the integration: light.classic300s_night_light

type: custom:mini-humidifier
entity: humidifier.classic300s
indicators:
  humidity:
    icon: mdi:water
    unit: '%'
    source:
      entity: sensor.classic300s_current_humidity
buttons:
  led:
    icon: mdi:lightbulb-on-outline
    order: 2
    type: dropdown
    entity_id: light.classic300s_night_light
    state:
      attribute: brightness
    source:
      '0': '80'
      '1': '50'
      '2': 'Off'
    active: state => (state !== 2 && state !== '2')
    change_action: |
      (selected, state, entity) => {
        const options = { entity_id: entity.entity_id, brightness: selected };
        return this.call_service('light', 'turn_on', options);
      }

I'm not really a coder, so I know what I have for the LED / Light is wrong.

Any advice for modifying to call light.turn_on and adjust brightness ?

image
@Scope666 Scope666 changed the title Levoit Class 300s Humidifier Levoit Classic 300s Humidifier Jan 31, 2024
@Scope666 Scope666 changed the title Levoit Classic 300s Humidifier Levoit Classic 300S Humidifier Jan 31, 2024
@regevbr
Copy link
Collaborator

regevbr commented Jan 31, 2024

just practice the service call in the dev dashboard and see what works for you

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants