Jump to content

UPDATED 20.12. GenericBrightness.kext


  • Please log in to reply
671 replies to this topic

#621
webkostas

webkostas

    InsanelyMac Protégé

  • Members
  • Pip
  • 42 posts

SUCCESS !!!

I managed to get brightness working on my laptop (Nvidia G310m) ! Although it doesn't use your kext, ivik, but I have used it a lot during my research and I think it is interesting information for other nvidia users.


Now, before I get to how I did it, I'd like to warn you that I have just succeeded moments ago and I still need to check temperatures and other harmful factors that may cause harm to the hardware.

Apparently, all it needed was the @0,pwm-info key injected, I took this key from a MacBookPro6,1 dump,
Here, since our graphics card were similar and injected it via GFX strings. Additionally, I added a PNLF device to my DSDT ( usefulness is still to be tested ).

Here is the Pnlf device:

Device (PNLF)                    {                        Name (_HID, EisaId ("APP0002"))                        Name (_CID, "backlight")                        Name (_UID, 0x0A)                        Name (_STA, 0x0B)                    }

And here is the injected part, you can inject it via DSDT or GFX string, it is your choice. You can look up information on how to do that on this forum.

<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"><plist version="1.0"><dict>	<key>PciRoot(0x0)/Pci(0x1,0x0)/Pci(0x0,0x0)</key>	<dict>		<key>@0,AAPL,boot-display</key>		<string>0x00000001</string>		<key>@0,EDID</key>		<data>AP///////wBMo0UyAAAAAAASAQCAIhN4Cof1lFdPjCcnUFQAAAABAQEBAQEBAQEBAQEBAQEBQRxWoFAAFjAwICUAWMIQAAAZAAAADwAAAAAAAAAAACOHAmQBAAAA/gBTQU1TVU5HCiAgICAgAAAA/gBMVE4xNTZBVDAyMDAwAHw=</data>		<key>@0,backlight-control</key>		<data>AQAAAA==</data>		<key>@0,use-backlight-blanking</key>		<data></data>		<key>@1,can-hot-plug</key>		<data></data>		<key>@0,pwm-info</key>		<data>AhgAZJBZAgAIUgAApRwAAAAEAAABAAAA</data>		<key>AAPL,backlight-control</key>		<data>AQAAAA==</data>		<key>AAPL,aux-power-connected</key>		<data>AQAAAA==</data>		<key>@0,built-in</key>		<string>0x01</string>		<key>@0,compatible</key>		<data>TlZEQSxOVk1hYwA=</data>		<key>@0,device_type</key>		<data>ZGlzcGxheQA=</data>		<key>@0,display-cfg</key>		<string>0x0036ffff</string>		<key>@0,name</key>		<data>TlZEQSxEaXNwbGF5LUEA</data>		<key>@1,compatible</key>		<data>TlZEQSxOVk1hYwA=</data>		<key>@1,device_type</key>		<data>ZGlzcGxheQA=</data>		<key>@1,display-cfg</key>		<string>0x013eff00</string>		<key>@1,name</key>		<data>TlZEQSxEaXNwbGF5LUIA</data>		<key>AAPL,slot-name</key>		<string>Slot-1</string>		<key>NVCAP</key>		<data>BAAAAAAAAQD+AAAAAAAACgAAAAA=</data>		<key>NVPM</key>		<data>AQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA==</data>		<key>VRAM,totalsize</key>		<string>0x20000000</string>		<key>device_type</key>		<data>TlZEQSxQYXJlbnQA</data>		<key>model</key>		<data>R2VGb3JjZSBHMzEwTQA=</data>		<key>rom-revision</key>		<data>IEJJT1MA</data>	</dict></dict></plist>

It all began to work for me when I injected the @0,pwm-info key however some of the other keys may still be necessary (especially the keys concerning backlight).

Again, this may be dangerous, be careful when or if you try this out. I am not responsible if this bricks your hardware


Hey guys sorry for the question, but...I searched high and low and could not manage to find an answer...How do I inject the above info and where??? It is not very specific and I just can't get it, sorry...Thanks a lot

#622
TheDynamo

TheDynamo

    InsanelyMac Protégé

  • Members
  • Pip
  • 24 posts
  • Gender:Male
  • Location:London
Hi,

Thanks - worked with the 2nd method with minimal DSDT Edit - tried with the 1st method but it didnt work.

#623
webkostas

webkostas

    InsanelyMac Protégé

  • Members
  • Pip
  • 42 posts
my above question is solved! Thanks:
http://www.insanelym...p...t&p=1729961

#624
jazzyguy

jazzyguy

    InsanelyMac Geek

  • Members
  • PipPipPipPip
  • 188 posts
  • Gender:Male
  • Location:USA
I have a edited DSDT, which I can upload if anyone needs to see it. But I have a weird problem.

When I turn on my laptop, I can adjust the brightness, but it doesn't work right. The first level of brightness is 0%, then it jumps to like 80, then 90, then 100%. So its really too bright.

But if I put it to sleep and wake it up, brightness functions fine, with all 16 different levels and everything. How can I fix that?

#625
macq

macq

    InsanelyMac Geek

  • Members
  • PipPipPip
  • 115 posts
@ ivik / Nixin, /others

Need a bit of help here. I am on Lion 10.7.

I get the brightness slider after dsdt patching and putting GenericBrightness.kext in S/L/E,but moving the slider doesn't do anything.
There is no change in brightness levels,nor is there any change with brightness keys or fn.
Rest of my system is working fine.

My patched DSDT.aml and ioreg is attached.

Please help!!
TIA :unsure:

Attached Files

  • Attached File  Macq.zip   436.35KB   13 downloads


#626
gnnash

gnnash

    InsanelyMac Protégé

  • Members
  • Pip
  • 21 posts
Well, I've searched high and low, and am getting closer to a solution, but not quite there yet...

I managed to get brightness control with the menulet. However, I have no brightness slider in display preferences at all. I do have the PNLF device added to my DSDT. I have also tried injecting info for my card (NVidia Geforce 9300M GS), but every time I do, the correct drivers are not loaded, but I get regular 1024x768 VESA resolution at logon with no QE/CI or brightness control.

Any ideas from anyone? My DSDT is attached.

#627
gizmonder

gizmonder

    InsanelyMac Protégé

  • Members
  • Pip
  • 9 posts
  • Gender:Male
  • Location:Belarus
Big thanks! Second method works with Sony VAIO EB.

#628
szokolov

szokolov

    InsanelyMac Protégé

  • Members
  • Pip
  • 13 posts
Hi,

the second method don't work for me (Lenovo G570, 10.7.1). After install GenericBrightness.kext and DSDT modification dmesg show:[codebox]Acpi brightness levels:11, lowest brightness:10, highest brightness:100
GenericBrightness: Kernel Control Registered[/codebox]
No slider in SystemPreferences and Fn+Up or Fn+Down don't work.

My DSDT:
Attached File  DSDT_Lenovo_G570.aml.zip   14.88KB   17 downloads

Thanks!

Szokolov

#629
Zprood

Zprood

    InsanelyMac Sage

  • Members
  • PipPipPipPipPip
  • 251 posts
  • Gender:Male
  • Location:CHN

Hi,

the second method don't work for me (Lenovo G570, 10.7.1). After install GenericBrightness.kext and DSDT modification dmesg show:

Acpi brightness levels:11, lowest brightness:10, highest brightness:100  GenericBrightness: Kernel Control Registered
No slider in SystemPreferences and Fn+Up or Fn+Down don't work.

My DSDT:
Attached File  DSDT_Lenovo_G570.aml.zip   14.88KB   17 downloads

Thanks!

Szokolov

You don't add PNLF device to the \_SB , so you can't see slider in the SystemPreferences--Display. I add that Device for you, try it.Attached File  dsdt.aml.zip   14.99KB   67 downloads

#630
szokolov

szokolov

    InsanelyMac Protégé

  • Members
  • Pip
  • 13 posts

