Skip to content

Commit

Permalink
New Script audio, updated CodecCommander,USBInjectAll and ALCPLUGINFIX
Browse files Browse the repository at this point in the history
  • Loading branch information
johnnynunez committed Jan 14, 2020
1 parent 53ab7f8 commit 7ee09aa
Show file tree
Hide file tree
Showing 27 changed files with 1,067 additions and 75 deletions.
Binary file modified .DS_Store
Binary file not shown.
Binary file modified ALCPlugFix_Xiaomi_Air_13_alc255Gen/.DS_Store
Binary file not shown.
Binary file modified ALCPlugFix_Xiaomi_Air_13_alc255Gen/ALCPlugFix
Binary file not shown.
Binary file added ALCPlugFix_Xiaomi_Air_13_alc255Gen/SSDT-ALC255.aml
Binary file not shown.
35 changes: 35 additions & 0 deletions ALCPlugFix_Xiaomi_Air_13_alc255Gen/SSDT-ALC255.dsl
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
DefinitionBlock ("", "SSDT", 1, "hack", "_ALC255", 0)
{
External(_SB.PCI0.HDEF, DeviceObj)
Name(_SB.PCI0.HDEF.RMCF, Package()
{
"CodecCommander", Package()
{
"Custom Commands", Package()
{
Package(){}, // signifies Array instead of Dictionary
Package()
{
// 0x19 SET_PIN_WIDGET_CONTROL 0x25
"Command", Buffer() { 0x01, 0x97, 0x07, 0x25 },
"On Init", ">y",
"On Sleep", ">n",
"On Wake", ">y",
},
Package()
{
// 0x21 SET_UNSOLICITED_ENABLE 0x83
"Command", Buffer() { 0x02, 0x17, 0x08, 0x83 },
"On Init", ">y",
"On Sleep", ">n",
"On Wake", ">y",
}
},
"Perform Reset", ">n",
"Perform Reset on External Wake", ">n", // enabled since using AppleALC
"Send Delay", 10,
"Sleep Nodes", ">n",
},
})
}
//EOF
4 changes: 2 additions & 2 deletions ALCPlugFix_Xiaomi_Air_13_alc255Gen/good.win.ALCPlugFix.plist
Original file line number Diff line number Diff line change
Expand Up @@ -8,14 +8,14 @@
<string>good.win.ALCPlugFix</string>
<key>ProgramArguments</key>
<array>
<string>/usr/bin/ALCPlugFix</string>
<string>/usr/local/bin/ALCPlugFix</string>
</array>
<key>RunAtLoad</key>
<true/>
<key>ServiceIPC</key>
<false/>
<!--Shuold be directory that hda-verb at-->
<key>WorkingDirectory</key>
<string>/usr/bin/</string>
<string>/usr/local/bin/</string>
</dict>
</plist>
14 changes: 7 additions & 7 deletions ALCPlugFix_Xiaomi_Air_13_alc255Gen/install.sh
Original file line number Diff line number Diff line change
@@ -1,18 +1,17 @@
#!/bin/bash

DAEMON_PATH=/Library/LaunchDaemons/
BIN_PATH=/usr/bin/
BIN_PATH=/usr/local/bin/
DAEMON_FILE=good.win.ALCPlugFix.plist
VERB_FILE=hda-verb
FIX_FILE=ALCPlugFix

echo "Installing ALCPlugFix. Root user is required."
echo "Installing ALCPlugFix v1.6"

# check if the root filesystem is writeable (starting with macOS 10.15 Catalina, the root filesystem is read-only by default)
if sudo test ! -w "/"; then
echo "Root filesystem is not writeable. Remounting as read-write and restarting Finder."
sudo mount -uw /
sudo killall Finder
# check if the directory "usr/local/bin" exist, if not then create the directory

if [ ! -d "$BIN_PATH" ] ; then
mkdir "$BIN_PATH" ;
fi

# stop the daemon if it's already running
Expand All @@ -22,6 +21,7 @@ if sudo launchctl list | grep --quiet ALCPlugFix; then
fi

# copy over the files to their respective locations (overwrite automatically if files exist)

