Jump to content

AppleALC — dynamic AppleHDA patching


vit9696
5,378 posts in this topic

Recommended Posts

2 hours ago, MacPeet said:

Have you ever tried rollback AppleHDA from 10.13.3?

The following fact: On my Dell with codec AD1984A AppleALC is broken since 10.13.4. I have been working with Rollback AppleHDA since 10.13.3, also now with Mojave. Original AppleHDA and AppleALC does not work, rollback AppleHDA and current AppleALC works very well. We have not found the error so far.
Maybe you have the same problem with alc295.

Do you see the devices and can not hear anything? 

Link to comment
Share on other sites

1 hour ago, MacPeet said:

Rollback with DP6 Mojave works very well here.

 

- original AppleHDA secure against rollback (if it does not work)
- install rollback with KextUtility2.6.6
- Restart and try

I do not have any more ideas either.

 

@MacPeet

 

Many thanks for the HDA Rollback, I installed it on Mojave beta 6 and now have sound working with AppleALC 1.2.7. 

 

1378465578_Screenshot2018-08-10at16_24_32.thumb.png.f1332f2d997e5782a8551da4fe1c3cb1.png

 

With the MacOS 10.13.3 HDA RollBack installed I tried AppleALC 1.3.0 & the three test versions you sent but none of them worked (same as when using native/vanilla Mojvae AppleHDA.kext)

 

47 minutes ago, wern apfel said:

Do you see the devices and can not hear anything? 

 

With AppleALC 1.3.0 and all of the 1.3.1 versions you posted there was no audio input or output devices listed in Sys Prefs -> Sound, just grey speaker icon in menu bar.

 

Happy to keep testing beta versions and supply any debug info you or the other AppleALC devs need to get to the bottom of the issue.

At least we got a workaround until AppleALC 1.3.0+ can work correctly with ALC295 codec.

 

Cheers

Jay

 

 

Edited by jaymonkey
  • Like 1
Link to comment
Share on other sites

1 hour ago, jaymonkey said:

Happy to keep testing beta versions and supply any debug info you or the other AppleALC devs need to get to the bottom of the issue.

At least we got a workaround until AppleALC 1.3.0+ can work correctly with ALC295 codec.

 

Cheers

Jay

 

 

Save and upload an IOReg dump with non-working audio. Have you tried a patched AppleHDA to make sure it's not an AppleALC issue?

Link to comment
Share on other sites

32 minutes ago, wern apfel said:

Save and upload an IOReg dump with non-working audio

 

@wern apfel

 

Attached is ioreg from Mojave beta 6 Vanilla AppleHDA (282.10) , Lilu 1.2.6 and  AppleALC 1.3.0 (from git releases) if you want me to do the same with the test builds MacPeet sent just let me know.

 

As you can see although AppleALC is loading there is no AppleALC attached to IOResources ... ?

 

44 minutes ago, wern apfel said:

Have you tried a patched AppleHDA to make sure it's not an AppleALC issue?

 

I haven't used a binary patched AppleHDA in a very long time although i did use to use a dummyHDA kext + clover patches generated with mirone's HDA patcher until around March this year, then i switched to using AppleALC version 1.2.7 as i was already using Lilu + Whatevergreen + other Lilu plugins. AppleALC version 1.2.7 works perfect but obviously  wont work with Mojave vanilla AppleHDA due to using layout-id  3 which is no longer supported in Mojave. I tested AppleALC ver 1.3.0 and 1.2.8 on High Sierra 10.13.6, the results of those tests I posted here i also tried with three test builds from MacPeet (see posts above) on both Mojave and HS but with no success.

 

Let me know if you need any other info.

 

Cheers

Jay

Archive.zip

Link to comment
Share on other sites

1 hour ago, jaymonkey said:

 

@wern apfel

 

Attached is ioreg from Mojave beta 6 Vanilla AppleHDA (282.10) , Lilu 1.2.6 and  AppleALC 1.3.0 (from git releases) if you want me to do the same with the test builds MacPeet sent just let me know.

 

As you can see although AppleALC is loading there is no AppleALC attached to IOResources ... ?

 

 

