View Single Post
 
Old 01-07-2010, 09:21 PM
excos's Avatar
excos excos is offline
 
Join Date: Jun 2009
Location: Athens
Posts: 540
Παραδειγματα για fix και τι προσθετουμε στο dsdt για να λυνει προβληματα

Code:
:Method 

(WAK, 1, NotSerialized) //WAKE up
{
\_SB.PCI0.SBRG.EC0.EC0W (Arg0)
\_SB.PCI0.NWAK (Arg0)
\_SB.PCI0.SBRG.SWAK (Arg0)
LPWK (Arg0)
Store(\_SB.ATKD.PBLG(),local0) //---> Get Brightness level from NVS
\_SB.ATKD.PBLS(local0) //---> Set Brightness level.
} 
Device (LID0)
{
Name (_HID, EisaId ("PNP0C0D")) //LID detection
Method (_PRW, 0, NotSerialized)
{
Return (Package (0x02)
{
0x0B,
0x04
})
}
Code:
Name (LIDS, One)
Method (_LID, 0, NotSerialized)
{
Store (^^PCI0.SBRG.EC0.SF13, LIDS) //LID register
XOr (LIDS, One, Local0)
IF (Local0) //if LID is closed 
{ 
Notify (SLPB, 0x80) //Set system to sleep
} 
Return (LIDS)
}
Sample code..
Code:
Method (CAMS, 1, Serialized) //Camera Set
{
Return (OCMS (Arg0))
}

Method (CAMR, 0, Serialized) //Camera toggle : added
{
Store (OCMG (), Local0)
XOr (Local0, One, Local0) 
Return (OCMS (Local0))
}

Method (CAMG, 0, Serialized) //Camera Set
{
Return (OCMG ())
}
The code above is very tell tale, it is for switching the Camera on and off.


Code:
Method (_Q2A, 0, NotSerialized) //Camera
{
^^^^ATKD.CAMR() //Toggle Camera
ATKN (0x1D) //notify ATKD
}
..................κλπ κλπ

Mac mini i5 mid 2011- Apple Cinema Display 27' /Lion 10.7.3

MacBook/MB466/A GR Aluminium late 2008 Lion 10.7.3

iPhone 4 16GB

Acer Aspire one ZG5 Snow Leopard 10.6.8

Last edited by SomniusX; 01-07-2010 at 09:38 PM.
Reply With Quote