-
Notifications
You must be signed in to change notification settings - Fork 90
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add basic support for ayaneo slide. #998
Conversation
WalkthroughThis update introduces support for the new AYANEOSLIDE device in the HandheldCompanion project. It includes a specialized class for managing device-specific settings, capabilities, and custom key mappings. Additionally, a new image resource has been added to enhance the project's visuals. Changes
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media? TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (invoked as PR comments)
Additionally, you can add CodeRabbit Configration File (
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Review Status
Actionable comments generated: 3
Configuration used: CodeRabbit UI
Files ignored due to path filters (1)
HandheldCompanion/Resources/device_aya_slide.png
is excluded by:!**/*.png
Files selected for processing (3)
- HandheldCompanion/Devices/AYANEO/AYANEOSLIDE.cs (1 hunks)
- HandheldCompanion/Devices/IDevice.cs (1 hunks)
- HandheldCompanion/HandheldCompanion.csproj (2 hunks)
Additional comments: 5
HandheldCompanion/Devices/AYANEO/AYANEOSLIDE.cs (3)
- 11-11: The class
AYANEOSLIDE
is correctly defined and extendsAYANEODevice
, ensuring it fits into the existing device hierarchy.- 13-19: The
LEDGroup
enum is well-defined, providing clear identifiers for different LED groups within the device. This will facilitate easier manipulation of LED settings.- 98-113: The overridden method
GetGlyph(ButtonFlags button)
correctly implements custom glyphs for the device's OEM buttons. This ensures that the correct symbols are displayed for the device's custom keys, enhancing the user experience.HandheldCompanion/Devices/IDevice.cs (1)
- 268-270: The addition of the case "AS01" with the instantiation of
AYANEOSLIDE
in theGetDefault
method correctly integrates the new device into the system. This ensures that theAYANEOSLIDE
device will be recognized and properly initialized when detected.HandheldCompanion/HandheldCompanion.csproj (1)
- 112-112: The addition of
device_aya_slide.png
as a resource is correctly implemented and follows the project's conventions for including image resources. This change supports the PR's objective to introduce support for the AYANEO SLIDE device by ensuring the necessary graphical assets are available within the application.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Review Status
Actionable comments generated: 0
Configuration used: CodeRabbit UI
Files selected for processing (1)
- HandheldCompanion/Devices/AYANEO/AYANEOSLIDE.cs (1 hunks)
Files skipped from review as they are similar to previous changes (1)
- HandheldCompanion/Devices/AYANEO/AYANEOSLIDE.cs
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Review Status
Actionable comments generated: 0
Configuration used: CodeRabbit UI
Files selected for processing (2)
- HandheldCompanion/Devices/AYANEO/AYANEOSLIDE.cs (1 hunks)
- HandheldCompanion/Devices/IDevice.cs (1 hunks)
Files skipped from review as they are similar to previous changes (2)
- HandheldCompanion/Devices/AYANEO/AYANEOSLIDE.cs
- HandheldCompanion/Devices/IDevice.cs
Ok It's ready :D Thanks for showing me around the repo guys <3 |
For an image, what I do is get a nice product image online, then in Paint.net, make the area around it transparant. Then realize that the width is the same as the generic device picture and save as png. For the fan, we use RW everything and check which adresses Ayaspace adjusts and which change based on fan speed. https://github.com/Valkirie/HandheldCompanion/wiki/Tools#rweverything Did you get the LEDs working? |
@CasperH2O using HW everything may be a bit outta my league hahaha could you give a brief breakdown of some steps to follow to get the addresses? I'll try the same in the end with the lighting controls. maybe in a different PR |
ah I get it now. @CasperH2O I see the button presses from me hitting the extra buttons. but I really can't find a correlation between me settings fans to 100 and to auto. None for RGB too, but idk really if that would show up here. any suggestions? |
@DevL0rd may I ask you to share some photos of HC running on AYANEO Slide. I'd like to use them to advertise forthcoming compatibility :) |
yes sir @Valkirie , I can do so when I am home, right after I make a nice transparent image for the device preview in the about menu. 🙂👍 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Review Status
Actionable comments generated: 0
Configuration used: CodeRabbit UI
Files ignored due to path filters (1)
HandheldCompanion/Resources/device_aya_slide.png
is excluded by:!**/*.png
Files selected for processing (1)
- HandheldCompanion/Views/Pages/AboutPage.xaml (1 hunks)
Additional comments: 1
HandheldCompanion/Views/Pages/AboutPage.xaml (1)
- 214-214: The addition of "DevL0rd" to the contributors list is correctly implemented and follows the existing convention for listing names. This change effectively acknowledges the contributions made towards supporting the AYANEO SLIDE device. It's important to ensure that all contributors are credited appropriately, and this update seems to align with that goal.
|
Thanks! @CasperH2O shall we merge as-is or do you want to wait until you get yours ? |
Nice pictures! Im good with doing this set now and the fan and LED later when I have a device. Can we squash this PR in one commit though, seems cleaner? |
idk how to squash haha. but yeah I figure do fan and led after I'm going to play with it myself and see if I learn something meanwhile. at least for now everything else works. Just a note from that issue, ayaneo ships with a broken driver for the gyro and accelerometer. have to install the latest driver or gyro just doesn't function at all. |
Depending on your Git client, squash and merge commit instructions for GitHub Desktop Client: https://docs.github.com/en/desktop/managing-commits/squashing-commits-in-github-desktop An alternative quick and easy way is to copy the changed files from your repo, make a new branch from main, paste the files, test they work, commit and PR. Or... @Valkirie or me hits the squash and merge button on this PR. 😅 |
Correction, using GitHubs squash and merge still creates a merge commit, which we dont want. |
Support for Ayaneo Slide
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Review Status
Actionable comments generated: 0
Configuration used: CodeRabbit UI
Files ignored due to path filters (1)
HandheldCompanion/Resources/device_aya_slide.png
is excluded by:!**/*.png
Files selected for processing (4)
- HandheldCompanion/Devices/AYANEO/AYANEOSLIDE.cs (1 hunks)
- HandheldCompanion/Devices/IDevice.cs (1 hunks)
- HandheldCompanion/HandheldCompanion.csproj (2 hunks)
- HandheldCompanion/Views/Pages/AboutPage.xaml (1 hunks)
Files skipped from review as they are similar to previous changes (4)
- HandheldCompanion/Devices/AYANEO/AYANEOSLIDE.cs
- HandheldCompanion/Devices/IDevice.cs
- HandheldCompanion/HandheldCompanion.csproj
- HandheldCompanion/Views/Pages/AboutPage.xaml
alright guess I'm using GitHub desktop now haha. all done! |
Excellent! |
Resolves issues #997, and seemingly #976
All buttons working, glyphs are correct, gyro is corrected.
Issues:
I'm not sure how to get the correct ECDetails, as such I have disabled fan control.
However I am interested in learning what I can do to get these functions working :)
Summary by CodeRabbit
device_aya_slide.png
to the project.