I haven't used a binary patched AppleHDA in a very long time although i did use to use a dummyHDA kext + clover patches generated with mirone's HDA patcher until around March this year, then i switched to using AppleALC version 1.2.7 as i was already using Lilu + Whatevergreen + other Lilu plugins. AppleALC version 1.2.7 works perfect but obviously  wont work with Mojave vanilla AppleHDA due to using layout-id  3 which is no longer supported in Mojave. I tested AppleALC ver 1.3.0 and 1.2.8 on High Sierra 10.13.6, the results of those tests I posted here i also tried with three test builds from MacPeet (see posts above) on both Mojave and HS but with no success.

 

Let me know if you need any other info.

 

Cheers

Jay

Archive.zip

Ok, try it, if it does not work, I'll upload a patched Mojave AppleHDA

AppleALC.kext_v1.zip

AppleALC.kext_v2.zip

Link to comment
Share on other sites

1 hour ago, wern apfel said:

Ok, try it, if it does not work, I'll upload a patched Mojave AppleHDA

 

@wern apfel

 

Many thanks for taking a look and for the two test versions of AppleALC, unfortunately neither of them worked, same result as the release version 1.3.0 and the two versions MacPeet sent me. No sound devices in Sys Prefs -> Sound, grey speaker icon in menu bar. No AppleALC attached to IOResources in ioreg ??

 

I Uploaded a Codec Dump in this post, MacPeet processed it and provided consolidated verbs and pin config in this post,, am happy to try a patched HDA from that data if you think it will help in figuring out why AppleALC its not working.

 

Cheers

Jay

Link to comment
Share on other sites

13 hours ago, jaymonkey said:

 

@wern apfel

 

Many thanks for taking a look and for the two test versions of AppleALC, unfortunately neither of them worked, same result as the release version 1.3.0 and the two versions MacPeet sent me. No sound devices in Sys Prefs -> Sound, grey speaker icon in menu bar. No AppleALC attached to IOResources in ioreg ??

 

I Uploaded a Codec Dump in this post, MacPeet processed it and provided consolidated verbs and pin config in this post,, am happy to try a patched HDA from that data if you think it will help in figuring out why AppleALC its not working.

 

Cheers

Jay

I forgot to ask you for an IOReg dump. Change the layout-id to 4 and try it with the 10.13 AppleHDA.kext if it works try it also with the 10.14 kext.

AppleALC.kext_v3.zip

AppleALC.kext_v4.zip

Edited by wern apfel
Link to comment
Share on other sites

2 hours ago, wern apfel said:

I forgot to ask you for an IOReg dump. Change the layout-id to 4 and try it with the 10.13 AppleHDA.kext if it works try it also with the 10.14 kext.

 

Hi Wern Apfel,

 

Thanks for your post and the test files.

 

I changed my Clover config.plist to inject-id 4 as per your post :-

		<key>Audio</key>
		<dict>
			<key>AFGLowPowerState</key>
			<true/>
			<key>Inject</key>
			<integer>4</integer>
			<key>ResetHDA</key>
			<true/>
		</dict>

I then tested the two versions of AppleALC you posted on Mojave beta 6 first with AppleHDA kext from MacOS 10.13.3 and then with the Native AppleHDA included with Mojave beta 6.

Unfortunately all four tests where un-successful .... no audio input or output devices in Sys Prefs -> Sound.

I dumped the IOReg for each of the tests which are in the attached zipped archive.

 

Interestingly in all those tests the layout-id reported in the HDEF device is still 3 so not sure why that would be ? Could this be a possible issue ?

 

My understanding is that AppleALC ver 1.2.8 was the first version to support the dynamic layout-id re-mapping, when i tested that version on High Sierra it did work but the Headphones and External Mic did not work.

 

So as an experiment i tried AppleALC ver 1.2.8 on Mojave beta 6 with both the 10.13.3 & 10.14.X AppleHDA ... in both cases it worked re-mapping the layout-id to 7, Laptop Speakers, Internal Mic & Headphones worked, although i could not get it to detect the external Mic (headphones + Mic with 4 pin 3.5mm Plug).

 

I have included ioreg dumps of those tests too as i thought they could be useful as thats as near to a working ALC295 Current AppleALC release as i've been able to get.

 

Please let me know what you'd like me to test next ...

 

Cheers

Jay

 

 

Archive.zip

Edited by jaymonkey
Link to comment
Share on other sites

1 hour ago, jaymonkey said:

 

Hi Wern Apfel,

 

