Contribute
Register

[Guide] How to patch DSDT for working battery status

Hello,

I have a HP ZBook 14 on which I recently installed OS X El Capitan and I tried your DSDT patching method but the displayed battery level is always 0% even with a fully charged battery.

I put ACPIBatteryManager.kext in EFI/Clover/kexts/10.11/ and I modified your probook generic patch to fit with my system but maybe I missed something. I attach the original and patched DSDTs as well as the patch itself. (I put the patched DSDT to /EFI/Clover/ACPI/patched and and set the DSDT name to "DSDT.aml" with Clover Configurator)

Thanks
 

Attachments

  • dsdt_battery_zbook14.zip
    149.3 KB · Views: 97
Hello,

I have a HP ZBook 14 on which I recently installed OS X El Capitan and I tried your DSDT patching method but the displayed battery level is always 0% even with a fully charged battery.

I put ACPIBatteryManager.kext in EFI/Clover/kexts/10.11/ and I modified your probook generic patch to fit with my system but maybe I missed something. I attach the original and patched DSDTs as well as the patch itself. (I put the patched DSDT to /EFI/Clover/ACPI/patched and and set the DSDT name to "DSDT.aml" with Clover Configurator)

Thanks

Read post #1, "Problem Reporting".
 
Ok, you can find everything you asked in the attached zip file (ioreg, clover, command outputs, extracted dsdt/ssdt and the patch).

Thanks for looking at this

ACPI is not patched correctly (I checked for "Darwin"... didn't find it... means lack of "OS Check Fix").

See guide: http://www.tonymacx86.com/el-capitan-laptop-support/152573-guide-patching-laptop-dsdt-ssdts.html

You should also check your system.log. I think you'll find _BIF is failing.

Also, look at ProBook specific patches: https://github.com/RehabMan/HP-ProBook-4x30s-DSDT-Patch
 
I applied an OS patch and it just removed the battery icon from the menu bar but from the preference pane I can see that the battery is still saw as empty.

It's strange because in the syslog, with ou without the OS patch, everything seems just fine (at least there is a battery capacity and the battery is given as charged):
Code:
27/03/2016 17:52:52,000 kernel[0]: ACPIBatteryManager: pollingTimeOut called27/03/2016 17:52:52,000 kernel[0]: ACPIBatteryManager: pollBatteryState: path = 1
27/03/2016 17:52:52,000 kernel[0]: ACPIBatteryManager: getBatterySTA called
27/03/2016 17:52:52,000 kernel[0]: ACPIBatteryManager: setBatterySTA: battery_status = 0x1f
27/03/2016 17:52:52,000 kernel[0]: ACPIBatteryManager: getBatteryBIF called
27/03/2016 17:52:52,000 kernel[0]: ACPIBatteryManager: validateObject return 0x0
27/03/2016 17:52:52,000 kernel[0]: ACPIBatteryManager: getBatteryBST called
27/03/2016 17:52:52,000 kernel[0]: ACPIBatteryManager: setBatteryBST: acpibat_bst size = 4
27/03/2016 17:52:52,000 kernel[0]: ACPIBatteryManager: fPowerUnit       = 0x0
27/03/2016 17:52:52,000 kernel[0]: ACPIBatteryManager: currentStatus    = 0x0
27/03/2016 17:52:52,000 kernel[0]: ACPIBatteryManager: fCurrentRate     = 0
27/03/2016 17:52:52,000 kernel[0]: ACPIBatteryManager: fCurrentCapacity = 3523
27/03/2016 17:52:52,000 kernel[0]: ACPIBatteryManager: fCurrentVoltage  = 12800
27/03/2016 17:52:52,000 kernel[0]: ACPIBatteryManager: Calculating for WATTS
27/03/2016 17:52:52,000 kernel[0]: ACPIBatteryManager: fCurrentRate(mA) = 0
27/03/2016 17:52:52,000 kernel[0]: ACPIBatteryManager: fCurrentCapacity(mAh) = 3523
27/03/2016 17:52:52,000 kernel[0]: ACPIBatteryManager: fAverageRate = 0
27/03/2016 17:52:52,000 kernel[0]: ACPIBatteryManager: Battery is charged.
27/03/2016 17:52:52,000 kernel[0]: ACPIBatteryManager: constructAppleSerialNumber called
27/03/2016 17:52:52,000 kernel[0]: ACPIBatteryManager: rebuildLegacyIOBatteryInfo called
 
I applied an OS patch and it just removed the battery icon from the menu bar but from the preference pane I can see that the battery is still saw as empty.

Read post #1, "Problem Reporting".
 
Here are the files

Why did you remove this line of code in DSDT?
Code:
    Store (PNLF, Index (Local0, One))

It is not valid to use DropOem=true without having all SSDTs (patched as required) in ACPI/patched.

Check your system.log to see which method is failing (looks like _BIF is failing or returning bad data).

Did you do EC reset?

--

Please provide complete details in your profile/signature
(Profile/Settings link in upper right corner of this site)

Mobo: manufacturer/model + bootloader(Clover/Chameleon/Chimera)
CPU: detailed CPU model + motherboard chipset
Graphics: all graphics devices + laptop internal screen resolution

For example, typical Ivy laptop:
Mobo: HP ProBook 4540s (Clover)
CPU: i5-3320m/HM76
Graphics: HD4000, 1366x768

Use CPU-Z on Windows to find CPU (Core iX-xxx) and motherboard chipset (HMxx), and graphics capabilities. For a laptop, these details are important and affect critical installation procedures.

Note: When specifying your bootloader, if using Clover legacy, please be sure to specify "Clover legacy"). Specifying "Clover" will be assumed as "Clover UEFI"
 
