Skip to content

SBAM/corsair_one_d

Repository files navigation

CorsairOne daemon

If coretemp (max temperature across all CPU cores) or coolant temperature (liquid circuit temperature) exceeds pre-defined thresholds, the daemon requests internal CorsairOne's USB device to increase fan speed.

Upon installation:

  • a custom udev rule is added to /usr/lib/udev/rules.d/ (pkg-config udev -> udevdir)
  • a custom systemd unit is added to /usr/lib/systemd/system (pkg-config systemd -> systemdsystemunitdir)
  • daemon is deployed in GNU standard bin directory

Supported devices

  • CS-9000015-EU

Dependencies

Fedora 36 setup

$ dnf install cmake gcc-c++ pkg-config boost-devel libusb-devel lm_sensors-devel spdlog-devel

Build and install

user@mach:~$ git clone https://github.com/SBAM/corsair_one_d.git
user@mach:~$ cd corsair_one_d
user@mach:~$ ./configure.sh
user@mach:~$ make -C build/Release
user@mach:~$ sudo make -C build/Release install
## reload systemd's configuration
user@mach:~$ sudo systemctl daemon-reload
## simulate corsair's USB device connected
user@mach:~$ sudo udevadm trigger --attr-match=subsystem=usb --attr-match=idVendor=1b1c --action=add
## check systemd service succesfully started
user@mach:~$ journalctl -f
[...] systemd[1]: Started CorsairOne daemon.
[...] audit[1]: SERVICE_START [...] msg='unit=CorsairOneDaemon comm="systemd" exe="/usr/lib/systemd/systemd" hostname=? addr=? terminal=? res=success'

Acknowledgments

Many thanks to: