Skip to content

Commit

Permalink
Update battery status section (#81)
Browse files Browse the repository at this point in the history
Co-authored-by: Dhinak G <[email protected]>
Co-authored-by: Avery Black <[email protected]>
  • Loading branch information
3 people authored Aug 23, 2021
1 parent e9b284b commit bc7a25c
Showing 1 changed file with 38 additions and 2 deletions.
40 changes: 38 additions & 2 deletions laptop-specific/battery.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,40 @@
# Battery Patching
# Battery Status

While at the moment battery patching is not something covered in this guide, we'll at least point you to some helpful resources and add some useful notes for when using them in OpenCore.
With [ECEnabler.kext](https://github.com/1Revenger1/ECEnabler/releases/latest), ACPI patching is no longer required for working battery percentage. If you would like battery functionality beyond charge percentage (e.g. cycle count, or temperature/other supplemental data) or have dual batteries, you still will need to create ACPI patches - see the resources below.

* If battery status is not working even with ECEnabler, make sure you have the [SMCBatteryManager](https://github.com/Acidanthera/VirtualSMC/releases/latest) VirtualSMC plugin enabled in your OpenCore configuration.

* Certain devices, such as the Surface 3, Surface Pro 5, Surface Book 2, and Surface Laptop (and all subsequent Surface devices), use proprietary Embedded Controllers (or other similar hardware) instead of standard ACPI battery devices and OperationRegion fields, and thus without device-specific kexts, battery status cannot work.

::: details Battery Patching Resources

* Note: If you are using the ECEnabler kext, you do not need to split EC fields as shown in the guides below. This means that you can use the field names in your DSDT directly instead of through utility methods (e.g. `B1B2`, `B1B4`, `RE1B`, and `RECB`).

## Dual Battery

Because macOS does not properly support systems with dual batteries, you have to merge the two batteries in ACPI.

Refer to the VirtualSMC documentation for information on how to handle dual-battery laptops: [Link](https://github.com/acidanthera/VirtualSMC/blob/master/Docs/Dual%20Battery%20Support.md)

## Cycle Count

Some laptop vendors, such as HP, already supply cycle count information. However, their firmwares either do not implement or expose it within the `_BIX` method. In the past, Rehabman's ACPIBatteryManager employed a hack to support cycle counts on firmwares which do not have a `_BIX` method, however with SMCBatteryManager this is no longer supported.

Refer to the VirtualSMC documentation for information on how to transition from the ACPIBatteryManager cycle count hack to a proper `_BIX` method implementation: [Link](https://github.com/acidanthera/VirtualSMC/blob/master/Docs/Transition%20from%20zprood%27s%20cycle%20count%20hack.md)

The documentation may also prove useful for those implementing cycle count for the first time rather than transitioning from the ACPIBatteryManager cycle count hack.

## Battery Information Supplement

Although many laptops supply supplemental battery information (e.g. manufacture date and battery temperature) in their EC fields, the traditional `_BIF`, `_BIX`, and `_BST` ACPI methods do not support providing this information. Thus, SMCBatteryManager supports two ACPI methods, `CBIS` and `CBSS` to provide this information to macOS.

Refer to the VirtualSMC documentation for information on how to implement these methods: [Link](https://github.com/acidanthera/VirtualSMC/blob/master/Docs/Battery%20Information%20Supplement.md)

:::

::: details Legacy Patching Resources

* Note: Rehabman's guides say to use ACPIBatteryManager, you must use SMCBatteryManager instead.

## DSDT Patching

Expand All @@ -19,3 +53,5 @@ Once you've finally gotten your DSDT patched and battery working in macOS, it's
**[Rehabman's Guide to Using Clover to "hotpatch" ACPI](https://www.tonymacx86.com/threads/guide-using-clover-to-hotpatch-acpi.200137/)**

* Note: Specifically post #2 refers to battery hot-patching

:::

0 comments on commit bc7a25c

Please sign in to comment.