Trying to convert the remaining two references to 8-bit, SBDC and SBDV, using the technique
described here by Zprood. Unfortunately, I just can't quite figure this out, as it's not working like the others--I get compile errors.
FIrst
SBDC. Original code has 4 references:
Field (ECOR, ByteAcc, NoLock, Preserve)
{
Offset (0xA0),
SBDC, 16,
…
Method (GBIF, 3, NotSerialized)
{
…
If (Local7)
{
Multiply (SBDC, 0x0A, Local0)
}
Else
{
Store (SBDC, Local0)
}
...
Method (SBDC, 1, NotSerialized)
{
If (And (Arg0, 0x02))
{
BPWC (0x01)
}
Else
{
BPWC (0x00)
}
If (And (Arg0, 0x04))
{
Or (WGFL, 0x40, WGFL)
\BLTH (0x02)
}
Else
{
And (WGFL, Not (0x40), WGFL)
\BLTH (0x03)
}
}
I tried changing it to make it like the other edits, using the B1B2 Method
Field (ECOR, ByteAcc, NoLock, Preserve)
{
Offset (0xA0),
//SBDC, 16,
BDC0, 8,
BDC1, 8,
…
If (Local7)
{
//Multiply (SBDC, 0x0A, Local0)
Multiply (B1B2 (BDC0, BDC1), 0x0A, Local0)
}
Else
{
//Store (SBDC, Local0)
Store (B1B2 (BDC0, BDC1), Local0)
}
(Not sure what to do with Method (
SBDC...)
Second is
SBDV. This object occurs 4 times in the original code as well
Field (ECOR, ByteAcc, NoLock, Preserve)
{
Offset (0xA0),
SBDC, 16,
SBDV, 16,
…
Method (GBIF, 3, NotSerialized)
...
Else
{
If (SBDV)
{
Divide (0x00030D40, SBDV, Local2, Index (Arg1, 0x06))
}
Else
{
Store (0x00, Index (Arg1, 0x06))
}
}
…
Store (SBDV, Index (Arg1, 0x04))
Tried replacing it with this:
Field (ECOR, ByteAcc, NoLock, Preserve)
{
Offset (0xA0),
SBDC, 16,
//SBDV, 16,
BDV0, 8,
BDV1, 8,
…
Method (GBIF, 3, NotSerialized)
...
Else
{
//If (SBDV)
If (B1B2 (BDV0, BDV1))
{
//Divide (0x00030D40, SBDV, Local2, Index (Arg1, 0x06))
Divide (0x00030D40, B1B2 (BDV0, BDV1), Local2, Index (Arg1, 0x06))
}
Else
{
Store (0x00, Index (Arg1, 0x06))
}
}
…
//Store (SBDV, Index (Arg1, 0x04))
Store (B1B2 (BDV0, BDV1), Index (Arg1, 0x04))
Followed the format of the other fixes, but these ones create compile errors. B1B2 Method is defined further up in the DSDT file.
Thanks, any help is appreciated. Attached is the DSDT that won't compile, and a version without any battery related edits.