Zprood Posted December 5, 2011 Author Share Posted December 5, 2011 Zprood, Thank you for all the work you have done on this. I am having real difficulty trying to identify exactly how to modify my DSDT for this. The machine is a lenovo G570. I'd really appreciate it if you could take a look. Many thanks for your time. Try this one:dsdt_fix.aml.zip Link to comment Share on other sites More sharing options...
paulicat Posted December 6, 2011 Share Posted December 6, 2011 Excellent work! Worked perfectly for my Acer 8735, now its a complete 18.3" monster macbook pro clone! Thanks for your hard work! Link to comment Share on other sites More sharing options...
MiniHack Posted December 6, 2011 Share Posted December 6, 2011 Try this one:dsdt_fix.aml.zip Thank you Zprood. The register conversion had been defeating me - I can now see where I went wrong. Your DSDT fix works very well and lets me use the Lion ACPI kext. Again, many thanks. Link to comment Share on other sites More sharing options...
bisk Posted December 6, 2011 Share Posted December 6, 2011 Working perfectly on Gateway NV57H (i5/2410m) ! The 8 bit variable conversion routines simplify it all down to little more than a basic search & replace op. VoodooBattery lives again Well done !!! Link to comment Share on other sites More sharing options...
3dpro Posted December 8, 2011 Share Posted December 8, 2011 Hi everyone, Having some problem with the 8 bit conversion method. It got AppleSmartBatteryManager kernel panic when I used my modified DSDT. I think I already changed all the registry like the guide. Please someone take a look at my DSDT. Thanks in advance! DSDT-Z470.zip Link to comment Share on other sites More sharing options...
loKEY Posted December 8, 2011 Share Posted December 8, 2011 Hi Zprood, i've tried a bunch and really just can't figure this out on my dsdt. i'd really appreciate it if you could take a look. it's a samsung laptop. thank you for your time and all the work you've done . dsdt.aml.zip Link to comment Share on other sites More sharing options...
CyberWalrus Posted December 10, 2011 Share Posted December 10, 2011 Hi all, I have been trying to get battery working without Voodoobattery on my sony vaio SA. I have tried to implement this method myself, but lots of my stuff seems very different, and I cant work out how it should go together. I would appreciate any help that anyone can give. My dsdt is attached DSDT.zip Link to comment Share on other sites More sharing options...
gothic860 Posted December 10, 2011 Share Posted December 10, 2011 Hey, i have a Lenovo Thinkpad W520 and i think everything works fine (without DSDT edit...) but i don't get a cycle count. Any idea? I have tried the DSDT edit but i can't find some of the stuff i have to edit / add. Hope someone can help me here a little bit. Thanks! dsdt.aml.zip Link to comment Share on other sites More sharing options...
flip360 Posted December 26, 2011 Share Posted December 26, 2011 Hi Zprood, Thanks for the kexts and the dsdt fix for a working battery in Lion Fixed it now have correct readings from battery in system info and statusbar Cheers and Thanks Link to comment Share on other sites More sharing options...
sebern Posted December 31, 2011 Share Posted December 31, 2011 Zprood, I try to integrate your fix in my DSDT, but didn't find the right point to replace 16 bit to 8 bit with your method in my HP/Compaq DSDT. Tried it several times, but was not able to compile it. Maybe you (or someone else) can point me to the right direction. Thanks. Regards, Sebastian DSDT.aml.zip Link to comment Share on other sites More sharing options...
sebern Posted January 1, 2012 Share Posted January 1, 2012 Zprood, I try again to fix my DSDT and now I was able to integrate your fix and compile DSDT with no errors . I can now use good old VoodooBattery with Lion ACPIPlatform kext instead of SL ones to get battery status. Thanks for providing and sharing such a solution. I attached my fixed DSDT, maybe helpful for someone. Happy new year, Sebastian DSDT_b1b2.aml.zip Link to comment Share on other sites More sharing options...
smartie77 Posted January 1, 2012 Share Posted January 1, 2012 Hi, I have a Toshiba Laptop which works great with Snow and Lion ; The DSDT is fixed for almost everything working like usb,sleep,hpet,lpc and so on and tested over months usage with no problems; OSX works problem-free with SMBIOS of MacBookPro5.1 ( Core2Duo Speedstep vanilla ) but this Battery Thing with Lion is the last open issue for me. My BAT1 Entries in DSDT look very different from your example code and I don't want to mess my otherwise working file. Can you figure out what I need to change in order to have working battery kexts in Lion with original apple acpi and pci kexts ( I don't want to mix Snow and Lion files ). Thanks The complete dsdt that I use in OSX is attached as file. Here only Battery section : Device (BAT1) { Name (_HID, EisaId ("PNP0C0A")) Name (_UID, One) Name (_PCL, Package (0x01) { _SB }) Name (BMDL, Zero) Method (_STA, 0, NotSerialized) { If (ECOK ()) { If (^^EC0.BAL0) { Sleep (0x14) Return (0x1F) } Else { Sleep (0x14) Return (0x0F) } } Else { Sleep (0x14) Return (0x1F) } } Method (_BIF, 0, NotSerialized) { Name (STAT, Package (0x0D) { One, 0x1770, 0x1770, One, 0x2A30, 0x0258, 0xB4, 0x0108, 0x0EC4, "PA3533U ", "41167", "Li-Ion", "TOSHIBA" }) Name (CMMA, Buffer (0x0C) {}) CreateByteField (CMMA, Zero, APN1) CreateByteField (CMMA, One, APN2) CreateByteField (CMMA, 0x02, APN3) CreateByteField (CMMA, 0x03, APN4) CreateByteField (CMMA, 0x04, APN5) CreateByteField (CMMA, 0x05, APN6) CreateByteField (CMMA, 0x06, APN7) CreateByteField (CMMA, 0x07, APN8) CreateByteField (CMMA, 0x08, APN9) CreateByteField (CMMA, 0x09, Z00A) CreateByteField (CMMA, 0x0A, Z00B) CreateByteField (CMMA, 0x0B, Z00C) Store (PHMR (0xACF8), APN1) Store (PHMR (0xADF8), APN2) Store (PHMR (0xAEF8), APN3) Store (PHMR (0xAFF8), APN4) Store (PHMR (0xB0F8), APN5) Store (PHMR (0xB1F8), APN6) Store (PHMR (0xB2F8), APN7) Store (PHMR (0xB3F8), APN8) Store (PHMR (0xB4F8), APN9) Store (PHMR (0xB5F8), Z00A) Store (PHMR (0xB6F8), Z00B) Store (PHMR (0xB7F8), Z00C) Store (CMMA, Index (STAT, 0x09)) If (ECOK ()) { Store (^^EC0.BDN0, Local0) Store (Local0, BMDL) Store (^^EC0.BFC0, BFC1) Sleep (0x14) Store (^^EC0.BDC0, Index (STAT, One)) Sleep (0x14) Store (^^EC0.BDV0, Index (STAT, 0x04)) Sleep (0x14) } Else { Store ("Li-Ion", Index (STAT, 0x0B)) Store (BFC1, Index (STAT, One)) } If (BFC1) { Divide (BFC1, 0x64, Local0, Local1) Multiply (Local1, 0x0A, Local1) Store (Local1, Index (STAT, 0x05)) Divide (BFC1, 0x64, Local0, Local1) Multiply (Local1, 0x03, Local1) Store (Local1, Index (STAT, 0x06)) Store (BFC1, Index (STAT, 0x02)) } Return (STAT) } Method (_BST, 0, NotSerialized) { Name (PBST, Package (0x04) { Zero, 0xFFFFFFFF, 0xFFFFFFFF, 0x2A30 }) Store (0x2A30, Local3) If (ECOK ()) { Sleep (0x14) Store (^^EC0.BST0, BST1) Sleep (0x14) Store (^^EC0.BRC0, Local2) Sleep (0x14) Store (^^EC0.BPV0, Local3) Sleep (0x14) } Store (BST1, Index (PBST, Zero)) Store (Zero, Index (PBST, One)) Store (Local2, Index (PBST, 0x02)) Store (Local3, Index (PBST, 0x03)) If (ECOK ()) { If (LNotEqual (^^EC0.BDN0, BMDL)) { Notify (BAT1, 0x81) } } Return (PBST) } } Device (DMAC) { Name (_HID, EisaId ("PNP0200")) Name (_CRS, ResourceTemplate () { IO (Decode16, 0x0000, // Range Minimum 0x0000, // Range Maximum 0x01, // Alignment 0x20, // Length ) IO (Decode16, 0x0081, // Range Minimum 0x0081, // Range Maximum 0x01, // Alignment 0x11, // Length ) IO (Decode16, 0x0093, // Range Minimum 0x0093, // Range Maximum 0x01, // Alignment 0x0D, // Length ) IO (Decode16, 0x00C0, // Range Minimum 0x00C0, // Range Maximum 0x01, // Alignment 0x20, // Length ) DMA (Compatibility, NotBusMaster, Transfer8_16, ) {4} }) } dsdt.aml.zip Link to comment Share on other sites More sharing options...
LIMITER Posted January 5, 2012 Share Posted January 5, 2012 Hello, Attached is the original and patched (fully working) DSDT for Lenovo B550 (G550?). dsdt.aml.zip dsdt-batteryfix.aml.zip Thanks to all that made this awesome driver and to Zprood for the great tutorial !!! Link to comment Share on other sites More sharing options...
flip360 Posted January 18, 2012 Share Posted January 18, 2012 I created a complete dsl instruction file of all the edits I did to get SmartBatteryManager working on Lion for my Asus M60J, but should be applicable to all the Asus Core i3/i5/i7 notebooks. From what I've seen so far, all the Asus Core i notebooks have identical battery dsdt. The Lion dsdt edits instruction file is at the bottom of my post# 95 in glsy's thread under the name Asus_Coreix_Lion_Edits. I have also included a full dsdt of my Asus M60J on Lion in case they don't understand a particular instruction. http://www.insanelym...dpost&p=1771830 Thanks for the instructions buddy, working battery here at last Cheers Link to comment Share on other sites More sharing options...
Neo_01 Posted January 22, 2012 Share Posted January 22, 2012 I attach my DSDT file I'm not an expert someone could please patch the file. Thanks DSDT.zip Link to comment Share on other sites More sharing options...
Neo_01 Posted January 24, 2012 Share Posted January 24, 2012 I attach my DSDT file I'm not an expert someone could please patch the file. Thanks Sorry, Could you please help me to patch the file? Thanks in advice Link to comment Share on other sites More sharing options...
Neo_01 Posted January 27, 2012 Share Posted January 27, 2012 Sorry, Could you please help me to patch the file? Thanks in advice Could you please indicate me what I have to do?? Thanks Link to comment Share on other sites More sharing options...
Neo_01 Posted January 28, 2012 Share Posted January 28, 2012 I attach the dsdt file modified according the indications but the compiler show me a lot of errors could you please help me. Thanks DSDT_FIXED.aml.zip Link to comment Share on other sites More sharing options...
Micky1979 Posted February 11, 2012 Share Posted February 11, 2012 First Of All, Thanks these people for the battery driver:Chun-Nan, zenglg1977, gsly, bcc9, VIVXIX, weizh126. Cause without what they do can't get it work.Now start the topic. Since apple changes some things on lion, the Appleacpibatterymanager does't work any more under the Lion, so people use roll backed next to get is work, but this has shortage. At the first, bcc9 found that lion reads battery info from EC by 8bit, and most laptop's EC region use 16bit to store battery information, so the legacy driver doesn't work include voodoo battery. This information is important for next. The guy zenglg1977 takes some time to rewrite the sources code of Appleacpibatterymanager to make it work for lion. It is needed to edit the code of battery in the dsdt, so divide 16bit register into two 8bit can make sense. Like: Before // Field (RAM, ByteAcc, Lock, Preserve) { Offset (0xE0), BSDC, 16, BSDV, 16, BSSN, 16 } // Later // Field (RAM, ByteAcc, Lock, Preserve) { Offset (0xE0), SDC0, 8, SDC1, 8, SDV0, 8, SDV1, 8, SSN0, 8, SSN1, 8 } // then, the transmit part can be done like this: For example: Before: Multiply (BSDC, 0x0A, Local1) Later: Multiply (SDC1, 0x100, Local1) Add (SDC0, Local1, Local1) Multiply (Local1, 0x0A, Local1) Before: Store (BSDC, Local1) Later: Multiply (SDC1, 0x100, Local1) Add (SDC0, Local1, Local1) This way created by zenglg1977, after done with this can make it work. But when compare VIVXIX with others method, i found his method is simple and easy to reach, it named "B1B2". Here is his method: 1, create the "Method (B1B2, 2, NotSerialized)" as global: Method (B1B2, 2, NotSerialized) { Or (ShiftLeft(Arg1,0x08), Arg0, Local0) Return (Local0) } //for 16bit Method (B1B4, 4, NotSerialized) { Or (ShiftLeft(Arg1,0x08), Arg0, Local0) Or (ShiftLeft(Arg2,0x10), Local0, Local0) Or (ShiftLeft(Arg3,0x18), Local0, Local0) Return (Local0) } //for 32bit Method (L1L4, 4, NotSerialized)//32*4=128 { Or (ShiftLeft(Arg1,0x20), Arg0, Local0) Or (ShiftLeft(Arg2,0x40), Local0, Local0) Or (ShiftLeft(Arg3,0x60), Local0, Local0) Return (Local0) }//for 128bit 2, change the 16bit register into two 8bit register, like: //BPV0, SPV0, 8, SPV1, 8, 3, here is some collections of example editing work he finished before. A: //Store (^^EC0.BAC0, Local5) Store (B1B2(^^EC0.SAC0,^^EC0.SAC1), Local5) B: //Store (^^EC0.BDC0, Index (STAT, One)) Store (B1B2(^^EC0.SDC0,^^EC0.SDC1), Index (STAT, One)) C: //Multiply (BGU1, BFC1 ,Local2) Multiply (BGU1, B1B2 (BFC0, BFC1), Local2) Some special parts as below: D: //If (^^EC0.BDC0 ) If (B1B2(^^EC0.SDC0,^^EC0.SDC1)) E: //If (LGreater (^^EC0.BAC0, 0xFB00)) If (LGreater (B1B2(^^EC0.SAC0,^^EC0.SAC1), 0xFB00) F: //Store (^^EC0.BDC0, BFC1) Store (^^EC0.SDC1, BFC1) Sleep (0x14) Store (^^EC0.SDC0, BFC0) More about the sources code, zenglg1977 combines gsly's AppleSmartBatteryManger code into whole project, then people get two choice. And weizh126 plays a trick about battery cycle count in the _BIF method part, the _BIF just contains 13 items in the package and he adds "Zero" to it become 14, and store the cycle count register info in it, it sounds illegal, but it works. Last, here is the sources code and attachments. AppleBatteryManager_src.zip AppleACPIBatteryManager.kext.zip AppleSmartBatteryManager.kext.zip Also screenshots: Original link address: http://bbs.pcbeta.co...935509-1-1.html http://bbs.pcbeta.co...935582-1-1.html Hello Zprood, I am having trouble getting the patch to the battery and the LID, can you help me? I attach dsdt dsdt.aml.zip Link to comment Share on other sites More sharing options...
jazzyguy Posted February 19, 2012 Share Posted February 19, 2012 Out of curiosity, how are we supposed to know which items need to be turned into 8 bit? Link to comment Share on other sites More sharing options...
xmen107 Posted March 4, 2012 Share Posted March 4, 2012 Ok, sorry my mistake, now tested on Snow Leopard and both work well without making alterations in my dsdt. Thank you for your excellent work. In Lion did not work for me, I do not know why, but ok. Link to comment Share on other sites More sharing options...
joe2108 Posted March 20, 2012 Share Posted March 20, 2012 I'm still confuse with this DSDT fix cause no line in my DSDT like that, could you patch my dsdt, thanks before DSDT Vostro 3350DSDT.aml.zip Link to comment Share on other sites More sharing options...
ludacrisvp Posted March 22, 2012 Share Posted March 22, 2012 You may be interested to know that voodoo battery works perfectly out of the box on mountain lion dp1 on the same laptop that had lion battery issues. I did not fix my dsdt for lion. Link to comment Share on other sites More sharing options...
chinmaya__swarup Posted April 1, 2012 Share Posted April 1, 2012 Try this one:dsdt_fix.aml.zip @Zprood i have successfully edited my DSDT, converted registers to 8 bit, battery is being detected, but not properly. i have attached screenshots and my dsdt. Problem is that i am getting 1. Charge Remaining wrong figures 2. Amperes remaining in -ve figures 3. Battery at 20:00 remaining at full charge. Please help me to rectify these errors. Thanks in advance. DSDTx.aml.zip Link to comment Share on other sites More sharing options...
vlad.s Posted April 18, 2012 Share Posted April 18, 2012 Hello, I have a Lenovo Ideapad Y560 i7. I tried to apply this battery patch to my dsdt but it looks different thank the one in the example. Could someone please take a look and help me? Thank you! dsdt.zip 1 Link to comment Share on other sites More sharing options...
Recommended Posts