ARTECK Bluetooth Keyboard Caps Lock LED Remains On

Whenever I press my caps lock button on my ARTECK Bluetooth wireless keyboard to turn off my caps lock function, the LED light for it remains on, until I press a key. This does not occur when I switch to a TTY view, as it functions perfectly fine there. I’m on Kubuntu 26.04 running KDE Plasma 6.6.5.

How do I fix this?

Managed to solve it myself using Claude. Simply do these instructions:

sudo nano /usr/local/bin/capslock-led-fix.py

Inside that, paste this:

#!/usr/bin/env python3
import evdev
from evdev import ecodes
import time

DEVICE_NAME = "Telink Wireless Receiver"

def find_device():
    for path in evdev.list_devices():
        dev = evdev.InputDevice(path)
        if dev.name == DEVICE_NAME:
            return dev
    return None

while True:
    dev = find_device()
    if not dev:
        time.sleep(3)
        continue
    try:
        state = False
        for event in dev.read_loop():
            if event.type == ecodes.EV_KEY and event.code == ecodes.KEY_CAPSLOCK and event.value == 1:
                state = not state
                dev.set_led(ecodes.LED_CAPSL, int(state))
    except OSError:
        time.sleep(3)

Make it executable and then edit the systemd service file for it:

sudo chmod +x /usr/local/bin/capslock-led-fix.py

sudo nano /etc/systemd/system/capslock-led-fix.service

Add this into the file:

[Unit]
Description=Force Caps Lock LED sync for Telink wireless keyboard dongle
After=multi-user.target

[Service]
ExecStart=/usr/bin/python3 /usr/local/bin/capslock-led-fix.py
Restart=always
RestartSec=2

[Install]
WantedBy=multi-user.target

Run these to reload and enable the service:

sudo systemctl daemon-reload
sudo systemctl enable --now capslock-led-fix.service

Now press the caps lock LED to make sure it actually turns off the light when turning off caps lock. If everything went right, you’ve got it working!