You don't add PNLF device to the \_SB , so you can't see slider in the SystemPreferences--Display. I add that Device for you, try it.Attached File  dsdt.aml.zip   14.99KB   67 downloads


Hi Zprood!

Thanks for your help. Now, I can adjust screen brightness in SystemPreferences-Display section, but the Fn+Up, Fn+Down or Brightness Menulet doesn't work. In terminal brightness get result is 0.

Now I use ApplePS2Controller.kext because VoodooPS2Controller.kext doesn't work. If I use the second one the FN key maybe work?

Szokolov

#631
Zprood

Zprood

    InsanelyMac Sage

  • Members
  • PipPipPipPipPip
  • 251 posts
  • Gender:Male
  • Location:CHN

Hi Zprood!

Thanks for your help. Now, I can adjust screen brightness in SystemPreferences-Display section, but the Fn+Up, Fn+Down or Brightness Menulet doesn't work. In terminal brightness get result is 0.

Now I use ApplePS2Controller.kext because VoodooPS2Controller.kext doesn't work. If I use the second one the FN key maybe work?

Szokolov

I see you have a Lenovo laptop and me too, the problem is we can't get Fn+up/down scan code with debug version VoodooPS2keyboard, it is not a static value, so if your laptop get the driver work, you can use the "Pause" and "Fn+Delete" key to adjust the brightness. In my case, i can use them all, even Fn+Up/Down, I don't why you can't get Fn+up/down work, maybe you can take a look in your dsdt, also put it reboot see whether it change or not.

#632
szokolov

szokolov

    InsanelyMac Protégé

  • Members
  • Pip
  • 13 posts

I see you have a Lenovo laptop and me too, the problem is we can't get Fn+up/down scan code with debug version VoodooPS2keyboard, it is not a static value, so if your laptop get the driver work, you can use the "Pause" and "Fn+Delete" key to adjust the brightness. In my case, i can use them all, even Fn+Up/Down, I don't why you can't get Fn+up/down work, maybe you can take a look in your dsdt, also put it reboot see whether it change or not.


Hi Zprood,

thanks your tip! In my laptop the Fn+ScrLk and Fn+Pause work.
BTW if you have a Lenovo laptop can you help me with the sleep, maybe? I put SleepEnabler.kext to E/E but after system go sleep immediately reboot the laptop. Sorry for the offtopic.

Thanks again!

Szokolov

#633
Zprood

Zprood

    InsanelyMac Sage

  • Members
  • PipPipPipPipPip
  • 251 posts
  • Gender:Male
  • Location:CHN

Hi Zprood,

thanks your tip! In my laptop the Fn+ScrLk and Fn+Pause work.
BTW if you have a Lenovo laptop can you help me with the sleep, maybe? I put SleepEnabler.kext to E/E but after system go sleep immediately reboot the laptop. Sorry for the offtopic.

Thanks again!

Szokolov

I have one too, but it is too old, i wanna to help but can't do that. Cause I just know my hardware and how to get it work. BTW you can search the forum by using the your laptop's model, chip etc. Sleep problem is related USB high speed bus, such as EHC1, EHC2. Hope you can get good luck.

#634
gnnash

gnnash

    InsanelyMac Protégé

  • Members
  • Pip
  • 21 posts
I have added the PNLF device to my DSDT, but have no brightness slider under either Snow Leopard or Lion. My DSDT is attached, can someone shed some light on this issue?

Attached Files



#635
Zprood

Zprood

    InsanelyMac Sage

  • Members
  • PipPipPipPipPip
  • 251 posts
  • Gender:Male
  • Location:CHN

I have added the PNLF device to my DSDT, but have no brightness slider under either Snow Leopard or Lion. My DSDT is attached, can someone shed some light on this issue?

Attached File  dsdt.aml.zip   11.09KB   7 downloads
Try it, you should add the PNLF device under the '_SB'.

#636
gnnash

gnnash

    InsanelyMac Protégé

  • Members
  • Pip
  • 21 posts

Attached File  dsdt.aml.zip   11.09KB   7 downloads
Try it, you should add the PNLF device under the '_SB'.


I swapped in this DSDT, and still have no slider unfortunately.

#637
alecri2002

alecri2002

    InsanelyMac Protégé

  • Members
  • Pip
  • 11 posts
  • Gender:Male
Hi,
that my situation: I have three netbook two Samsung NC10-N130 and one Acer Aspire One A110L, all with 10.6.8 same setup. I patch DSDT same way (add PNLF) but The Samsung have _BCM _BCL _BQC in DSDT Aspire no.
The result is that Samsung have Brightness from slider and fn Key (F12/ins) (also sun icon) working.
Aspire have slider that move fn key (F12/ins) (also sun icon) The number change also in ioreg (the number are the same 0x400/max-0x0/Min, and change the same way in samsung and Aspire ioreg: three press down give the same value in ioreg 0x340) but brightness not changing. I can use fn arrow up/down but with no sun icon as without DSDT to dim (no sun icon also in XP and Ubuntu).
The brightness is controlled directly from BIOS and the step are written in BIOS in fact the minimum value change in different BIOS version (I read it somewhere)
The brightness is controlled from EC. I can see in rw everything one number (EC 66/62 reg 51 (81)) change from 00 to 09 during fn up/down key pressure, and if I write on it the brightness change.

So the question is: can I add _BCL _BCM _BQC to aspire DSDT? Can I discover the name of register for store Brightness and if yes how can I find it? Maybe BLVL?

Or there is no hope to use vanilla brightness on Aspire One?

PS: I have look inside DSDT from a MacBook (Gma3100) and from a MacBookPro (8600M) and there are no _BCL, _BCM, _BQC on both so I hope is possible also on Acer, but my knowledge is very poor and I'm stuck here.

Attached File  DSDT_N130_AAO.zip   616.95KB   2 downloads

#638
monkeyalan

monkeyalan

    InsanelyMac Protégé

  • Members
  • Pip
  • 3 posts
Hello,

I have managed to get the slider active under display but the brightness is erratic and non linear! I tried to follow the instructions from here:

http://www.insanelym...p;#entry1747344 but when I try to compile the dsdt file with the changes its produces errors.

I have a 6510b with X3100 graphics.

Any help would be great!

Attached File  dsdt_hp6510b.zip   33.06KB   3 downloads

#639
teme

teme

    InsanelyMac Protégé

  • Members
  • PipPip
  • 83 posts
^^^in that same thread the OP posted a fix for the brightness that works great
i used it and had no problems
try it
it's an executable. run it and reboot. no need to edit the DSDT
that's it

#640
Onishi

Onishi

    InsanelyMac Protégé

  • Members
  • PipPip
  • 93 posts
Fist of all thanks for this topic, topic starter.
But I can't set brightness of my Toshiba A-100 internal LCD with topic starter instructions.
A bit later on Tony's site I found something and I have it mixed whit topic starter instructions and made the brightness work besides some inconveniences (my VGA display stops autodedect) .
SO what I've done.
1. Added to Device (PNLF) to Device (PCI0)=&gt; Device (PEGP)=&gt; Device (VGA)=&gt; Device (LCD) where were _BCL, _BCM, _BQC methods (these methods I include to Device (PNLF))
						Device (PNLF)
						{
							Name (_HID, EisaId ("APP0002"))
							Name (_CID, "backlight")
							Name (_UID, 0x0A)
							Name (_STA, 0x0B)
							Method (_BCL, 0, NotSerialized)
							{
								Return (Package (0x0A)
								{
									0x4B,
									0x23,
									0x0A,
									0x19,
									0x23,
									0x32,
									0x3C,
									0x4B,
									0x5A,
									0x64
								})
							}
							Method (_BCM, 1, NotSerialized)
							{
								Name (BRIT, Buffer (0x08)
								{
									/* 0000 */	0x0A, 0x19, 0x23, 0x32, 0x3C, 0x4B, 0x5A, 0x64
								})
								Store (0x07, Local0)
								While (Local0)
								{
									Store (DerefOf (Index (BRIT, Local0)), Local1)
									If (LEqual (Arg0, Local1))
									{
										Break
									}
									Decrement (Local0)
								}
								Acquire (MUTS, 0xFFFF)
								LSMI (0xA2, Local0)
								Release (MUTS)
							}
							Method (_BQC, 0, NotSerialized)
							{
								Name (BRIT, Buffer (0x08)
								{
									/* 0000 */	0x0A, 0x19, 0x23, 0x32, 0x3C, 0x4B, 0x5A, 0x64
								})
								Acquire (MUTS, 0xFFFF)
								Store (LSMI (0xA3, Zero), Local1)
								Release (MUTS)
								Store (DerefOf (Index (BRIT, And (Local1, 0x07))), Local0)
								Return (Local0)
							}
						}
2. installed GenericBrightness.kext
After that I get brightness , but alway on 100% of brightness.
3. Added to org.chameleon.Boot.plist next keys - MacBookPro6,1 properties and system type as a notebook :
<key>device-properties</key>
	<string>e70400000100000001000000db0400001800000002010c00d041030a000000000101060000010101060000007fff0400220000004100410050004c002c0073006c006f0074002d006e0061006d00650000000a000000536c6f742d31320000004100410050004c002c006200610063006b006c0069006700680074002d0063006f006e00740072006f006c00000008000000010000002e000000400030002c004100410050004c002c0062006f006f0074002d0064006900730070006c00610079000000080000000100000022000000400030002c0064006900730070006c00610079002d00630066006700000008000000ffff36000e0000004e00560050004d00000020000000010000000000000000000000000000000000000000000000000000001c000000400030002c006200750069006c0074002d0069006e00000005000000011e00000072006f006d002d007200650076006900730069006f006e0000000a0000002042494f5300100000004e0056004300410050000000180000000400000000000100fe0000000000000a0000000022000000400030002c006400650076006900630065005f00740079007000650000000c000000646973706c617900100000006d006f00640065006c000000120000004765466f72636520473331304d0038000000400030002c007500730065002d006200610063006b006c0069006700680074002d0062006c0061006e006b0069006e0067000000040000001c000000400030002c00700077006d002d0069006e0066006f0000001c000000021800649059020008520000a51c0000000400000100000014000000400030002c006e0061006d0065000000130000004e5644412c446973706c61792d410022000000400031002c0064006900730070006c00610079002d0063006600670000000800000000ff3e0124000000400031002c00630061006e002d0068006f0074002d0070006c00750067000000040000001c0000006400650076006900630065005f0074007900700065000000100000004e5644412c506172656e740014000000400031002c006e0061006d0065000000130000004e5644412c446973706c61792d420020000000400031002c0063006f006d00700061007400690062006c00650000000f0000004e5644412c4e564d61630022000000400031002c006400650076006900630065005f00740079007000650000000c000000646973706c61790020000000400030002c0063006f006d00700061007400690062006c00650000000f0000004e5644412c4e564d61630014000000400030002c00450044004900440000008400000000ffffffffffff004ca345320000000000120100802213780a87f594574f8c2727505400000001010101010101010101010101010101411c56a0500016303020250058c2100000190000000f0000000000000000002387026401000000fe0053414d53554e470a2020202020000000fe004c544e31353641543032303030007c220000005600520041004d002c0074006f00740061006c00730069007a00650000000800000000000020360000004100410050004c002c006100750078002d0070006f007700650072002d0063006f006e006e0065006300740065006400000008000000010000002e000000400030002c006200610063006b006c0069006700680074002d0063006f006e00740072006f006c0000000800000001000000</string>
	<key>system-type</key>
	<string>2</string>
4. Change smbios.plist to MacBookPro6,1.

After that I got working brightness but my VGA display stops autodedect. How can I fix my VGA problem and delete MacBookPro6,1 key from org.chameleon.Boot.plist ?
Thanks a lot.





0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users

© 2014 InsanelyMac  |   News  |   Forum  |   Downloads  |   OSx86 Wiki  |   Mac Netbook  |   PHP hosting by CatN  |   Designed by Ed Gain  |   Logo by irfan  |   Privacy Policy