Why did you remove this line of code in DSDT?
Code:
    Store (PNLF, Index (Local0, One))

It is not valid to use DropOem=true without having all SSDTs (patched as required) in ACPI/patched.

Check your system.log to see which method is failing (looks like _BIF is failing or returning bad data).

Did you do EC reset?
I removed this line because I couldn't compile my DSDT with it. Since it's related to backlight control and that my backlight is working perfectly well (will Clover PNFL patch and appropriate kext) I don't think it's a big issue.

I didn't know that with DropOpem you need to provide all SSDTs so I just set it to false since there is no improvement with my generated SSDT.

In my syslog, the two kind of lines involving BIF are:
Code:
28/03/2016 09:44:05,000 kernel[0]: ACPIBatteryManager: getBatteryBIF called
28/03/2016 09:45:28,000 kernel[0]: ACPIBatteryManager: Using ACPI regular battery information method _BIF

I also tried the EC reset with no luck

Edit : It's really strange because with the power cable unplugged I have the estimated remaining time (about 3h, which makes sense for this laptop) but the percentage is always zero...
 

Attachments

  • dsdt_battery_zbook14_3.zip
    4.7 MB · Views: 93
I removed this line because I couldn't compile my DSDT with it. Since it's related to backlight control and that my backlight is working perfectly well (will Clover PNFL patch and appropriate kext) I don't think it's a big issue.

Don't remove code unless you understand why you're removing it and what it does...

I didn't know that with DropOpem you need to provide all SSDTs so I just set it to false since there is no improvement with my generated SSDT.

It is in the guide: http://www.tonymacx86.com/el-capitan-laptop-support/152573-guide-patching-laptop-dsdt-ssdts.html

In my syslog, the two kind of lines involving BIF are:
Code:
28/03/2016 09:44:05,000 kernel[0]: ACPIBatteryManager: getBatteryBIF called
28/03/2016 09:45:28,000 kernel[0]: ACPIBatteryManager: Using ACPI regular battery information method _BIF

Check for all output from ACPIBatteryManager.

Edit : It's really strange because with the power cable unplugged I have the estimated remaining time (about 3h, which makes sense for this laptop) but the percentage is always zero...

The percentage is zero because the capacities are not being read correctly in _BIF.
 
Back
Top