paul-ridgway/aero-keyboard

Make FN keys great again

iamthevoid opened this issue · 8 comments

Hello!
Have you also problems with 'fn' keys? I have Gigabyte P56XT laptop with Manjaro Linux installed and only few 'fn' buttons serves its purpose.
fn+f1 - sleep - working
fn+f2 - have no idea what is about - not working )
fn+(f3, f4) - screen brightness - not working
fn+f5 - switch monitor - working
fn+f6 - also have no idea what is it about - not working
fn+(f7-f9) - sound control - working
fn+f10 - touchpad lock - not working
fn+f11 - airplane mode - not working
fn+f12 - not defined

would you add support for these buttons?

I was hoping to have time to look at this, but haven't yet at least. From what I could tell in wireshark I think the keyboard uses a custom HID protocol to send all but some keys and the gigabyte software handles the various changes. Linux can handle standard keys but not these, so in theory they probably could be intercepted but then you'd need to create the logic to change brightness, etc.

Not only that the device has yet again changed from "7a39" to "7a3f" and your code no longer appears to work with it. I updated the "device.rb" for the new device.

Bus 001 Device 006: ID 1044:7a3f Chu Yuen Enterprise Co., Ltd USB-HID Keyboard

ps: On mine airplane mode does appear to work.

Have you tried wireshark to see if that device is being interacted with when the lights are changed using the official app?

It is possible the protocol changed too I guess, wouldn't be surprised if the windows driver abstracted this away from the officail app itself.

Sorry, I got stuck with your solution - I am fairly certain it was communicating with the keyboard, but it just didn't seem to do anything. I did have success with https://github.com/martin31821/fusion-kbd-controller His is also based on the 7a39 device, but when I changed the device in his code I was finally able to change the lights. Which tells me, yours should have worked too. I did notice his implementation always did two control transfers to set a mode or custom mode to program the lights. Take a peek at his code if you like - in the "enums.h" file. It is using libusb and it is C based, which I am much more comfortable with than Ruby - never done that before, but I am a SW engineer so a new language doesn't scare me.

Sorry for the long response, I am just happy the lights are nice now. It keeps it through power cycles, so I guess this is burned into the flash of the keyboard itself.

Glad you got it working. I'm not likely to have time to tweak and maintain this project as it works for me and I have no means to test with other hardware, but I would welcome any PRs!

Hi there. I wrote a kernel module for my Gigabyte Aero 15 SB that re-enables some of the function keys. I got annoyed that the brightness fn keys weren't working (Fn+F3, Fn+F4) so I took the matter to my own hands and wrote a custom hid driver. You can check it out here. Cheers.

Nice, I'd always hoped to have the time to tackle those

I'm going to close this thread as @jaytohe has provided a solution and I don't plan to maintain this project for other model variants etc.