Contribute
Register

[Guide] How to patch DSDT for working battery status

You think fresh install will help to find the problem? I did it couple times and I did even clean install and this is still happening anyway Ill back with log here soon

I can't predict the future and it depends on what you're doing in your post-install process.

You should look at system.log.
 
ill post a log file when battery status will turn off now it's working.
 
Yeah, I think it really might be some hardware problem. I will be changing my Wifi soon so when I'll open my laptop I'll check the battery adapter area.
 
I have followed the steps in order to patch my DSDT and get native battery support with your kext, but when I compile the DSDT with the patches, I get 145 compilation errors :banghead:

I think that the patch isn't completely wrong, but I can't figure what could cause all this errors

Here is the patch

Code:
# 16-bit registers
into device label H_EC code_regex BTPC,\s+16 replace_matched begin TPC0,8,TPC1,8 end;
into device label H_EC code_regex B1RA,\s+16 replace_matched begin 1RA0,8,1RA1,8 end;
into device label H_EC code_regex B1PR,\s+16 replace_matched begin 1PR0,8,1PR1,8 end;
into device label H_EC code_regex B1VO,\s+16 replace_matched begin 1VO0,8,1VO1,8 end;
into device label H_EC code_regex B1DA,\s+16 replace_matched begin 1DA0,8,1DA1,8 end;
into device label H_EC code_regex B1DF,\s+16 replace_matched begin 1DF0,8,1DF1,8 end;
into device label H_EC code_regex B1DV,\s+16 replace_matched begin 1DV0,8,1DV1,8 end;
into device label H_EC code_regex B1DL,\s+16 replace_matched begin 1DL0,8,1DL1,8 end;
into device label H_EC code_regex CYLC,\s+16 replace_matched begin YLC0,8,YLC1,8 end;


into method label B1B2 remove_entry;
into definitionblock code_regex . insert
begin
Method (B1B2, 2, NotSerialized) { Return(Or(Arg0, ShiftLeft(Arg1, 8))) }\n
end;


into method label BAT1 code_regex \BTPC\), replaceall_matched begin B1B2(TPC0,TPC1)) end;
into method label BAT1 code_regex \(B1RA, replaceall_matched begin (B1B2(1RA0,1RA1), end;
into method label BAT1 code_regex \(B1PR, replaceall_matched begin (B1B2(1PR0,1PR1), end;
into method label BAT1 code_regex \(B1VO, replaceall_matched begin (B1B2(1VO0,1VO1), end;
into method label BAT1 code_regex \(B1DA, replaceall_matched begin (B1B2(1DA0,1DA1), end;
into method label BAT1 code_regex \(B1DF, replaceall_matched begin (B1B2(1DF0,1DF1), end;
into method label _PR code_regex \(\_SB\.PCI0\.LPCB\.H_EC\.B1DF, replaceall_matched begin (B1B2(\_SB.PCI0.LPCB.H_EC.1DF0, \_SB.PCI0.LPCB.H_EC.1DF1), end;
into method label BAT1 code_regex \(B1DV, replaceall_matched begin (B1B2(1DV0,1DV1), end;
into method label BAT1 code_regex \(B1DL, replaceall_matched begin (B1B2(1DL0,1DL1), end;
into method label BAT1 code_regex \(CYLC, replaceall_matched begin (B1B2(YLC0,YLC1), end;

And the View attachment DSDT.aml
 
Back
Top