sudo cp -f ALCPlugFix $BIN_PATH
sudo cp -f hda-verb $BIN_PATH
sudo cp -f good.win.ALCPlugFix.plist $DAEMON_PATH
Expand Down
2 changes: 2 additions & 0 deletions ALCPlugFix_Xiaomi_Air_13_alc255Gen/uninstall.sh
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,8 @@ sudo rm /usr/bin/hda-verb
sudo launchctl unload -w /Library/LaunchDaemons/good.win.ALCPlugFix.plist
sudo launchctl remove good.win.ALCPlugFix
sudo rm /Library/LaunchDaemons/good.win.ALCPlugFix.plist
sudo rm /usr/local/bin/ALCPlugFix
sudo rm /usr/local/bin/hda-verb

echo "Done!"
exit 0
Binary file modified EFI/.DS_Store
Binary file not shown.
Binary file modified EFI/CLOVER/.DS_Store
Binary file not shown.
Binary file modified EFI/CLOVER/kexts/.DS_Store
Binary file not shown.
100 changes: 43 additions & 57 deletions EFI/CLOVER/kexts/Other/CodecCommander.kext/Contents/Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<plist version="1.0">
<dict>
<key>BuildMachineOSBuild</key>
<string>18A391</string>
<string>19C57</string>
<key>CFBundleDevelopmentRegion</key>
<string>English</string>
<key>CFBundleExecutable</key>
Expand All @@ -19,29 +19,29 @@
<key>CFBundlePackageType</key>
<string>KEXT</string>
<key>CFBundleShortVersionString</key>
<string>2.7.1</string>
<string>2.7.2</string>
<key>CFBundleSignature</key>
<string>????</string>
<key>CFBundleSupportedPlatforms</key>
<array>
<string>MacOSX</string>
</array>
<key>CFBundleVersion</key>
<string>2.7.1</string>
<string>2.7.2</string>
<key>DTCompiler</key>
<string>com.apple.compilers.llvm.clang.1_0</string>
<key>DTPlatformBuild</key>
<string>9F2000</string>
<string>11C29</string>
<key>DTPlatformVersion</key>
<string>GM</string>
<key>DTSDKBuild</key>
<string>10M2518</string>
<string>19B90</string>
<key>DTSDKName</key>
<string>macosx10.6</string>
<string>macosx10.15</string>
<key>DTXcode</key>
<string>0941</string>
<string>1130</string>
<key>DTXcodeBuild</key>
<string>9F2000</string>
<string>11C29</string>
<key>IOKitPersonalities</key>
<dict>
<key>CodecCommander</key>
Expand All @@ -50,6 +50,10 @@
<string>org.tw.CodecCommander</string>
<key>Codec Profile</key>
<dict>
<key>1002</key>
<string>Disabled HDMI</string>
<key>10de</key>
<string>Disabled HDMI</string>
<key>10ec_0233</key>
<string>Realtek ALC283,etc</string>
<key>10ec_0235</key>
Expand All @@ -70,8 +74,6 @@
<string>Realtek ALC283,etc</string>
<key>10ec_0292</key>
<string>Realtek ALC292</string>
<key>10ec_0298</key>
<string>Realtek ALC298</string>
<key>10ec_0668</key>
<string>Realtek ALC668</string>
<key>10ec_0892_HDA_1458</key>
Expand All @@ -80,6 +82,8 @@
<string>Realtek ALC892 desktop</string>
<key>10ec_0900</key>
<string>Realtek ALC1150</string>
<key>8086</key>
<string>Disabled HDMI</string>
<key>Default</key>
<dict>
<key>Check Infinitely</key>
Expand Down Expand Up @@ -114,7 +118,9 @@
<array>
<dict>
<key>Command</key>
<data>AgUABw==</data>
<data>
AgUABw==
</data>
<key>Comment</key>
<string>0x20 SET_COEF_INDEX 0x07</string>
<key>On Init</key>
Expand All @@ -126,7 +132,9 @@
</dict>
<dict>
<key>Command</key>
<data>AgR8sA==</data>
<data>
AgR8sA==
</data>
<key>Comment</key>
<string>0x20 SET_PROC_COEF 0x7CB0</string>
<key>On Init</key>
Expand All @@ -150,7 +158,9 @@
<array>
<dict>
<key>Command</key>
<data>AVcIgw==</data>
<data>
AVcIgw==
</data>
<key>Comment</key>
<string>0x15 SET_UNSOLICITED_ENABLE 0x83</string>
<key>On Init</key>
Expand All @@ -168,7 +178,9 @@
<array>
<dict>
<key>Command</key>
<data>AVcIgw==</data>
<data>
AVcIgw==
</data>
<key>Comment</key>
<string>0x15 SET_UNSOLICITED_ENABLE 0x83</string>
<key>On Init</key>
Expand All @@ -186,7 +198,9 @@
<array>
<dict>
<key>Command</key>
<data>AhcIgw==</data>
<data>
AhcIgw==
</data>
<key>Comment</key>
<string>0x21 SET_UNSOLICITED_ENABLE 0x83</string>
<key>On Init</key>
Expand All @@ -208,7 +222,9 @@
<array>
<dict>
<key>Command</key>
<data>AZcHJQ==</data>
<data>
AZcHJQ==
</data>
<key>Comment</key>
<string>0x19 SET_PIN_WIDGET_CONTROL 0x25</string>
<key>On Init</key>
Expand All @@ -219,8 +235,6 @@
<true/>
</dict>
<dict>
<key>Command</key>
<data>AhcIgw==</data>
<key>Comment</key>
<string>0x21 SET_UNSOLICITED_ENABLE 0x83</string>
<key>On Init</key>
Expand Down Expand Up @@ -256,7 +270,9 @@
</dict>
<dict>
<key>Command</key>
<data>AVcIgw==</data>
<data>
AVcIgw==
</data>
<key>Comment</key>
<string>0x15 SET_UNSOLICITED_ENABLE 0x83</string>
<key>On Init</key>
Expand All @@ -270,49 +286,15 @@
<key>Perform Reset</key>
<false/>
</dict>
<key>Realtek ALC298</key>
<dict>
<key>Custom Commands</key>
<array>
<dict>
<key>Command</key>
<data>AYcHIg==</data>
<key>Comment</key>
<string>0x18 SET_PIN_WIDGET_CONTROL 0x22</string>
<key>On Init</key>
<true/>
<key>On Sleep</key>
<false/>
<key>On Wake</key>
<true/>
</dict>
<dict>
<key>Command</key>
<data>AhcIgw==</data>
<key>Comment</key>
<string>0x21 SET_UNSOLICITED_ENABLE 0x83</string>
<key>On Init</key>
<true/>
<key>On Sleep</key>
<false/>
<key>On Wake</key>
<true/>
</dict>
</array>
<key>Perform Reset</key>
<false/>
<key>Send Delay</key>
<integer>10</integer>
<key>Sleep Nodes</key>
<false/>
</dict>
<key>Realtek ALC668</key>
<dict>
<key>Custom Commands</key>
<array>
<dict>
<key>Command</key>
<data>AVcIgw==</data>
<data>
AVcIgw==
</data>
<key>Comment</key>
<string>0x15 SET_UNSOLICITED_ENABLE 0x83</string>
<key>On Init</key>
Expand All @@ -324,7 +306,9 @@
</dict>
<dict>
<key>Command</key>
<data>AbcHIA==</data>
<data>
AbcHIA==
</data>
<key>Comment</key>
<string>Node 0x1b - Pin Control (In Enable)</string>
<key>On Init</key>
Expand Down Expand Up @@ -459,6 +443,8 @@
<string>CodecCommanderClient</string>
</dict>
</dict>
<key>LSMinimumSystemVersion</key>
<string>10.6</string>
<key>NSHumanReadableCopyright</key>
<string>Copyright © 2013-2014 TimeWalker/RehabMan. All rights reserved.</string>
<key>OSBundleLibraries</key>
Expand Down
Binary file not shown.
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
// CodecCommander configuration for ALC1220
// provided by daliansky @github

DefinitionBlock ("", "SSDT", 1, "hack", "_ALC1220", 0)
{
External(_SB.PCI0.HDEF, DeviceObj)
Name(_SB.PCI0.HDEF.RMCF, Package()
{
"CodecCommander", Package()
{
"Custom Commands", Package()
{
Package(){}, // signifies Array instead of Dictionary
Package()
{
// 0x19 SET_PIN_WIDGET_CONTROL 0x24
"Command", Buffer() { 0x01, 0x97, 0x07, 0x24 },
"On Init", ">y",
"On Sleep", ">n",
"On Wake", ">y",
},
Package()
{
// 0x1B SET_UNSOLICITED_ENABLE 0x83
"Command", Buffer() { 0x01, 0xB7, 0x08, 0x83 },
"On Init", ">y",
"On Sleep", ">n",
"On Wake", ">y",
},
},
"Perform Reset", ">y",
//"Perform Reset on External Wake", ">n", // enable if using AppleALC
"Send Delay", 10,
"Sleep Nodes", ">n",
},
})
}
//EOF
Loading

0 comments on commit 7ee09aa

Please sign in to comment.