Thanks for your post and the test files.

 

I changed my Clover config.plist to inject-id 4 as per your post :-


		<key>Audio</key>
		<dict>
			<key>AFGLowPowerState</key>
			<true/>
			<key>Inject</key>
			<integer>4</integer>
			<key>ResetHDA</key>
			<true/>
		</dict>

I then tested the two versions of AppleALC you posted on Mojave beta 6 first with AppleHDA kext from MacOS 10.13.3 and then with the Native AppleHDA included with Mojave beta 6.

Unfortunately all four tests where un-successful .... no audio input or output devices in Sys Prefs -> Sound.

I dumped the IOReg for each of the tests which are in the attached zipped archive.

 

Interestingly in all those tests the layout-id reported in the HDEF device is still 3 so not sure why that would be ? Could this be a possible issue ?

 

My understanding is that AppleALC ver 1.2.8 was the first version to support the dynamic layout-id re-mapping, when i tested that version on High Sierra it did work but the Headphones and External Mic did not work.

 

So as an experiment i tried AppleALC ver 1.2.8 on Mojave beta 6 with both the 10.13.3 & 10.14.X AppleHDA ... in both cases it worked re-mapping the layout-id to 7, Laptop Speakers, Internal Mic & Headphones worked, although i could not get it to detect the external Mic (headphones + Mic with 4 pin 3.5mm Plug).

 

I have included ioreg dumps of those tests too as i thought they could be useful as thats as near to a working ALC295 Current AppleALC release as i've been able to get.

 

Please let me know what you'd like me to test next ...

 

Cheers

Jay

 

 

Archive.zip

You are probably using a DSDT or SSDT which overrides the layout-id of your config.plist. If so change it there.

 

Since it works with AppleALC_1.2.8 its clearly  an AppleALC issue. It seems that with AppleALC_1.3.1 layout-id remapping does not work, but you do not need it if you use layout-id 4. Make sure the layout-id is 4 and try it again with V3 and V4.

 

Does it switch to the external microphone if you plug in the headset?

Edited by wern apfel
Link to comment
Share on other sites

1 hour ago, wern apfel said:

You are probably using a DSDT or SSDT which overrides the layout-id of your config.plist. If so change it there.

 

I've quickly checked my DSDT and all the OEM SSDT's and i cant find any reference to it, I always thought Clover was its job of  injecting layout-id 3 as up until recently i have not had any issues with sound (using AppleALC ver 1.2.7) and I don't do any HDA specific ACPI patching, so this is a bit odd. Also I always thought that Clover would over ride any layout defined in the ACPI ? if defined in the config.plist..

 

1 hour ago, wern apfel said:

Since it works with AppleALC_1.2.8 its clearly  an AppleALC issue. It seems that with AppleALC_1.3.1 layout-id remapping does not work

 

Thats what i thought and what led me to report the issue to the AppleALC dev's in the first place, see this post.

 

1 hour ago, wern apfel said:

but you do not need it if you use layout-id 4. Make sure the layout-id is 4 and try it again with V3 and V4.

 

I thought AppleALC only supports native Layout-id's 3,13 & 28 for the ALC295 codec (without re-mapping) .... notice that layout 12 has been recently added to the build.

Why do you think layout-id 4 would work ?, I'm confused. I will try and sort out the injected layout-id to 4 and try again and report back.

 

1 hour ago, wern apfel said:

Does it switch to the external microphone if you plug in the headset?

 

No it does not, which is why i started looking into the pin config which MacPeet helped me with in this post, I was then going to create new custom platform and layout files as a new layout-id to submit to the devs to be included in the next release ..

 

Thanks for your help so far ...

Cheers

Jay

Edited by jaymonkey
Link to comment
Share on other sites

1 hour ago, wern apfel said:

You are probably using a DSDT or SSDT which overrides the layout-id of your config.plist. If so change it there ..... but you do not need it if you use layout-id 4. Make sure the layout-id is 4 and try it again with V3 and V4.

 

 

Ahhh yes now i remember I'm using Clover to Add Properties for HDMI Audio .... which also set's a layout-id.

 

2113169008_Screenshot2018-08-11at16_57_53.thumb.png.a4a30b099cb0fdd5e3ab6418e489eea9.png

 

Will change to 4 and try the test versions again and report back

 

Cheers

