27.10.2015 Views

Advanced Configuration and Power Interface Specification

ACPI_6.0

ACPI_6.0

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

ACPI-Defined Devices <strong>and</strong> Device-Specific Objects<br />

9.19.3 Example<br />

Device(BTNS)<br />

{<br />

Name(_HID, “ACPI0011”)<br />

Name(_CRS, ResourceTemplate() {<br />

GpioInt(Edge, ActiveBoth…) {pin} //Vol Down<br />

GpioInt(Edge, ActiveBoth…) {pin} //Vol Up<br />

GpioInt(Edge, ActiveBoth,…) {pin} //<strong>Power</strong> (MUST BE<br />

//ACTIVEBOTH!)<br />

})<br />

Name(_DSD, Package(2) {<br />

//UUID for HID Button Descriptors:<br />

ToUUID(“FA6BD625-9CE8-470D-A2C7-B3CA36C4282E”),<br />

//Data structure for this UUID:<br />

Package() {<br />

Package(5) {<br />

0, //Declare a Collection<br />

1, //Unique ID for this collection<br />

0, //It is a top-level collection<br />

0x0c,//Usage Page (“Consumer”)<br />

0x01 //Usage (“Consumer Control”)<br />

},<br />

Package(5) {<br />

0, //Declare another Collection<br />

2, //Unique ID for this collection<br />

0, //Also a top-level collection<br />

0x01,// Usage Page (”Generic Desktop”)<br />

0x80 //Usage (“System Control”)<br />

},<br />

Package(5) {<br />

1, //Declare a Control<br />

0, //Interrupt index in _CRS for Vol Down<br />

1, //In the “Consumer Control” collection<br />

0x0c,//Usage Page (“Consumer”)<br />

0xEA //Usage (“Volume Decrement”)<br />

},<br />

Package(5) {<br />

1, //Declare another Control<br />

2, //Interrupt index for the <strong>Power</strong> Button<br />

2, //In the “System Control” collection<br />

0x01,//Usage Page (”Generic Desktop”)<br />

0x81 //Usage (“System <strong>Power</strong> Down”)<br />

},<br />

Package(5) {<br />

1, //Declare another Control<br />

1, //Interrupt index for the Vol Up button<br />

1, //In the “Consumer Control” collection<br />

0x0c,//Usage Page (“Consumer”)<br />

0xE9 //Usage (“Volume Increment”)<br />

},<br />

Package(5) {<br />

1, //Another Control<br />

0xFF,//No Interrupt for this one… e.g. OS-<br />

// specific signaling for Rotation Lock<br />

1, //In the “Consumer Control” collection<br />

0x0C,//Usage Page (“Consumer”)<br />

0x245 //Usage (“AC Rotate”)<br />

}<br />

}<br />

})<br />

Version 6.0 555

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!