From af9d3eb50e6332fc9ee6f5f6ec53aae60d727c8d Mon Sep 17 00:00:00 2001 From: Serge <5920850+seerge@users.noreply.github.com> Date: Sat, 10 Feb 2024 22:53:22 +0100 Subject: [PATCH 1/4] Skip airplane mode command for ancient devices https://github.com/seerge/g-helper/issues/2052 --- app/AppConfig.cs | 5 +++++ app/Input/InputDispatcher.cs | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/app/AppConfig.cs b/app/AppConfig.cs index bb148661..fe5d9de1 100644 --- a/app/AppConfig.cs +++ b/app/AppConfig.cs @@ -387,6 +387,11 @@ public static class AppConfig return (ContainsModel("G614JV") || ContainsModel("G614JZ") || ContainsModel("G512LI") || ContainsModel("G513R") || ContainsModel("G713PV") || ContainsModel("G513IE") || ContainsModel("G713RC") || ContainsModel("G513QM") || ContainsModel("G531G")) && !Is("per_key_rgb"); } + public static bool IsNoAirplaneMode() + { + return ContainsModel("FX506"); + } + public static bool IsNoDirectRGB() { return ContainsModel("GA503") || ContainsModel("G533Q"); diff --git a/app/Input/InputDispatcher.cs b/app/Input/InputDispatcher.cs index eac35530..e1bb2835 100644 --- a/app/Input/InputDispatcher.cs +++ b/app/Input/InputDispatcher.cs @@ -638,7 +638,7 @@ namespace GHelper.Input KeyProcess("m6"); return; case 136: // FN + F12 - Program.acpi.DeviceSet(AsusACPI.UniversalControl, AsusACPI.Airplane, "Airplane"); + if (!AppConfig.IsNoAirplaneMode()) Program.acpi.DeviceSet(AsusACPI.UniversalControl, AsusACPI.Airplane, "Airplane"); return; case 181: // FN + Numpad Enter KeyProcess("fne"); From 094fce0117b8d5acec78c701979fa8afe313982a Mon Sep 17 00:00:00 2001 From: Serge <5920850+seerge@users.noreply.github.com> Date: Sun, 11 Feb 2024 11:46:37 +0100 Subject: [PATCH 2/4] Backlight brightness tweak for G14 2024 --- app/AppConfig.cs | 5 +++++ app/USB/Aura.cs | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/app/AppConfig.cs b/app/AppConfig.cs index fe5d9de1..eb1577d9 100644 --- a/app/AppConfig.cs +++ b/app/AppConfig.cs @@ -377,6 +377,11 @@ public static class AppConfig return ContainsModel("GA401") || ContainsModel("FX517Z") || ContainsModel("FX516P") || ContainsModel("X13") || IsARCNM() || ContainsModel("GA502IU"); } + public static bool IsInputBacklight() + { + return ContainsModel("GA503") || ContainsModel("GA403"); + } + public static bool IsStrix() { return ContainsModel("Strix") || ContainsModel("Scar") || ContainsModel("G703G"); diff --git a/app/USB/Aura.cs b/app/USB/Aura.cs index 6a63e040..ebc6e53f 100644 --- a/app/USB/Aura.cs +++ b/app/USB/Aura.cs @@ -298,7 +298,7 @@ namespace GHelper.USB if (AppConfig.IsAlly()) ApplyAura(); - if (AppConfig.ContainsModel("GA503")) + if (AppConfig.IsInputBacklight()) AsusHid.WriteInput(new byte[] { AsusHid.INPUT_ID, 0xBA, 0xC5, 0xC4, (byte)brightness }, log); }); From 2785bc626703ba4dbf96c73d892cee60146e7588 Mon Sep 17 00:00:00 2001 From: Serge <5920850+seerge@users.noreply.github.com> Date: Sun, 11 Feb 2024 14:03:11 +0100 Subject: [PATCH 3/4] Update README.md --- docs/README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/docs/README.md b/docs/README.md index 3ccbc3d0..39d5dfbe 100644 --- a/docs/README.md +++ b/docs/README.md @@ -107,6 +107,7 @@ Huge thanks to [@IceStormNG](https://github.com/IceStormNG) 👑 for contributio ### ⌨️ Keybindings - ``Fn + F5 / Fn + Shift + F5`` - Toggle Performance Modes forwards / backwards +- ``Shift + Fn + F7 / F8`` - Set Anime Matrix / Slash Lightning brightness Down / Up - ``Ctrl + Shift + F5 / Ctrl + Shift + Alt + F5`` - Toggle Performance Modes forwards / backwards - ``Ctrl + Shift + F12`` - Open G-Helper window - ``Ctrl + M1 / M2`` - Screen brightness Down / Up From 060e3b7f7df6268956ac9e90b6528d1090de5770 Mon Sep 17 00:00:00 2001 From: Serge <5920850+seerge@users.noreply.github.com> Date: Sun, 11 Feb 2024 16:09:51 +0100 Subject: [PATCH 4/4] Updates to RyzenControl to support Hawk Point CPUs --- app/Ryzen/RyzenControl.cs | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/app/Ryzen/RyzenControl.cs b/app/Ryzen/RyzenControl.cs index 77330f5b..28c9b47d 100644 --- a/app/Ryzen/RyzenControl.cs +++ b/app/Ryzen/RyzenControl.cs @@ -7,7 +7,6 @@ using GHelper.Helpers; using System.Management; using System.Net; -using System.Reflection; namespace Ryzen { @@ -23,7 +22,6 @@ namespace Ryzen public static int MinTemp => AppConfig.Get("min_temp", 75); public const int MaxTemp = 98; - public static string[] FAM = { "RAVEN", "PICASSO", "DALI", "RENOIR/LUCIENNE", "MATISSE", "VANGOGH", "VERMEER", "CEZANNE/BARCELO", "REMBRANDT", "PHOENIX", "RAPHAEL/DRAGON RANGE" }; public static int FAMID { get; protected set; } public static string CPUModel = ""; @@ -42,6 +40,7 @@ namespace Ryzen //PHEONIX - 9 //RAPHAEL/DRAGON RANGE - 10 //MENDOCINO - 11 + //HAWKPOINT - 12 public static void Init() { @@ -108,7 +107,7 @@ namespace Ryzen FAMID = 8; //REMBRANDT } - if (CPUModel.Contains("Model " + Convert.ToString(116))) + if (CPUModel.Contains("Model " + Convert.ToString(116)) || CPUModel.Contains("Model " + Convert.ToString(120))) { FAMID = 9; //PHEONIX } @@ -123,6 +122,11 @@ namespace Ryzen FAMID = 11; //MENDOCINO } + if (CPUModel.Contains("Model " + Convert.ToString(117))) + { + FAMID = 12; //HAWKPOINT + } + Logger.WriteLine($"CPU: {FAMID} - {CPUName} - {CPUModel}"); SetAddresses(); @@ -224,7 +228,7 @@ namespace Ryzen Smu.PSMU_ADDR_RSP = 0x3B10A80; Smu.PSMU_ADDR_ARG = 0x3B10A88; } - else if (FAMID == 5 || FAMID == 8 || FAMID == 9 || FAMID == 11) + else if (FAMID == 5 || FAMID == 8 || FAMID == 9 || FAMID == 11 || FAMID == 12) { Smu.MP1_ADDR_MSG = 0x3B10528; Smu.MP1_ADDR_RSP = 0x3B10578;