Jay

 

 

Link to comment
Share on other sites

2 hours ago, wern apfel said:

but you do not need it if you use layout-id 4. Make sure the layout-id is 4 and try it again with V3 and V4.

 

@Wern Apfel,

 

Tried AppleALC V3 and V4 with layout-id 4 against Mojave beta 6 vanilla AppleHDA (282.10) but same issue as before, no sound devices in Sys Prefs -> Sound, grey speaker icon. No AppleALC attached to IOResources.  IOREG dumps for each test in attached Archive

 

Cheers

Jay

Archive.zip

Edited by jaymonkey
Link to comment
Share on other sites

3 hours ago, jaymonkey said:

 

Thats what i thought and what led me to report the issue to the AppleALC dev's in the first place, see this post.

 

 

I thought AppleALC only supports native Layout-id's 3,13 & 28 for the ALC295 codec (without re-mapping) .... notice that layout 12 has been recently added to the build.

Why do you think layout-id 4 would work ?, I'm confused. I will try and sort out the injected layout-id to 4 and try again and report back.

 

 

No it does not, which is why i started looking into the pin config which MacPeet helped me with in this post, I was then going to create new custom platform and layout files as a new layout-id to submit to the devs to be included in the next release ..

I've not read the previous posts (because of the aggressive ads) but it seems that more codecs are affected. From all the IOReg dumps I can see that the binary patch is not working! Try to also inject "alc-layout-id"

 

Layout 4 are new resources that I've added. You can try the AppleALC_1.2.8 with layout-id 4.

AppleALC.kext_v1.2.8_layout_4.zip

Link to comment
Share on other sites

3 hours ago, wern apfel said:

Layout 4 are new resources that I've added. You can try the AppleALC_1.2.8 with layout-id 4.

 

@Wern Apfel,

 

Many thanks for the new test version .... I think we are making progress.

 

I tested the new version you posted on High Sierra 10.13.6 with vanilla AppleHDA and injecting layout-id.

 

After reboot, I get a black speaker icon and the device shows up in Sys Prefs -> Sound ...... but there is no sound out of the Speakers

If i use the volume keys i get the on-screen volume level feedback but no sound from the speakers (I have the volume change feedback sound Switched on in Sys Prefs -> Sound)

 

If I close the lid, the laptop will not Sleep ... even i i wait for 2 mins the only change is the layout-4 version of AppleALC so this must be what is stopping the system from sleeping.

However if i then re-open the lid the Sound works from the laptop Speakers, but the system will still not sleep.

 

Is it possible that the lack of sound from the Speakers on boot could be to do with the EAPD verbs on AppleALC initialisation ?
and after a lid close/open AppleALC reset's the EAPD with the wake verbs thus making the internal speakers work ?

 

Can not explain that the system does not sleep, but after re-installing AppleALC 1.2.7 the system sleeps again.

 

IOREG Dump attached

Cheers

Jay

 

 

 

 

MacOS 10.13.6 AppleALC 1.2.8 layout 4.ioreg.zip

Link to comment
Share on other sites

currently something is not right in AppleALC with the inject of some devices.
I have two computer with ALC888. Both work with last and current source without problems in all versions OSX.
Many negative messages but with lower devices ALC295, ALC 257, ....
I'm currently also at a loss.

Link to comment
Share on other sites

14 hours ago, jaymonkey said:

 

@Wern Apfel,

 

Many thanks for the new test version .... I think we are making progress.

 

I tested the new version you posted on High Sierra 10.13.6 with vanilla AppleHDA and injecting layout-id.

 

After reboot, I get a black speaker icon and the device shows up in Sys Prefs -> Sound ...... but there is no sound out of the Speakers

If i use the volume keys i get the on-screen volume level feedback but no sound from the speakers (I have the volume change feedback sound Switched on in Sys Prefs -> Sound)

 

If I close the lid, the laptop will not Sleep ... even i i wait for 2 mins the only change is the layout-4 version of AppleALC so this must be what is stopping the system from sleeping.

However if i then re-open the lid the Sound works from the laptop Speakers, but the system will still not sleep.

 

Is it possible that the lack of sound from the Speakers on boot could be to do with the EAPD verbs on AppleALC initialisation ?
and after a lid close/open AppleALC reset's the EAPD with the wake verbs thus making the internal speakers work ?

 

