Control your RGB LEDs on your Skikk laptop from Linux

Linux user-space tools for controlling ITE8291 RGB controllers

Posted by J├╝rgen on 25 March 2023

Introduction

After 10 years, my Dell XPS l702x was certainly showing its age. So after searching, comparing and more searching, I bought a Loki laptop from Skikk. Skikk offers support for Linux on their laptops, so that was a big pre. Everything works just fine in Mint Linux (I'm quite experienced with linux; used Slackware, Debian, Gentoo, Archlinux and even compiled my own LFS, but I'm at a stage where I want stuff to just work, and a nice UI is appreciated, so Mint is actually very nice.)

Anyway, everything worked just fine, but control over the RGB keyboard and the RGB decoration strip was a bit lacking. Using the support portion of Skikk and a bit of searching led me to the following projects:

Though they both were lacking for my combination of hardware (2 different ITE8291 controllers messes up a lot of detection), they were a valuable insight into the controllers.

Custom user-space tools

In order to have proper control, I created two, rather similar, tools for controlling the 4-zone RGB keyboard, and the 7-zone decorative RGB strip in the base of the laptop. Descriptively named keyboard and ledstrip. These tools can be installed using PIP, so a working Python environment is essential.

Keyboard

The keyboard is a 4-zone RGB panel, based on a ITE8291 rev 2 controller. It supports multiple effects, but the keyboard tools is limited to setting colors and brightness, though more effects and colors may be added.

Keyboard

Ledstrip

The decorative LED strip in the base is a 7-zone strip, based on a ITE8291 rev 3 controller. A lot of effects are supported at the moment, but more effects may be added, and more colors may be added.

Ledstrip

Installation

First of all, you'll need a working python environment on your linux workstation. On a debian based distribution:

apt install -y python3 python3-pip

After which the package from rgbleds project can be installed using:

pip install git+https://git.jurgenhaan.nl/projects/rgbleds.git

After which you'll have 2 extra commands, namely keyboard and ledstrip Removing the package can be done using:

pip uninstall rgbleds

Usage

First of all, look at the commands using keyboard -h and ledstrip -h. Which will give you the following:

$ keyboard -h
usage: keyboard [-h] [-b {low,medium,high}] {blue,green,off,on,rainbow,red,white}

positional arguments:
  {blue,green,off,on,rainbow,red,white}
                        effect

options:
  -h, --help            show this help message and exit
  -b {low,medium,high}  brightness
$ ledstrip -h
usage: ledstrip [-h] [-b {low,medium,high}] [-s {slowest,slow,medium,fast,fastest}] {blue,expand,fade,kitt,marquee,off,rainbow,red}

positional arguments:
  {blue,expand,fade,kitt,marquee,off,rainbow,red}
                        effect

options:
  -h, --help            show this help message and exit
  -b {low,medium,high}  brightness
  -s {slowest,slow,medium,fast,fastest}
                        speed

(One notable effect is kitt; This is actually why I started with these tools, since I thought it would be cool having the scanner bar of K.I.T.T. in the base of my laptop.)

Extending

The rgbleds project can be cloned using GIT, and I've been careful to keep the code simple, so extending with extra colors, and finding extra effects should be simple enough. Just clone the repo, make some changes and install the package using pip install .