trccd is a lightweight solution for controlling Thermalright LCD displays
found on AIO coolers such as the Frozen Warframe series. It uses libusb and
ffmpeg to process and stream images or videos (or just a solid colour)
directly to the screen.
- Easy to use: Just point
trccdat your media and it usesffmpegunder the hood to automatically scale, crop and convert it to fit the display. - Automatic caching: Processed media is cached to disk on the first run. Each subsequent run will begin playing the media instantly by loading from the cache.
- systemd integration: Designed to run in the background as a systemd
service. The service unit is started automatically by
systemd-udevdwhen the device is detected. - Security: The service unit file makes extensive use of systemd sandboxing
features (see
systemd.exec(5)#SANDBOXING)
to run the daemon as a dynamic user with stripped capabilities. A custom udev
rule grants access to the USB device via the
tr_displaygroup. - Lightweight: Written in pure C with performance and efficiency in mind. The Linux page cache is used to keep as much of the media in memory as possible without exhausting system RAM and the program will loop the media with as few USB transfers as it can manage. For static images and solid colours this uses very little CPU time.
- Pipe in your own data: Arbitrary data can be read from
stdinso you can experiment with your ownffmpegcommands or use a different program to process your media.
| Vendor | Product | VID:PID |
|---|---|---|
| Winbond Electronics Corp. | USBDISPLAY | 0416:5302 |
Only the device above is currently supported. If you own a Thermalright product that isn't supported and you're willing to help test, please create an issue and we can try to add support.
Tip
Run lsusb to find the name of your device.
gcc>= 16 orclang>= 21makelibusbpkg-configffmpeg(not required if you only plan to pipe in pre-processed data)
Clone the repository and build with make:
git clone https://github.com/Jontos/trccd.git
cd trccd
makeInstall to your system with:
sudo make install
sudo systemd-sysusers
sudo systemctl daemon-reload
sudo udevadm control --reload
sudo udevadm triggerIf the device is already plugged in udevadm trigger will automatically start
the systemd service. See usage for instructions on adjusting this
behaviour.
Note
Currently only tested on Arch Linux. If you run into problems on a different distro, please create an issue.
trccd can be uninstalled with:
sudo make uninstallThis won't remove the configuration file, which must be removed manually.
When running as a systemd service, trccd can be configured by editing the
values in the trccd.conf file. Set the path to your media like so:
MEDIA=/etc/trccd/my_video.mkvThe OPTIONS= variable can be used to pass command line flags to trccd:
MEDIA=/path/to/my_media
OPTIONS=--mode videoTip
The location of the trccd.conf file will differ depending on how
you installed trccd. Use systemctl show -P EnvironmentFiles trccd to query
its location.
Restarting the service will pick up new config changes:
sudo systemctl restart trccdImportant
The path used for MEDIA must be readable by the dynamic user created by
systemd; this user cannot read files inside your home directory. Copy your
media somewhere globally readable (e.g. in the same directory as the
trccd.conf file) and specify that instead.
The service can be manually stopped or started with the below commands:
sudo systemctl stop trccdsudo systemctl start trccdMask the systemd service if you want to prevent it from being automatically
started by systemd-udevd:
sudo systemctl mask trccdIt can be unmasked with:
sudo systemctl unmask trccdtrccd can also be run manually:
trccd [OPTION]... {FILE|COLOUR}
Where FILE is either the path to the media you want to display or - for
standard input, and COLOUR is either an X11 colour name (see
colour_names.h for the full list) or an RGB565 colour
value in hexadecimal format (e.g. 0xF800 for red).
Here's an example of how you can pipe data into trccd via standard input:
ffmpeg -nostdin \
-loglevel fatal \
-i /path/to/my_media.mkv \
-an -sn \
-vf "scale=320:240:force_original_aspect_ratio=increase,crop=320:240,transpose=1,fps=22" \
-f rawvideo \
-pix_fmt rgb565le - | trccd --mode video -Note
The command above is what trccd runs internally for video mode.
Data can also be fed in from a file using shell redirection:
trccd --mode video - < rgb565_bytes.binNote
Data piped/redirected into trccd this way is not cached to disk.
The first time you play a media file, trccd runs ffmpeg to convert it and
writes the processed frames to disk. Subsequent runs with the same media will
map those cached frames into memory, avoiding redundant calls to ffmpeg and
reducing start-up time.
- Under systemd:
/var/cache/private/trccd. - When run manually:
$XDG_CACHE_HOME/trccdor$HOME/.cache/trccdif$XDG_CACHE_HOMEis empty or unset.
It's safe to delete these directories to wipe the cache. For the systemd service, the cache can be wiped by running this command when the service is stopped:
sudo systemctl clean trccd- Available disk space is not checked before caching the media to disk.
- Media is saved in an uncompressed format. One frame is 153.6 kilobytes, so one second of video at 22 FPS will be ~3.4MB; keep this in mind if you plan to watch any movies on your CPU cooler.
This project is licensed under the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. See the COPYING file for details.