Can not explain that the system does not sleep, but after re-installing AppleALC 1.2.7 the system sleeps again.

 

IOREG Dump attached

Cheers

Jay

 

 

 

 

MacOS 10.13.6 AppleALC 1.2.8 layout 4.ioreg.zip

Ok, what about the microphones? 

Did you try to inject the alc-layout-id ?

Since the binary patch isn't working, let clover do it, with the latest AppleHDA and AppleALC1.3.1.

<dict>
				<key>Comment</key>
				<string>AD1984 to 10EC0295</string>
				<key>Disabled</key>
				<true/>
				<key>Find</key>
				<data>
				hBnUEQ==
				</data>
				<key>InfoPlistPatch</key>
				<false/>
				<key>Name</key>
				<string>com.apple.driver.AppleHDA</string>
				<key>Replace</key>
				<data>
				lQLsEA==
				</data>
			</dict>

BTW. the annoying ads are gone.

Link to comment
Share on other sites

2 hours ago, wern apfel said:

Ok, what about the microphones? 

Did you try to inject the alc-layout-id ?

Since the binary patch isn't working, let clover do it, with the latest AppleHDA and AppleALC1.3.1.

 

Hi Wern Apfel,

 

I tried 1.3.0 with Clover doing the binary patch and injecting alc-layout-id 3 ... same result as before, grey speaker icon, no audio devices in Sys Prefs -> Sound

 

I then tried AppleALC ver 3 & 4 that you posted with Clover binary patch and injecting alc-layout-id 4 ... same result

 

303645718_ScreenShot2018-08-12at17_15_34.thumb.png.80c2ea292962cd906905c47488fa4787.png

 

2104606923_ScreenShot2018-08-12at17_16_12.thumb.png.f0ed19f9772bd2e892878cab4342d0b0.png

 

There must be more than just the binary patch not working as in all the above tests no AppleALC was attached to IOResources in ioreg.

I think we need to wait for the AppleALC devs to fix the underlying issues with version 1.3.0+ as many users are reporting it not working.

 

ioreg dump attached (MacOS 10.13.6, Vanilla AppleALC, your AppleALC V3, Inject alc-layout-id 4)

 

Cheers

Jay

 

 

10.13.6 AppleHDA AppleALC V3 layout-id + alc-layout-id 4.ioreg.zip

  • Like 1
Link to comment
Share on other sites

On 8/13/2018 at 12:28 AM, jaymonkey said:

 

Hi Wern Apfel,

 

I tried 1.3.0 with Clover doing the binary patch and injecting alc-layout-id 3 ... same result as before, grey speaker icon, no audio devices in Sys Prefs -> Sound

 

I then tried AppleALC ver 3 & 4 that you posted with Clover binary patch and injecting alc-layout-id 4 ... same result

 

303645718_ScreenShot2018-08-12at17_15_34.thumb.png.80c2ea292962cd906905c47488fa4787.png

 

2104606923_ScreenShot2018-08-12at17_16_12.thumb.png.f0ed19f9772bd2e892878cab4342d0b0.png

 

There must be more than just the binary patch not working as in all the above tests no AppleALC was attached to IOResources in ioreg.

I think we need to wait for the AppleALC devs to fix the underlying issues with version 1.3.0+ as many users are reporting it not working.

 

ioreg dump attached (MacOS 10.13.6, Vanilla AppleALC, your AppleALC V3, Inject alc-layout-id 4)

 

Cheers

Jay

 

 

10.13.6 AppleHDA AppleALC V3 layout-id + alc-layout-id 4.ioreg.zip

Same problem with you.

 

When updated to AppleALC1.3.0+ they going to grey icon and with no output yet.

Replace to AppleALC1.2.8 there is no problem with well sound output.

 

So i dont know how AppleALC1.3.0 changes.

 

https://www.insanelymac.com/forum/topic/311293-applealc-—-dynamic-applehda-patching/?do=findComment&amp;comment=2627901

Link to comment
Share on other sites

16 hours ago, gujiangjiang said:

Same problem with you.

 

When updated to AppleALC1.3.0+ they going to grey icon and with no output yet.

Replace to AppleALC1.2.8 there is no problem with well sound output.

 

So i dont know how AppleALC1.3.0 changes.

 

@gujiangjiang

 

