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

Can't turn on scroll lock led #5342

Closed
olly1240 opened this issue May 14, 2020 · 6 comments
Closed

Can't turn on scroll lock led #5342

olly1240 opened this issue May 14, 2020 · 6 comments

Comments

@olly1240
Copy link

  • Sway Version:

1.4

  • Debug Log:

https://gist.github.com/olly1240/1a70e2f41101fa83e529057c19a01c97

  • Configuration File:

https://gist.github.com/olly1240/8e7856347fef222483b347bbb60ed625

Description

When I try to turn on the scroll lock led by xkb_options neither input * xkb_options grp:sclk_toggle and input * xkb_options grp_led:scrollworks. I tried to assign that to a key but did not work either. If I forcibly turn them on by sudo sh -c "echo 1 > /sys/class/led/input24::scrolllock/brightness" it lights up for a millisecond then turns off. I need to turn this led on because it's tied to my keyboard back-lighting. It shares the power with the scroll lock led.
On tty i can enable and disable it with the echo and with setleds +scroll

@rgouicem
Copy link

Same problem here, with sway 1.4.

@BusterGR18
Copy link

I'm facing the exact same issue, also tried the echo method with the same result

@Xyene
Copy link
Member

Xyene commented Jun 10, 2020

It shares the power with the scroll lock led.

That's horrifying...

To be more precise, I believe the behavior is that the backlight turns off after releasing your Enter key -- if you were to keep it pressed, I suspect the backlight would stay on. That's the case with my regular scrolllock LED, anyway.

The relevant logic is actually in wlroots, in particular this bit of code which resends LED states post-key-release. This works marginally better in GNOME/mutter since mutter only updates LEDs when a relevant key is pressed, whereas wlroots does it on every key release. wlroots could perform that logic only when modifiers change as an optimization, but it'd only mask the issue and your backlight would still go off the moment you released CapsLock.

So, I don't think there's much we can do here. That said, here's a relevant libinput thread with more details, with a workaround script you could try.

FWIW, you can also locally patch wlroots to always send the scrolllock bit in the code I linked to work around the issue with your hardware.

@xiliuya
Copy link

xiliuya commented Nov 19, 2022

I made a wlroot patch through the above answers
Operation process link
http://www.gentoo.site/viewtopic.php?id=589

@bigrand
Copy link

bigrand commented Dec 14, 2022

I made a wlroot patch through the above answers Operation process link http://www.gentoo.site/viewtopic.php?id=589

Based on these workarounds I managed to make a better workaround. I also submitted this issue on wlroots (issue).

@xiliuya
Copy link

xiliuya commented Dec 14, 2022

I made a wlroot patch through the above answers Operation process link http://www.gentoo.site/viewtopic.php?id=589

Based on these workarounds I managed to make a better workaround. I also submitted this issue on wlroots (issue).

This is great. I submitted a merger request to wlroots two weeks ago. merge_requests/3867

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

No branches or pull requests

6 participants