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

Feature Request: Option to Disable LED Indicators for Mute and Microphone at Night #267

Open
highTowerSU opened this issue Jan 3, 2025 · 1 comment

Comments

@highTowerSU
Copy link

Currently, the LED indicators for mute and microphone status remain illuminated during the night. While this is useful during the day, it can be disruptive in dark environments, such as bedrooms. An option to automatically disable or dim these LEDs during specified hours (e.g., night mode) would significantly improve the user experience.

Proposed Solution:

Introduce a "Night Mode" or "LED Control" feature in the settings that allows users to:

  1. Schedule a time range when the LEDs should be turned off or dimmed.

  2. Manually toggle the LED indicators for mute and microphone.

  3. Optionally adjust the brightness of the LEDs for less intrusive lighting.

Benefits:

Improved user comfort, especially in dark environments.

Enhanced flexibility and customization for users.

Potentially reduced energy consumption.

Use Case:

A user places the device in their bedroom and prefers a completely dark environment while sleeping. With this feature, they could schedule the LEDs to turn off between 10 PM and 7 AM, ensuring an uninterrupted night's sleep.

@jackwilsdon
Copy link

It would be nice to have a separate brightness slider for the light. I'm currently using this script as a workaround:

sequence:
  - variables:
      mute_entity_id: |
        {% for entity_id in device_entities(device) %}
          {% if entity_id.startswith("switch.") and entity_id.endswith("_mute") %}
            {{ entity_id }}
          {% endif %}
        {% endfor %}
      light_entity_id: |
        {% for entity_id in device_entities(device) %}
          {% if entity_id.startswith("light.") %}
            {{ entity_id }}
          {% endif %}
        {% endfor %}
          
    alias: Get entities
  - variables:
      was_muted: "{{ states(mute_entity_id) == \"on\" }}"
      was_lit: "{{ states(light_entity_id) == \"on\" }}"
    alias: Get state
  - alias: Unmute if muted
    if:
      - condition: template
        value_template: "{{ was_muted }}"
    then:
      - action: switch.turn_off
        metadata: {}
        data:
          entity_id: "{{ mute_entity_id }}"
      - delay:
          hours: 0
          minutes: 0
          seconds: 0.5
  - action: light.turn_on
    data:
      brightness: "{{ brightness }}"
      entity_id: "{{ light_entity_id }}"
    alias: Turn on light
  - if:
      - condition: template
        value_template: "{{ not was_lit }}"
    then:
      - action: light.turn_off
        data:
          entity_id: "{{ light_entity_id }}"
    alias: Turn off if previously unlit
  - alias: Mute if previously muted
    if:
      - condition: template
        value_template: "{{ was_muted }}"
    then:
      - action: switch.turn_on
        metadata: {}
        data:
          entity_id: "{{ mute_entity_id }}"
alias: Set assist brightness
description: ""
fields:
  device:
    selector:
      device: {}
    name: Device
    required: true
  brightness:
    selector:
      number:
        min: 1
        max: 255
    name: Brightness
    required: true

It's a bit of a pain as changing brightness whilst muted doesn't actually work (seems like a bug?), so the script unmutes (if previously muted), changes the brightness and then remutes (if previously muted). Thankfully turning the light on and off again quickly like this doesn't cause it to flash unless it was already on.

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