1
0
mirror of https://github.com/MatMoul/g810-led.git synced 2024-12-23 09:16:11 +00:00
Linux led controller for Logitech G213, G410, G413, G512, G513, G610, G810, g815, G910 and GPRO Keyboards
Go to file
Dylan Baker 04370a1dae meson: Add a meson build system
meson is a build system generator similar to cmake or autotools, but
without the crazy of either of those languages. It provides a pleasant
scripting language that is inspired by languages like python, but is not
python. It has a non-turing complete language, with an emphasis on
upstream functionality instead of downstream scripts. It has support for
most Unix-like OSes, including linux, the four major BSDs, and macOS.
this includes support for abstracting dependency discovery, using
pkg-config, macOS frameworks, cmake, and some hand coded extensions.

It provides nice features like builtin support for debug builds,
changing from static to shared library builds, turning warning arguments
on and off, generates for pkg-config, and other modern niceties.

For g810-led this provides a number of advantages for distro packaging.
Distros already use meson for projects like mesa, systemd, and gnome, so
they're packaging wrappers already know how to configure, build, and
install meson based packages. It also provides advantages when moving to
other platforms, as meson understands the difference between clang,
apple's clang fork, gcc, and a host of other compilers.
2020-05-07 15:53:29 -07:00
sample_effects Add sample python effect 2017-03-18 21:52:57 +01:00
sample_profiles Fix Bad Character on fkeys as noticed in #85 2017-05-20 18:26:23 -04:00
src Finalize g815 2020-05-06 01:13:18 +02:00
systemd Update systemd service 2017-01-15 00:33:12 +01:00
udev Resolve merge conflicts 2020-04-26 18:48:26 +02:00
.gitignore Add kdev4 file 2017-04-14 02:10:13 +02:00
CONTRIBUTING.md Update CONTRIBUTING.md 2017-05-26 20:14:05 +02:00
CONTRIBUTORS.md Update project 2017-04-29 16:57:23 +02:00
install_link.sh meson: Add a meson build system 2020-05-07 15:53:29 -07:00
INSTALL.md Adding seperate Profile Sections in README 2019-10-29 17:46:51 +01:00
LICENSE Switch from LGPLv3 to GPLv3 2016-12-06 21:59:14 +01:00
makefile Version 0.4.1 2020-05-06 01:20:11 +02:00
makerelease meson: Add a meson build system 2020-05-07 15:53:29 -07:00
meson_options.txt meson: Add a meson build system 2020-05-07 15:53:29 -07:00
meson.build meson: Add a meson build system 2020-05-07 15:53:29 -07:00
PROFILES.md Adding seperate Profile Sections in README 2019-10-29 17:46:51 +01:00
README.md Finalize g815 2020-05-06 01:13:18 +02:00

g810-led

Linux led controller for Logitech G213, G410, G413, G512, G513, G610, G810, G815, G910 and GPRO Keyboards.

Compatible keyboards :

  • G213 Prodigy
  • G410 Atlas Spectrum
  • G413 Carbon
  • G512 Carbon
  • G513 Carbon
  • G610 Orion Brown
  • G610 Orion Red
  • G810 Orion Spectrum
  • G815 LIGHTSYNC
  • G910 Orion Spark
  • G910 Orion Spectrum
  • GPRO

Contribute and evolution :

Install :

Profiles :

You can load predefined configurations on startup!

Help :

g213-led --help
g410-led --help
g413-led --help
g512-led --help
g513-led --help
g610-led --help
g810-led --help
g815-led --help
g910-led --help
gpro-led --help

g810-led --help-keys
g810-led --help-effects
g810-led --help-samples

Samples :

g810-led -p /etc/g810-led/profile # Load a profile
g810-led -k logo ff0000 # Set color of a key
g810-led -a 00ff00 # Set color of all keys
g810-led -g fkeys ff00ff # Set color of a group of keys
g810-led -s color # Set keyboard power on effect
g810-led -fx color keys 00ff00 # Set fixed color effect
g810-led -fx breathing logo 00ff00 0a # Set breathing effect
g810-led -fx cycle all 0a # Set color cycle effect
g810-led -fx hwave keys 0a # Set horizontal wave effect
g810-led -fx vwave keys 0a # Set vertical wave effect
g810-led -fx cwave keys 0a # Set center wave effect

Samples with no commit :

g810-led -an 000000 # Set color of all key with no action
g810-led -gn modifiers ff0000 # Set color of a group with no action
g810-led -kn w ff0000 # Set color of a key with no action
g810-led -kn a ff0000 # Set color of a key with no action
g810-led -kn s ff0000 # Set color of a key with no action
g810-led -kn d ff0000 # Set color of a key with no action
g810-led -c # Commit all changes

Samples for G610 :

g610-led -a 60 # Set intensity of all keys
g610-led -k logo ff # Set intensity of a key
g610-led -g fkeys aa # Set intensity of a group of keys

Samples for G213 :

g213-led -a 00ff00 # Set all keys green
g213-led -r 1 ff0000 # Set region 1 red

Samples with pipe (for effects) :

g810-led -pp < profilefile # Load a profile
echo -e "k w ff0000\nk a ff0000\nk s ff0000\nk d ff0000\nc" | g810-led -pp # Set multiple keys

Testing unsupported keyboards :

Start by retrieving the VendorID and the ProductID of your keyboard using lsusb.
lsusb
Sample return :
Bus 001 Device 001: ID 046d:c331 Logitech, Inc.
In this sample VendorID is 046d and ProductID is c331. Now test your keyboard with all supported protocol (for 2019 keyboard start with -tuk 4):
g810-led -dv 046d -dp c331 -tuk 1 -a 000000
If your keyboard set all key to off you have found the protocol (1), if not continue.
g810-led -dv 046d -dp c331 -tuk 2 -a 000000
If your keyboard set all key to off you have found the protocol (2), if not continue.
g810-led -dv 046d -dp c331 -tuk 3 -a 000000
If your keyboard set all key to off you have found the protocol (2), if not continue.
g810-led -dv 046d -dp c331 -tuk 4 -a 000000
If your keyboard set all key to off you have found the protocol (3), if not, need new dump.

Building and linking against the libg810-led library :

Include in implementing source files.

#include <g810-led/Keyboard.h>

To link, simply provide -lg810-led to the build flags.

To build the g810-led application as a dynamically-linked variant, run the target:
make bin-linked

Dumps :

Dumps of keyboards are now stored in a separate project to preserve a small download size of this project. You can find them here : https://github.com/MatMoul/g810-led-resources