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 : Backlight - New option : BACKLIGHT_CAPS_LOCK #4769

Merged
merged 4 commits into from
Jan 29, 2019

Conversation

Rockman18
Copy link
Contributor

@Rockman18 Rockman18 commented Jan 4, 2019

Description

I've implemented this new option in backlight feature because my keyboard (S65-X) doesn't have LED indicators and the existing led_set_kb(usb_led) function try to use backlight as Caps Lock indicator but that creates an inconsistency with backlight_config state. Another bug, when suspending the power, the backlight stays on instead of turning off.

  • define BACKLIGHT_CAPS_LOCK to enable Caps Lock indicator using backlight (for keyboards without dedicated LED). Default state : Not defined.
  • Don't turn off LED indicators when suspend because backlight is already turned off. Else led_set(0) will turn back on backlight.
  • Documentation has been updated

Types of changes

  • Core
  • Bugfix
  • New Feature
  • Enhancement/Optimization
  • Keyboard (addition or update)
  • Keymap/Layout/Userspace (addition or update)
  • Documentation

Issues Fixed or Closed by this PR

Checklist:

  • My code follows the code style of this project.
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have read the CONTRIBUTING document. (https://docs.qmk.fm/#/contributing)
  • I have added tests to cover my changes.
  • I have tested the changes and verified that they work and don't break anything (as well as I can manage).

@Rockman18 Rockman18 force-pushed the Feature-BACKLIGHT_CAPS_LOCK_INDICATOR branch from b19e8bb to f022a0d Compare January 4, 2019 03:16
@Rockman18 Rockman18 force-pushed the Feature-BACKLIGHT_CAPS_LOCK_INDICATOR branch from f022a0d to 62cce8f Compare January 4, 2019 03:56
@Rockman18 Rockman18 changed the title Feature : Backlight - New option : BACKLIGHT_CAPS_LOCK_INDICATOR Feature : Backlight - New option : BACKLIGHT_CAPS_LOCK Jan 6, 2019
@Rockman18
Copy link
Contributor Author

Hello @drashna,
Any chance to see this PR merged ?

@Rockman18 Rockman18 force-pushed the Feature-BACKLIGHT_CAPS_LOCK_INDICATOR branch 2 times, most recently from 38e2234 to 336bf48 Compare January 15, 2019 23:07
I've implemented this feature because S65-X doesn't have LED indicators
and the existing led_set_kb(usb_led) function try to use backlight as
indicator but that creates an inconsistency with backlight_config state.

- define `BACKLIGHT_CAPS_LOCK_INDICATOR` to enable Caps Lock indicator
  using backlight (for keyboards without dedicated LED)

- Don't turn off LED indicators when suspend because backlight is
  already turned off. Else led_set(0) will turn back on backlight.

- Documentation has been updated
@Rockman18 Rockman18 force-pushed the Feature-BACKLIGHT_CAPS_LOCK_INDICATOR branch from 4f482df to 8a55889 Compare January 21, 2019 22:49
@Rockman18 Rockman18 mentioned this pull request Jan 21, 2019
13 tasks
@vomindoraan
Copy link
Contributor

vomindoraan commented Jan 27, 2019

This feature would be quite useful to me. I haven't had the chance to test this on a real board yet, but at first glance the changes look okay (though I don't think I've considered all the edge cases).

@drashna drashna merged commit df251d7 into qmk:master Jan 29, 2019
@Rockman18 Rockman18 deleted the Feature-BACKLIGHT_CAPS_LOCK_INDICATOR branch January 29, 2019 10:23
zer09 pushed a commit to zer09/qmk_firmware that referenced this pull request Feb 9, 2019
* [BACKLIGHT_CAPS_LOCK_INDICATOR] Use backlight toggling as Caps Lock LED

I've implemented this feature because S65-X doesn't have LED indicators
and the existing led_set_kb(usb_led) function try to use backlight as
indicator but that creates an inconsistency with backlight_config state.

- define `BACKLIGHT_CAPS_LOCK_INDICATOR` to enable Caps Lock indicator
  using backlight (for keyboards without dedicated LED)

- Don't turn off LED indicators when suspend because backlight is
  already turned off. Else led_set(0) will turn back on backlight.

- Documentation has been updated

* [BACKLIGHT_CAPS_LOCK_INDICATOR] Turn off all LED indicators except Caps Lock if BACKLIGHT_CAPS_LOCK_INDICATOR

* [BACKLIGHT_CAPS_LOCK] Rename BACKLIGHT_CAPS_LOCK_INDICATOR

* [BACKLIGHT_CAPS_LOCK] Use new IS_LED_ON method
dlhextall pushed a commit to dlhextall/qmk_firmware that referenced this pull request May 24, 2019
* [BACKLIGHT_CAPS_LOCK_INDICATOR] Use backlight toggling as Caps Lock LED

I've implemented this feature because S65-X doesn't have LED indicators
and the existing led_set_kb(usb_led) function try to use backlight as
indicator but that creates an inconsistency with backlight_config state.

- define `BACKLIGHT_CAPS_LOCK_INDICATOR` to enable Caps Lock indicator
  using backlight (for keyboards without dedicated LED)

- Don't turn off LED indicators when suspend because backlight is
  already turned off. Else led_set(0) will turn back on backlight.

- Documentation has been updated

* [BACKLIGHT_CAPS_LOCK_INDICATOR] Turn off all LED indicators except Caps Lock if BACKLIGHT_CAPS_LOCK_INDICATOR

* [BACKLIGHT_CAPS_LOCK] Rename BACKLIGHT_CAPS_LOCK_INDICATOR

* [BACKLIGHT_CAPS_LOCK] Use new IS_LED_ON method
@tophermckee
Copy link

Does anybody know why it's backward for me? The led is lit up when caps lock is off and led is turned off when caps lock is on? I've tried toggling caps locks with the keyboard unplugged and it consistently exhibits the same behavior

@fauxpark fauxpark mentioned this pull request Jan 25, 2024
14 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants