This commit is contained in:
Avery Black
2020-12-28 15:44:25 -08:00
parent 9be5c2853d
commit 423690b55c
4 changed files with 24 additions and 9 deletions

View File

@@ -2,22 +2,22 @@
* [Checking GPI0](#checking-gpio)
* [Edits to the sample SSDT](#edits-to-the-sample-ssdt)
* [Compiling the SSDT](#compiling-the-ssdt)
* [Enabling Trackpad](#enabling-trackpad)
* [Wrapping up](#wrapping-up)
## Checking GPI0
The first thing which should be checked is the GPI0 device, which is required for VoodooI2C. The best way to check this is working is to use IORegistryViewer.
The first thing which should be checked is the GPI0 device, which is required for VoodooI2C. The best way to check this is working is to use IORegistryExplorer.
![](../../images/Laptops/trackpad-md/gpio-enabled.png)
Here, we can see that VoodooGPIO is attached to GPI0 so no edits are needed for GPI0 and you can skip to the next section.
Here, we can see that VoodooGPIO is attached to GPI0 so no edits are needed for GPI0. If this is the case for you, you can skip to the [next section](#Enabling-Trackpad).
If VoodooGPIO isn't attached, then you may need to modify the `_STA` method in the `GPI0` device. In that case, you will need to find the GPI0 device in ACPI.
First open your decompiled DSDT you got from [Dumping the DSDT](/Manual/dump.md) and [Decompiling and Compiling](/Manual/compile.md) with either maciASL(if in macOS) or any other text editor if in Windows or Linux (VSCode has an [ACPI extension](https://marketplace.visualstudio.com/items?itemName=Thog.vscode-asl) that can also help).
Next search for `Device (GPI0)`. Should give you a result similar to this:
Next search for `Device (GPI0)`. You should get a result similar to this:
![](../../images/Laptops/trackpad-md/gpi0-2.png)
@@ -40,7 +40,7 @@ Method (_STA, 0, NotSerialized)
}
```
We want the value returned from _STA to be 0x0F to enable the `GPI0` device. If either `SBRG` or `GPEN` is equal to zero, then zero will be returned and `GPI0` will be disabled. Generally, `SBRG` should not be modified, as modifying it can break the `GPI0` device. Only modify the `GPEN` value if you need to enable the `GPI0` device.
We want the value returned from _STA to be 0x0F to enable the `GPI0` device. If either `SBRG` or `GPEN` is equal to zero, then zero will be returned and `GPI0` will be disabled. Generally, `SBRG` should not be modified, as modifying it can break the `GPI0` device. Only modify `GPEN` if you need to enable the `GPI0` device.
Here's some more examples:
![](../../images/Laptops/trackpad-md/gpi0.png)
@@ -87,12 +87,14 @@ If (_OSI ("Darwin"))
}
```
You will want to test the SSDT at this point by [compiling the SSDT!](/Manual/compile.md) and adding it to your config.plist. VoodooI2C should now be attached to the GPI0 device as shown at the top of the GPI0 section.
You will want to test the SSDT at this point by [compiling the SSDT](/Manual/compile.md) and adding it to your config.plist. VoodooGPIO should now be attached to the GPI0 device as shown at the top of the GPI0 section. If your trackpad still doesn't work after enabling the `GPI0` device, move on to the next section.
## Enabling Trackpad
Often times, the I2C devices check to see if they are running in Windows before enabling themselves. Similarly to the `GPI0` device, these devices contain a `_STA` method. For example, this is the I2C1 device below:
![](../../images/Laptops/trackpad-md/I2C1.png)
The part we care about is the `_STA` method:
```
@@ -132,6 +134,8 @@ There are various checks for many different versions of Windows, but there is no
**Before:**
```
External (\GPEN, FieldUnitObj)
If (_OSI ("Darwin"))
{
GPEN = One
@@ -140,6 +144,13 @@ If (_OSI ("Darwin"))
**After:**
```
// External type doesn't matter that much. If in doubt, IntObj is fine, or even UnknownObj
// FieldUnitObj as it's part of a Field Object
External (\GPEN, FieldUnitObj)
// IntObj because it's created w/ Name(OSYS, value)
External (\OSYS, IntObj)
If (_OSI ("Darwin"))
{
GPEN = One
@@ -147,7 +158,11 @@ If (_OSI ("Darwin"))
}
```
Note that Windows will also return true for checks of earlier versions of the OS. For example, Windows 7 would return true for "Windows 2000" through "Windows 2009", but not any version after. This is important as some features are only enabled in earlier Windows checks. For example, `WNTF = 0x01` allows DYTC thermal management to work on newer Thinkpads, though this only gets set in the check for "Windows 2001". You will need to check your own DSDT and see what values it sets and where they are used.
Note that Windows will also return true for checks of earlier versions of the OS. For example, Windows 7 would return true for "Windows 2000" through "Windows 2009", but not any version after. This is important as some features are only enabled in earlier Windows checks. For example, `WNTF = 0x01` allows DYTC thermal management to work on newer Thinkpads, though this only gets set in the check for "Windows 2001". You will need to check your own DSDT and see what values it sets and where they are used. At this point, you should [compile your SSDT]([compiling the SSDT](/Manual/compile.md)) and see if the trackpad works.
## Further Setup
If you need further help getting your trackpad to work, then the best place to look is [VoodooI2C's readme](https://github.com/VoodooI2C/VoodooI2C)
## Wrapping up

Binary file not shown.

View File

@@ -5,7 +5,7 @@ DefinitionBlock ("", "SSDT", 2, "DRTNIA", "XOSI", 0x00001000)
// Based off of https://docs.microsoft.com/en-us/windows-hardware/drivers/acpi/winacpi-osi
// Add OSes from the above list as needed, most only check up to Windows 2015
// but check what your DSDT looks for
Local0 = Package (0x13)
Local0 = Package ()
{
"Windows 2001",
"Windows 2001.1",

Binary file not shown.

After

Width:  |  Height:  |  Size: 453 KiB