MatMoul / g810-led

Linux led controller for Logitech G213, G410, G413, G512, G513, G610, G810, g815, G910 and GPRO Keyboards
GNU General Public License v3.0
1.39k stars 184 forks source link

Feature request: Read (pick) current RGB value of a key #295

Open mfvianna opened 2 years ago

mfvianna commented 2 years ago

This will allow querying the current RGB color of a key (suggested command option "-i" and profile "pick" directive, similar to "var"). Command example: command: g810-led -i KEY_1 output: ffffff

This will be especially useful on profiles where one could clone a key color from another key. Example:

pick key1color KEY_1

k 2 $key1color

Would be very helpful for processes that, for example, change the letters colors based on capslock keypress or keypad number colors based on numlock keypress.

OBS: Would work o a patch for further PR, but I have no idea on how the protocol works and specific hidapi usage.