osxfr33k Posted March 14, 2021 Share Posted March 14, 2021 Hello to all and to Emly hope to see you around again, I wanted to convert these patches meant for DSDT but port them over for OpenCore use by converting them to SSDT and I am sure conversely ACPI/Patching. Below are the 4 patches I would like to port, then I will no longer have to use DSDT. Fn Brightness Keys Patch KeyboardBacklight 16Levels Patch Battery Patch WiFi BT Boot/Sleep Status patch I have zipped them up as one attachment will this be possible to port these over to SSDT / OpenCore ACPI/Patches? Patches.zip Link to comment Share on other sites More sharing options...
Moderators Jake Lo Posted March 14, 2021 Moderators Share Posted March 14, 2021 You can't just convert them from that. You need the vanilla DSDT and the patched DSDT (make sure it works) to compare the 2 to make the SSDT. Of course the vanilla DSDT must be without error, save that and then apply the patches and then save that as a separate file. The patched DSDT should only include those patches you mentioned above. Add this DSDT to your OC install, if it work, then it's safe to compare them to make the SSDT. 1 Link to comment Share on other sites More sharing options...
osxfr33k Posted March 14, 2021 Author Share Posted March 14, 2021 sorry forgot to include them yes my DSDT is patched and working. Rehabman has a thread on the SSDT battery patching its monstrous learning. here is my patched dsdt and vanilla dsdt. I am starting simple with the FN key and 16 level keyboard brightness. Need to insert external devices, methods etc and make sure I have a rename patch in Opencore for the vanilla DSDT. DSDTs.zip Link to comment Share on other sites More sharing options...
osxfr33k Posted March 15, 2021 Author Share Posted March 15, 2021 Does the FN key patch look correct I get a compile error syntax error, unexpected '}' expecting '{'. I have the closed bracket at the end? Does this code look correct? I have already created the rename in OpenCore ACPI /Patch/Rename patch. I think I might have some External Object naming wrong but the syntax error occurs at the first IF statement line. DefinitionBlock ("", "SSDT", 2, "hack", "fnkey", 0x00000000) { External (_SB_.PCI0, DeviceObj) External (_SB_.PCI0.LPCB, DeviceObj) External (_SB_.PCI0.LPCB.EC0_, DeviceObj) External (_SB_.PCI0.LPCB.EC0_.XQ0E, MethodObj) // 0 Arguments External (_SB_.PCI0.LPCB.EC0_.XQ0F, MethodObj) // 0 Arguments External (_SB_.ATKD, DeviceObj) External (_SB_.ATKP, IntObj) Scope (_SB.PCI0.LPCB.EC0) { Method (XQ0E, 0, NotSerialized) // _Qxx: EC Query, xx=0x00-0xFF { If (ATKP) { _SB.PCI0.LPCB.ATKD.IANE (0x20) } } Method (XQ0F, 0, NotSerialized) // _Qxx: EC Query, xx=0x00-0xFF { If (ATKP) { _SB.PCI0.LPCB.ATKD.IANE (0x10) } } } } Actually I should not rename _Q0E and _Q0F in the SSDT rather in the DSDT instead I think? I found something online that was coded this was yet I still get the syntax error unexpected '{'. I am using the latest MacIASL from Acidanthera. I commented out some of the externals they did not have in their SSDT and they used \_SB. instead of _SB_. Here was the code I found online what do you think can be wrong? DefinitionBlock ("", "SSDT", 2, "hack", "fnkey", 0x00000000) { //External (_SB_.PCI0, DeviceObj) //External (_SB_.PCI0.LPCB, DeviceObj) //External (_SB_.PCI0.LPCB.EC0_, DeviceObj) //External (_SB_.PCI0.LPCB.EC0_.XQ0E, MethodObj) // 0 Arguments //External (_SB_.PCI0.LPCB.EC0_.XQ0F, MethodObj) // 0 Arguments External (\_SB.ATKD.IANE, MethodObj) External (\_SB.ATKP, IntObj) Scope (\_SB.PCI0.LPCB.EC0) { Method (_Q0E, 0, NotSerialized) // _Qxx: EC Query, xx=0x00-0xFF { If (ATKP) { \_SB.ATKD.IANE (0x20) } } Method (_Q0F, 0, NotSerialized) // _Qxx: EC Query, xx=0x00-0xFF { If (ATKP) { \_SB.ATKD.IANE (0x10) } } } } Link to comment Share on other sites More sharing options...
Moderators Jake Lo Posted March 15, 2021 Moderators Share Posted March 15, 2021 Uncomment this line on the second code should fix it //External (_SB_.PCI0.LPCB.EC0_, DeviceObj) 1 Link to comment Share on other sites More sharing options...
osxfr33k Posted March 15, 2021 Author Share Posted March 15, 2021 Thanks I just did that see below, but now I get the syntax error in a different spot where you see the arrows I drew. Does it compile for you, I am using Acidanthera MacIASL version. 1.59. DefinitionBlock ("", "SSDT", 2, "hack", "fnkey", 0x00000000) { //External (_SB_.PCI0, DeviceObj) //External (_SB_.PCI0.LPCB, DeviceObj) External (\_SB.PCI0.LPCB.EC0_, DeviceObj) //External (_SB_.PCI0.LPCB.EC0_.XQ0E, MethodObj) // 0 Arguments //External (_SB_.PCI0.LPCB.EC0_.XQ0F, MethodObj) // 0 Arguments External (\_SB.ATKD.IANE, MethodObj) External (\_SB.ATKP, IntObj) Scope (\_SB.PCI0.LPCB.EC0) { Method (_Q0E, 0, NotSerialized) // _Qxx: EC Query, xx=0x00-0xFF { If (ATKP) { \_SB.ATKD.IANE (0x20) } } >>>>> Method (_Q0F, 0, NotSerialized) // _Qxx: EC Query, xx=0x00-0xFF { If (ATKP) { \_SB.ATKD.IANE (0x10) } } } } Link to comment Share on other sites More sharing options...
Moderators Jake Lo Posted March 15, 2021 Moderators Share Posted March 15, 2021 I'm using the same version to compile without error. I set the compiler to "Stable", but no issue either with dev or legacy SSDT-fnKey.dsl.zip 1 Link to comment Share on other sites More sharing options...
osxfr33k Posted March 15, 2021 Author Share Posted March 15, 2021 That works and I see the issue look at this both in Catalina and Big Sure. Catalina using MaciASL v1.57 How in the world can something like this happen missing line numbers have a look it stops at line 22: Link to comment Share on other sites More sharing options...
Moderators Jake Lo Posted March 15, 2021 Moderators Share Posted March 15, 2021 Might be issue with your MacIASL.app. No issue on my end. I'm using 1.59 on Catalina. 1 Link to comment Share on other sites More sharing options...
Baio77 Posted March 15, 2021 Share Posted March 15, 2021 With this Kext you probably won't need any SSDT for brightness keys, you just have to test it. For Laptop Asus use This 1 Link to comment Share on other sites More sharing options...
Recommended Posts
Please sign in to comment
You will be able to leave a comment after signing in
Sign In Now