Jump to content

UPDATED 20.12. GenericBrightness.kext


ivik
 Share

674 posts in this topic

Recommended Posts

@The King & ivik

I think this website may be helpful.

AhgAZJBZAgAIUgAApRwAAAAEAAABAAAA

is base64, and in hex it is

02 18 00 64 90 59 02 00 08 52 00 00 a5 1c 00 00 00 04 00 00 01 00 00 00

Did you at least bother to read what I asked?

ivik did and I got my reply...

 

Injecting {censored} w/o to know what it does is called brainless hackintoshing...

Link to comment
Share on other sites

Did you at least bother to read what I asked?

ivik did and I got my reply...

 

Injecting {censored} w/o to know what it does is called brainless hackintoshing...

Hey 'THe KiNG'

 

While you sitting there, maybe have a pint ?

and don't be so serious

Link to comment
Share on other sites

Injecting {censored} w/o to know what it does is called brainless hackintoshing...

 

Hi,

Adding pwm-info key with values from MacBookPro6,1 (and other stuff) helped me to get brightness working natively.

I got it from MBP6,1 because i have a same gfx (GT 330M). Do you know if that values are correct for me or can you help to calculate correct values?

I noticed relation to lcd panel's vendor/product ID. ApplePanelA (AppleBacklight.kext) is linked to PNLF but in real MBP6,1 is AppleGraphicsControlBacklight. I can't manage to change this. Made LegacyAppleBacklight with my lcd panel's productID and can put my own brightness values. Tried LegacyAppleGraphicsControlBacklight in same way but it didn't load.

The EDID key values i copied from my IODisplayEDID key but don't know it's realy needed. Last key doing troubles for me is NVMT, i can't find correct values for it and don't know it's also needed.

Link to comment
Share on other sites

While you sitting there, maybe have a pint ?

and don't be so serious

Sure, a pint no, a hint maybe... :(

 

Hi,

Adding pwm-info key with values from MacBookPro6,1 (and other stuff) helped me to get brightness working natively.

I got it from MBP6,1 because i have a same gfx (GT 330M). Do you know if that values are correct for me or can you help to calculate correct values?

I noticed relation to lcd panel's vendor/product ID. ApplePanelA (AppleBacklight.kext) is linked to PNLF but in real MBP6,1 is AppleGraphicsControlBacklight. I can't manage to change this. Made LegacyAppleBacklight with my lcd panel's productID and can put my own brightness values. Tried LegacyAppleGraphicsControlBacklight in same way but it didn't load.

The EDID key values i copied from my IODisplayEDID key but don't know it's realy needed. Last key doing troubles for me is NVMT, i can't find correct values for it and don't know it's also needed.

You are lucky to match what Apple needs and maybe you have one of the supported Apple displays.

pwm-info is clear related to monitor, but I dunno how to calculate it and was the reason for asking.

NVMT is nVidia monitor timings, we have some clue about it but not full, more info you can find from fassl HERE

If you get the EDID automate filled(I don't as most of us) that means you are lucky with compatible hardware, and you can inject it as real EFI firmware does.

I tried to inject custom EDID but Apple driver ignore it, so I had to flash it on display eeprom to see what happen, I even flashed original Apple EDID since my monitor is close to what Apple use on macbookair3,1 (mine is LP116WH2-TLC1 and Apple is LP116WH4-TPA1) and got same result as before I can move the slider and that's it. Only diff with hacked/Apple EDID is that now it loads Apple color profile much better then default, and I got ApplePanelTable on PNLF .

 

I have brightness control with embedded controller help, I did this only to find out how Apple does it, for the sake of knowledge..

 

@ivik

 

I saw you modified ps2 driver for function keys assignment, maybe you have a clue in my case:

// scancodes from running showkey -s (under Linux) for extra keys on keyboard

// HP Mini 311

case 0xd4: keyCode = 0x7a; break; // E054 E0D4 = Brightness Up

//case 0x54: keyCode = 0x7a; break; // E054 E0D4 = Brightness Up

case 0xcc: keyCode = 0x7b; break; // E04C E0CC = Brightness Down

//case 0x4c: keyCode = 0x7b; break; // E04C E0CC = Brightness Down

As you can see my keyboard has 2 extended scancode for each Fn instead one, I tried to map them one by one w/o result, any idea how to fix this?

I could map the keys that has just one extended scancode just fine but not original keys that has 2.

Link to comment
Share on other sites

You are lucky to match what Apple needs and maybe you have one of the supported Apple displays.

pwm-info is clear related to monitor, but I dunno how to calculate it and was the reason for asking.

NVMT is nVidia monitor timings, we have some clue about it but not full, more info you can find from fassl HERE

If you get the EDID automate filled(I don't as most of us) that means you are lucky with compatible hardware, and you can inject it as real EFI firmware does.

I tried to inject custom EDID but Apple driver ignore it, so I had to flash it on display eeprom to see what happen, I even flashed original Apple EDID since my monitor is close to what Apple use on macbookair3,1 (mine is LP116WH2-TLC1 and Apple is LP116WH4-TPA1) and got same result as before I can move the slider and that's it. Only diff with hacked/Apple EDID is that now it loads Apple color profile much better then default, and I got ApplePanelTable on PNLF .

 

I have brightness control with embedded controller help, I did this only to find out how Apple does it, for the sake of knowledge..

Thanks THe KiNG for a very instructive explanation.

Also as you i get ApplePanelTable under PNLF device but if i use LegacyAppleBacklight containing my lcd panel's productID key in ApplePanels dict. For the start copied into it values from MBP6,1 panel's key. Don't know how to get AppleGraphicsControlBacklight loaded instead of AppleBacklight like in real MBP6,1. Maybe changing/injecting panel's vendor/product IDs resolve it? But how/where? Flashing eeprom? Not prefer (don't know how).

Link to comment
Share on other sites

I finally managed to compile VoodooPS2 32/64 bit.

AppleACPIPS2Nub.kext must also be installed.

GenericBrightness is also updated, since i missed one index.

 

Mapped keys are for these vendors:

acer
up e04e e059 e06e
down e06f

dell
up e006
down e005

hp
up e017
down e012

lg
up e078
down e077

samsung
up e008
down e009

 

Hi,

Tied it on my Samsung, only first use of Fn+Arrow caused SUN appeared, next do nothing.

Link to comment
Share on other sites

@king

 

I mapped e012/e017=>down/up. This is all i could find for HP.

http://cgit.freedesktop.org/hal-info/tree/...0-keymap-hp.fdi

 

You scancodes look like normal press/release event:

 

E054= key is pressed down, release= E0 (0x54+0x80) = E0D4 => brightness up

and

E04C= key is pressed down, release= E0 (0x4C+0x80) = E0CC => brightness down.

 

Do you get 4 events? 2 for press, and 2 for release?

Maybe it could be fixed like in pause or printscreen. Just skip them.

Link to comment
Share on other sites

Do you get 4 events? 2 for press, and 2 for release?

Maybe it could be fixed like in pause or printscreen. Just skip them.

No, When I press/release Fn+F3 I get: 0xE0 0x4C 0xE0 0xCC => Brightness Down

When I press/release Fn+F4 I get: 0xE0 0x54 0xE0 0xD4 => Brightness Up

 

I will look on Pause/Prt Sc stuff...

 

Thanks!

Link to comment
Share on other sites

Another try for dell and samsung: :/

Great! Brightness controll by Fn+Up/Down arrows and Fn+F12/Pause Brk (Insert) now works ^_^

Fn+F9 works like BrtnUP :( , Fn+F6 toggles sound (as should), Fn+F10 toggles touchpad (as should), Fn+L/R arrows controlls sound (as should), can use num keypad only with pressed Fn key down. :(

Thanks for your great work.

BTW. Would you like to make Fn+Fxx keys to work like real MacBook too?

 

Doesn't remember brightness level after reboot.

 

EDIT: First use of Fn+F10 causes brightness down to 0, next works ok.

Link to comment
Share on other sites

It looks like samsung FN+F9 has same scancode as some other laptop brightness up.

 

Got 2 confirmations that it works on Samsung. Waiting for dell. I think it has same issue like samsung.

Don't know if LG isuers have stuck keys also...

 

EDIT: samsung FN+F10 = E077 => LG brightness up...

Maybe should I add option to plist for keyboard mapping per laptop..

Link to comment
Share on other sites

I resolve my issue with the kext is not started. Dunno why. After numerous changes and reverts it works.

I am fully satisfied with my Dell. Brightness works with Fn+Scroll/Pause (Sun on the screen) and with slider in Display prefPane.

 

I can't do it for Samsung with Tiger :)

1. To make Tiger version of GenericBrightness.kext I exclude joinPMtree(). It panics.

2. To make AppleBacklightDisplay I have to rebuild IOGraphicsFamily because it checks i2c connection that my display has no.

3. Deadend. With my ATIRadeon9000 I have no good framebuffer, only Callisto that has functional restrictions. There are no Calibration and Brightness through the driver.

 

About ApplePanelA. It was Opensource in past, but now I can't find it at Apple's site.

class ApplePanelA : public ApplePanel
{
OSDeclareDefaultStructors(ApplePanelA);

enum { kApplePanelLevels = 128 };

AppleDisplays_1151.0.0.tar.gz

Link to comment
Share on other sites

@Slice

 

http://www.insanelymac.com/forum/index.php...t&p=1582781

If you use your acpimonitor, you could have brightness with dsdt only.

Sure, I have brightness by Fn+Up/Down. I just want to see a Sun and slider in prefPane. It absents while AppleBacklight is loaded and AppleBacklightDisplay is connected to display.

Link to comment
Share on other sites

Not that.. without my driver. You could check from dsdt if brightness is changed (slider). And then call _BCM method.

I'm not using any driver for brightness now. Your acpimonitor calls SMCA method, in it i also check if brightness is changed and set hardware brightness and return temperature.

Link to comment
Share on other sites

@ivik,

could you please show the sources of the menu-let app. It is the only thing that works for me (All.zip package). Remember my complain about brightness up/down. I'd like to know how the menu-let manages it.

In a fail to have a windows os installed (as of now), I cannot get rw-everything values. I'd contact some friends with same mobo and get back to you.

Link to comment
Share on other sites

@ivik,

would it be possible to give the menu-let app more keyboard/trackpad control ? Maybe by relying on key press + trackpad slider, could make it more attractive to the rest of us. what do u think ?

Link to comment
Share on other sites

but i don't know how.

neither do I. But what if you do same thing you done to get the hotkey (alt-Q) for exiting the menu-let.

Thus declaring an new hotkey for set_brightness. Then one could edit the trackpad.prefpane to add something like the one for zooming.

For me, honestly, this sounds Chinese.

Link to comment
Share on other sites

 Share

×
×
  • Create New...