Contribute
Register

[solved] AC Adapter Detection and Sleep Issues on PCSpecialist Lafité II / TopStar U931

Status
Not open for further replies.
You would want something like this:
Code:
// SSDT-ACAP.dsl
//
// Some AC adapter ACPI implementations do not notify the ACPI host
// of changes to AC adapter status.
//
// This SSDT can be used to fix that by pairing with ACPIPoller.kext.
// ACPIPoller.kext will attach to this object, call FCPU each second.
// The FCPU method below, will detect changes in AC adapter status (_PSR),
// and notify the AC adapter object as needed.
//
// Note: Change the ACPI path of the AC adapter as appropriate.
//
DefinitionBlock("", "SSDT", 2, "hack", "_ACAP", 0)
{
    External(_SB.ADP1, DeviceObj)
    External(_SB.ADP1._PSR, MethodObj)
 
    Device(_SB.ADP1.ACAP)
    {
        Name(_HID, "FAN00000") // for matching with ACPIPoller.kext

        // FCPU will be executed each second by ACPIPoller.kext
        Name(LPSR, Ones)
        Method(FCPU)
        {
            Local0 = ^^_PSR()
            If (Local0 != LPSR)
            {
                LPSR = Local0
                Notify(^^, 0x80) // Notifies _SB.ADP1
            }
        }
    }
}
//EOF
Wow! :-O I'll give it a try...!
 
Last edited:
You would want something like this:
Code:
// SSDT-ACAP.dsl
//
// Some AC adapter ACPI implementations do not notify the ACPI host
// of changes to AC adapter status.
//
// This SSDT can be used to fix that by pairing with ACPIPoller.kext.
// ACPIPoller.kext will attach to this object, call FCPU each second.
// The FCPU method below, will detect changes in AC adapter status (_PSR),
// and notify the AC adapter object as needed.
//
// Note: Change the ACPI path of the AC adapter as appropriate.
//
DefinitionBlock("", "SSDT", 2, "hack", "_ACAP", 0)
{
    External(_SB.ADP1, DeviceObj)
    External(_SB.ADP1._PSR, MethodObj)
 
    Device(_SB.ADP1.ACAP)
    {
        Name(_HID, "FAN00000") // for matching with ACPIPoller.kext

        // FCPU will be executed each second by ACPIPoller.kext
        Name(LPSR, Ones)
        Method(FCPU)
        {
            Local0 = ^^_PSR()
            If (Local0 != LPSR)
            {
                LPSR = Local0
                Notify(^^, 0x80) // Notifies _SB.ADP1
            }
        }
    }
}
//EOF

Tried compiling directly in MaciASL and placing the resulting SSDT-ACAP.aml in ACPI/patched -- no change, unfortunately. Should I have made additional edits?
 
Tried compiling directly in MaciASL and placing the resulting SSDT-ACAP.aml in ACPI/patched -- no change, unfortunately. Should I have made additional edits?
No "Problem Reporting" files attached.
Read FAQ, "Problem Reporting" again. Carefully. Attach all requested files/output.
https://www.tonymacx86.com/threads/faq-read-first-laptop-frequent-questions.164990/
Use the gen_debug.sh tool mentioned in the FAQ, that way it is less likely you'll omit something.
 

Attachments

  • debug_18041.zip
    2.9 MB · Views: 57
Apologies. Please see attached.

If you open the SSDT-ACAP.aml, you can see iasl has some bugs...
This source should work around them:
Code:
// SSDT-ACAP.dsl
// 
// Some AC adapter ACPI implementations do not notify the ACPI host 
// of changes to AC adapter status.
//
// This SSDT can be used to fix that by pairing with ACPIPoller.kext.
// ACPIPoller.kext will attach to this object, call FCPU each second.
// The FCPU method below, will detect changes in AC adapter status (_PSR),
// and notify the AC adapter object as needed.
//
// Note: Change the ACPI path of the AC adapter as appropriate.
//
DefinitionBlock("", "SSDT", 2, "hack", "_ACAP", 0)
{
    External(_SB.ADP1, DeviceObj)
    External(_SB.ADP1._PSR, MethodObj)
   
    Device(_SB.ADP1.ACAP)
    {
        Name(_HID, "FAN00000") // for matching with ACPIPoller.kext

        // FCPU will be executed each second by ACPIPoller.kext
        Name(LPSR, Ones)
        Method(FCPU)
        {
            Local0 = \_SB.ADP1._PSR()
            If (Local0 != LPSR)
            {
                LPSR = Local0
                Notify(\_SB.ADP1, 0x80) // Notifies _SB.ADP1
            }
        }
    }
}
//EOF
 
If you open the SSDT-ACAP.aml, you can see iasl has some bugs...
This source should work around them:
Code:
// SSDT-ACAP.dsl
//
// Some AC adapter ACPI implementations do not notify the ACPI host
// of changes to AC adapter status.
//
// This SSDT can be used to fix that by pairing with ACPIPoller.kext.
// ACPIPoller.kext will attach to this object, call FCPU each second.
// The FCPU method below, will detect changes in AC adapter status (_PSR),
// and notify the AC adapter object as needed.
//
// Note: Change the ACPI path of the AC adapter as appropriate.
//
DefinitionBlock("", "SSDT", 2, "hack", "_ACAP", 0)
{
    External(_SB.ADP1, DeviceObj)
    External(_SB.ADP1._PSR, MethodObj)
  
    Device(_SB.ADP1.ACAP)
    {
        Name(_HID, "FAN00000") // for matching with ACPIPoller.kext

        // FCPU will be executed each second by ACPIPoller.kext
        Name(LPSR, Ones)
        Method(FCPU)
        {
            Local0 = \_SB.ADP1._PSR()
            If (Local0 != LPSR)
            {
                LPSR = Local0
                Notify(\_SB.ADP1, 0x80) // Notifies _SB.ADP1
            }
        }
    }
}
//EOF

Yep! That works perfectly now! Thank you!!!
 
Status
Not open for further replies.
Back
Top