-
-
Notifications
You must be signed in to change notification settings - Fork 1
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
Screenpad Plus Backlight Control #6
Comments
For reference, @shiecldk has a breakdown of EC events for the UX582 in hieplpvip/AsusSMC#102 (comment). It's worth mentioning that |
Continuing on the screenpad plus backlight discussion in #4 (comment)
Below is the WMNB method that executes the above ACPI calls// \_SB.ATKD.WMNB
54953 | Method (WMNB, 3, Serialized)
54954 | {
54955 | CreateDWordField (Arg2, Zero, IIA0)
54956 | CreateDWordField (Arg2, 0x04, IIA1)
54957 | Local0 = (Arg1 & 0xFFFFFFFF)
...
55362 | If ((Local0 == 0x53564544))
55363 | {
...
55524 | Name (TMBF, Buffer (0x02)
55525 | {
55526 | 0x00, 0x00
55527 | })
55528 | If ((IIA0 == 0x00050031))
55529 | {
55530 | TMBF [Zero] = Zero
55531 | Local0 = ^^PCI0.LPCB.EC0.REBC (0x12, 0x02)
55532 | Local1 = DerefOf (Local0 [Zero])
55533 | If ((IIA1 == One))
55534 | {
55535 | Local1 &= 0xFD
55536 | }
55537 | Else
55538 | {
55539 | Local1 |= 0x02
55540 | }
55541 |
55542 | TMBF [One] = Local1
55543 | Return (^^PCI0.LPCB.EC0.WEBC (0x13, 0x02, TMBF))
55544 | Return (Zero)
55545 | }
55546 |
55547 | If ((IIA0 == 0x00050032))
55548 | {
55549 | TMBF [One] = IIA1 /* \_SB_.ATKD.WMNB.IIA1 */
55550 | TMBF [Zero] = One
55551 | Return (^^PCI0.LPCB.EC0.WEBC (0x13, 0x02, TMBF))
55552 | Return (Zero)
55553 | }
55554 |
55555 | If ((IIA0 == 0x00050035))
55556 | {
55557 | TMBF [Zero] = Zero
55558 | Local0 = ^^PCI0.LPCB.EC0.REBC (0x12, 0x02)
55559 | Local1 = DerefOf (Local0 [Zero])
55560 | If ((IIA1 == Zero))
55561 | {
55562 | Local1 &= 0xF7
55563 | }
55564 | ElseIf ((IIA1 == One))
55565 | {
55566 | Local1 |= 0x08
55567 | }
55568 |
55569 | TMBF [One] = Local1
55570 | Return (^^PCI0.LPCB.EC0.WEBC (0x13, 0x02, TMBF))
55571 | Return (Zero)
55572 | } I have an example SSDT for disabling the screenpad plus display connector that writes to the EC's memory instead (based on @wern-apfel's
Rather than reading or writing to the embedded controller's memory directly ( External (\_SB.ATKD.WMNB, MethodObj)
// Sets the screenpad plus backlight intensity,
// where 'xx' is a hex value between 00 and FF.
\_SB.ATKD.WMNB(0x0, 0x53564544, /*b32000500xx000000*/)
// Disables screenpad plus until next backlight change.
\_SB.ATKD.WMNB(0x0, 0x53564544, /*b3100050000000000*/) Some behavior can be ported to AsusSMC from the asus-wmi-screenpad repo. |
Added refactor in 9de3d05. |
Do you solve this with SSDT-SPLC.aml? |
Yes. Its been fully implemented since the above PR, though an idea for #21 is to use an additional fake PNLF device to store and buffer backlight data to manipulate WMI methods. It should work more natively with those changes. |
Backlight is set by ACPI calls exposed through a WMI driver. For reference, there is a linux module that probes ACPI for methods controlling backlight of the screenpad. Below details basic methods for the display's backlight control implemented similarly to keyboard backlight control in AsusSMC:
asus-wmi.h#L50-L74
asus-wmi.c#L819-L831
If it can't be controlled in the same submenu as the primary display, then mapping Screenpad backlight brightness in a control center slider like keyboard brightness may be a good alternative UX implementation:
The text was updated successfully, but these errors were encountered: