Contribute
Register

[Guide] Laptop backlight control using AppleBacklightFixup.kext

Hello, I have been using this new method for months already, and just now I noticed my laptop right border started to get somewhat hot, I noticed it happens if I am at full brightness and after some time I can notice to right corner to get whiter than the rest of the screen.

Is there any way this new method makes the screen brightness go "beyond where it is suppose to go"?
Because if I leave my Brightness at around 85% it doesn't get hot, but it hard to limit myself to that hahaha.

The top brightness is set inside the brightness data in AppleBacklightInjector.kext.

Also is there an update to this guide?

Why should there be an update.

I feel like the AppleBacklightInjector should deserve its own repository =P

An entire repository for a single Info.plist file?
Why?


Also the "Smooth brightness changes" secret have been discovered already?

No.
 
That patch has nothing to do with brightness.
And if your HDMI port is attached to the 0406 port, you will still need that patch for HDMI audio.
If you removed it, and your HDMI audio still works, then your HDMI is likely connected to a port that is not the 0406 port.
It seems so, but without this patch HDMI audio wasn't working on ≤10.12.3 for me. With this patch there was no brighness on 10.12.6, but without it everything is excellent.
It was probably just that you rebuilt cache, which allowed the AppleBacklight patch to take hold.
No, i have cleaned cache with command "sudo kextcache -i /", but there was no such result before i removed this patch.
Those patches probably miss a few... (some applicable Notify ops)
You might want to check your patchmatic -extract output.
I don't know what to search for, so sorry. I can only include Problem Reporting files for this moment.
 

Attachments

  • CLOVER.zip
    5.3 MB · Views: 96
  • Rehabman.zip
    34.4 KB · Views: 82
  • Asus_Q500a.ioreg
    6.4 MB · Views: 116
  • Terminal_output.txt
    3.9 KB · Views: 136
I don't know what to search for, so sorry. I can only include Problem Reporting files for this moment.

One example of a missed patch VGA->IGPU is this:
Code:
                    Method (GNOT, 2, NotSerialized)
                    {
                        If (PDRD ())
                        {
                            Return (One)
                        }

                        Store (Arg0, CEVT)
                        Store (0x03, CSTS)
                        If (LAnd (LEqual (CHPD, Zero), LEqual (Arg1, Zero)))
                        {
                            If (LOr (LGreater (OSYS (), 0x07D0), LLess (OSYS (), 0x07D6)))
                            {
                                Notify (PCI0, Arg1)
                            }
                            Else
                            {
                                Notify (VGA, Arg1)
                            }
                        }

                        Notify (VGA, 0x80) // should be Notify(IGPU, 0x80)
                        Return (Zero)
                    }

Same goes for the Notify ops in SWHD.

And this reference in _Q81:
Code:
        Method (_Q81, 0, NotSerialized)  // _Qxx: EC Query
        {
            Notify (LID, 0x80)
            If (And (VGAF, One))
            {
                Store (GLID (), ^^^VGA.CLID)
            }
        }

And here:
Code:
        Method (_Q0E, 0, NotSerialized)  // _Qxx: EC Query
        {
            If (LGreaterEqual (OSFG, OSVT))
            {
                If (^^^VGA.PRST (^^^VGA.DWBL ())) {}
            }
            Else
            {
                If (LGreater (LBTN, Zero))
                {
                    Decrement (LBTN)
                }

                If (LGreater (LBTN, 0x0A))
                {
                    Store (0x0A, LBTN)
                }

                STBR ()
                If (ATKP)
                {
                    ^^^^ATKD.NTFY (Add (LBTN, 0x20))
                }
            }

            Return (One)
        }

        Method (_Q0F, 0, NotSerialized)  // _Qxx: EC Query
        {
            If (LGreaterEqual (OSFG, OSVT))
            {
                If (^^^VGA.PRST (^^^VGA.UPBL ())) {}
            }
            Else
            {
                If (LLess (LBTN, 0x0A))
                {
                    Increment (LBTN)
                }
                Else
                {
                    Store (0x0A, LBTN)
                }

                STBR ()
                If (ATKP)
                {
                    ^^^^ATKD.NTFY (Add (LBTN, 0x10))
                }
            }

            Return (One)
 
The top brightness is set inside the brightness data in AppleBacklightInjector.kext.

Why should there be an update.


I Was wondering if someone had a problem like mine, so I looked for an update for this method to see if something changed since the last time I set up mine.

but neither Kext, Patch or SSDT changed.

An entire repository for a single Info.plist file?
Why?

Who knows, maybe one day you. might need to put more stuff in there =P
 
I Was wondering if someone had a problem like mine, so I looked for an update for this method to see if something changed since the last time I set up mine.

but neither Kext, Patch or SSDT changed.

No changes necessary.
The content of the files are as designed.
You can customize the top brightness level if that is your wish.

Who knows, maybe one day you. might need to put more stuff in there =P

No.
 
No changes necessary.
The content of the files are as designed.
You can customize the top brightness level if that is your wish.



No.

Oh I get it I was just wondering if this method could make the brightness go beyond a "safe threshold".

I tried changing the max and min values in the info plist to MAX: 255 -> 235 and min: 40 -> 20 and rebuilt the kext cache.

But that doesn't seem to have changed at all, is it possible to check the current value so I can't set the max more precisely?
 
Oh I get it I was just wondering if this method could make the brightness go beyond a "safe threshold".

Full brightness should be safe. As should be expected, it will use more power than less brightness levels.

I tried changing the max and min values in the info plist to MAX: 255 -> 235 and min: 40 -> 20 and rebuilt the kext cache.

You changed the wrong data.
 
One example of a missed patch VGA->IGPU is this:
Thanks a lot. I have understood a little more after reading your thread: [Guide] Using Clover to "hotpatch" ACPI. I have found a lot of other useful and interesting information here, I have many things to learn in this treasure of knowledge and I'm going to read all of this stuff next time i will have free time.
I changed these 2 patches to 1.
I checked DSDT, which I extracted with patchmatic: "VGAF" and "NVGA" are not impacted, while "VGA" identifier is now replaced with "IGPU". Maybe, this time i have done everything right :)
Here is the patch:
Code:
Comment      String     VGA_ -> IGPU
Find         Data       5647415F
Replace      Data       49475055
Code:
            <key>Patches</key>
            <array>
                <dict>
                    <key>Comment</key>
                    <string>VGA_ -&gt; IGPU</string>
                    <key>Find</key>
                    <data>
                    VkdBXw==
                    </data>
                    <key>Replace</key>
                    <data>
                    SUdQVQ==
                    </data>
                </dict>
            </array>
Снимок экрана 2018-01-12 в 2.02.19.png
I have also edited my previous post with patch to not mislead people in the case someone will look for it.
 
Last edited:
Thanks a lot. I have understood a little more after reading your thread: [Guide] Using Clover to "hotpatch" ACPI. I have found a lot of other useful and interesting information here, I have many things to learn in this treasure of knowledge and I'm going to read all of this stuff next time i will have free time.
I changed these 2 patches to 1.
I checked DSDT, which I extracted with patchmatic: "VGAF" and "NVGA" are not impacted, while "VGA" identifier is now replaced with "IGPU". Maybe, this time i have done everything right :)
Here is the patch:
Code:
Comment      String     VGA_ -> IGPU
Find         Data       5647415F
Replace      Data       49475055
Code:
            <key>Patches</key>
            <array>
                <dict>
                    <key>Comment</key>
                    <string>VGA_ -&gt; IGPU</string>
                    <key>Find</key>
                    <data>
                    VkdBXw==
                    </data>
                    <key>Replace</key>
                    <data>
                    SUdQVQ==
                    </data>
                </dict>
            </array>
I have also edited my previous post with patch to not mislead people in the case someone will look for it.

Yeah, that would have been the patch I would have used.

And since you don't actually have a dual-GPU (according to your profile), the "other" VGA (for the discrete device that might be present on other laptops) is not active, so you don't have to worry about the fact that you would have the discrete device also named IGPU (which would be wrong).
 
Back
Top