Yes I think many users are seeing similar issues with AppleALC 1.3.0+.

I tried the official AppleALC 1.3.1 which was released yesterday but the issue remains.

 

AppleALC 1.2.8 which has the layout-id re-mapping code works for me on both High Sierra and Mojave beta, although the external mic does not work on my laptop but this should be fixable with custom platform and layout files. Something significant must have changed in the source code between 1.2.8 and 1.3.0 which is causing AppleALC to not initialise correctly.

 

I am sure that the AppleALC devs have been made aware of this issue due to the number of users reporting the same problem and will be working on a fix for the next release.

 

Cheers

Jay

 

  • Like 2
Link to comment
Share on other sites

On 8/12/2018 at 6:28 PM, jaymonkey said:

2104606923_ScreenShot2018-08-12at17_16_12.thumb.png.f0ed19f9772bd2e892878cab4342d0b0.png

 

There must be more than just the binary patch not working as in all the above tests no AppleALC was attached to IOResources in ioreg.

I think we need to wait for the AppleALC devs to fix the underlying issues with version 1.3.0+ as many users are reporting it not working.

You're right, it's not the binary patch.

In your screenshot, the hda-gfx value is the hex value from the "onboard-1" ASCII string, but the layout-id is not. I tried that, but it does not work here.
 

As you can see in gujiangjiangs 1.3.0 log: alc @ alc-layout-id was not provided by controller at HDEF the alc-layout-id was not provided.

I suggest to using an SSDT or try it as in my screenshot, which works here only with the "alc-layout-id".

properties.png

Link to comment
Share on other sites

1 hour ago, wern apfel said:

You're right, it's not the binary patch.

In your screenshot, the hda-gfx value is the hex value from the "onboard-1" ASCII string, but the layout-id is not. I tried that, but it does not work here.

 

Setting layout-id and alc-layout-id as per my screen shot works here ... whatever i set them to is picked up by AppleALC ver 1.2.8 and is confirmed by the ioreg

I think its an accepted way of injection for those values which are necessary for HDMI audio ... RehabMan even has those as examples in his Git repo here

 

		<key>#AddProperties</key>
		<array>
			<dict>
				<key>Device</key>
				<string>IntelGFX</string>
				<key>Key</key>
				<string>hda-gfx</string>
				<key>Value</key>
				<data>b25ib2FyZC0xAA==</data>
				<key>Comment</key>
				<string>hda-gfx=onboard-1 for HDMI audio</string>
			</dict>
			<dict>
				<key>Device</key>
				<string>HDA</string>
				<key>Key</key>
				<string>hda-gfx</string>
				<key>Value</key>
				<data>b25ib2FyZC0xAA==</data>
				<key>Comment</key>
				<string>hda-gfx=onboard-1 for HDMI audio</string>
			</dict>
			<dict>
				<key>Device</key>
				<string>HDA</string>
				<key>Key</key>
				<string>layout-id</string>
				<key>Value</key>
				<data>AgAAAA==</data>
				<key>Comment</key>
				<string>layout-id=2</string>
			</dict>
			<dict>
				<key>Device</key>
				<string>HDA</string>
				<key>Key</key>
				<string>PinConfigurations</string>
				<key>Value</key>
				<data></data>
			</dict>
		</array>

 

2 hours ago, wern apfel said:

As you can see in gujiangjiangs 1.3.0 log: alc @ alc-layout-id was not provided by controller at HDEF the alc-layout-id was not provided.

I suggest to using an SSDT or try it as in my screenshot, which works here only with the "alc-layout-id".

properties.png

 

I'm familiar with this method as I use it to set custom property keys for Whatevergreen, so I guess that makes sense that the AppleALC devs might also use it  ...

 

I'll try it and see if it makes any differance ..

 

Cheers

Jay

Link to comment
Share on other sites

Hello @vit9696 and @vandroiy2012

 

I made the correction for the Asus A45A and K45 laptop. Could you please add the new id 45 layout to the ALC269VB1. The settings are:

Outputs: Integrated Internal and HP with Switch 
Input´s: Internal Mic, Line in (Fixed to Work)

Thx
 

Files Fixed ALC269 Asus A45 and K45.zip

Edited by Wolfield
Add vit9696
  • Like 1
Link to comment
Share on other sites

×
×
  • Create New...