How to patch DSDT for working battery status
Your DSDT is returning an incorrect value in this case. Debug/analyse _BST method to determine why.
This is the method
Method (_BST, 0, NotSerialized) // _BST: Battery Status
{
If (^^PCI0.LPCB.EC.ECOK)
{
UPBS ()
}
Else
{
IVBS ()
}
Return (PBST)
}
And UPBS and IVBS
Method (UPBS, 0, NotSerialized)
{
If (^^PCI0.LPCB.EC.BAT0)
{
Store (Zero, Local0)
Store (Zero, Local1)
If (^^PCI0.LPCB.EC.ADP)
{
If (LEqual (And (B1B4 (^^PCI0.LPCB.EC.ST00, ^^PCI0.LPCB.EC.ST01, ^^PCI0.LPCB.EC.ST02, ^^PCI0.LPCB.EC.ST03), 0x02),
0x02))
{
Or (Local0, 0x02, Local0)
And (B1B4 (^^PCI0.LPCB.EC.PR00, ^^PCI0.LPCB.EC.PR01, ^^PCI0.LPCB.EC.PR02, ^^PCI0.LPCB.EC.PR03), 0xFFFF, Local1)
}
}
Else
{
Or (Local0, One, Local0)
And (B1B4 (^^PCI0.LPCB.EC.PR00, ^^PCI0.LPCB.EC.PR01, ^^PCI0.LPCB.EC.PR02, ^^PCI0.LPCB.EC.PR03), 0xFFFF, Local1)
}
And (Local1, 0x8000, Local7)
If (LEqual (Local7, 0x8000))
{
Store (0xFFFFFFFF, Local1)
}
And (B1B4 (^^PCI0.LPCB.EC.RC00, ^^PCI0.LPCB.EC.RC01, ^^PCI0.LPCB.EC.RC02, ^^PCI0.LPCB.EC.RC03), 0xFFFF, Local2)
And (B1B4 (^^PCI0.LPCB.EC.PV00, ^^PCI0.LPCB.EC.PV01, ^^PCI0.LPCB.EC.PV02, ^^PCI0.LPCB.EC.PV03), 0xFFFF, Local3)
Store (Local0, Index (PBST, Zero))
Store (Local1, Index (PBST, One))
Store (Local2, Index (PBST, 0x02))
Store (Local3, Index (PBST, 0x03))
If (LNotEqual (BFCC, B1B4 (^^PCI0.LPCB.EC.FC00, ^^PCI0.LPCB.EC.FC01, ^^PCI0.LPCB.EC.FC02, ^^PCI0.LPCB.EC.FC03)))
{
Notify (BAT0, 0x81)
}
}
Else
{
IVBS ()
}
Method (IVBS, 0, NotSerialized)
{
Store (Zero, Index (PBST, Zero))
Store (0xFFFFFFFF, Index (PBST, One))
Store (0xFFFFFFFF, Index (PBST, 0x02))
Store (0x2710, Index (PBST, 0x03))
}
Here is the 0xFFFFFFFF value
should i replace it or erase it all?
Not a clue, i got here by asking for help and trying to repeat what others already did. I'm not saying i'll give up. On the contrary i keep working and learning all i can to improve and challenge myself.
Thanks for encouraging everybody, its very important thing to do
I CAME into this (from acpi.info)
|
|
|
|
|
|
BatteryPresentRate
|
Integer
(DWORD)
|
Returns the power or current being supplied or accepted through the battery’sterminals (direction depends on the Battery State value). The Battery PresentRate value is expressed as power [mWh] or current [mAh] depending on thePower Unit value.
Batteries that are rechargeable and are in the discharging state are required toreturn a valid Battery Present Rate value.
• 0x00000000 – 0x7FFFFFFF in [mW] or [mA]
0xFFFFFFFF – Unknown rate
|
BatteryRemainingCapacity
|
Integer
(DWORD)
|
Returns the estimated remaining battery capacity. The Battery RemainingCapacity value is expressed as power [mWh] or current [mAh] depending on thePower Unit value.
Batteries that are rechargeable are required to return a valid Battery RemainingCapacity value.
- 0x00000000 – 0x7FFFFFFF in [mWh] or [mAh]
- 0xFFFFFFFF – Unknown capacity
|
BatteryPresentVoltage
|
Integer
(DWORD)
|
Returns the voltage across the battery’s terminals.
Batteries that are rechargeable must report Battery Present Voltage.
- 0x000000000 – 0x7FFFFFFF in [mV]
- 0xFFFFFFFF – Unknown voltage
Note: Only a primary battery can report unknown voltage.
|