Jump to content

VIA VT2021/2020 AppleHDA 1.0

Sign in to follow this  

About This File

=====================================================

***README*** Updated on 14th Oct 2012

=====================================================

Updated on 14th October 2012

a. Rectified a major bug in AppleHDAHardwareConfiguration.kext PinConfiguration in AppleHDA.kext

b. Updated HDEF to new one

Updated on 13th Oct 2012.

a. Rectified a minor bug with SPDIF Output.

b. Removed the use of VIA VT2021 kext

c. Added new HDEF patch

d. Enhanced AppleHDA kext

AppleHDA patch for VIA VT2021/2020 audio codecs for OS X Mountain Lion

10.8.x (Updated for 10.8.2)

Working Ports

1. Rear Green Port - Stereo Audio Output

2. Rear Pink Port - Stereo Microphone In

3. Rear Blue Port - Stereo Audio in

4. Rear SPDIF - Digital Line Out

=====================================================

1. Install AppleHDA using kext Utility

2. Patch DSDT with HDEF patch below, use it under PCI0

-----------------------------------------------------

Device (HDEF)

{

Name (_ADR, 0x001B0000)

Method (_PRW, 0, NotSerialized)

{

Return (Package (0x02)

{

0x0D,

0x05

})

}

Method (_DSM, 4, NotSerialized)

{

Store (Package (0x04)

{

"layout-id",

Buffer (0x04)

{

0x0c, 0x00, 0x00, 0x00

},

"PinConfigurations",

Buffer (0x30)

{

0x10, 0x40, 0x11, 0x01, 0xF0, 0x00, 0x00, 0x40,

0xF0, 0x00, 0x00, 0x40, 0xF0, 0x00, 0x00, 0x40,

0xF0, 0x00, 0x00, 0x40, 0xF0, 0x00, 0x00, 0x40,

0x50, 0x30, 0x81, 0x01, 0x60, 0x90, 0xA1, 0x90,

0xF0, 0x00, 0x00, 0x40, 0x20, 0x21, 0x45, 0x07,

0xF0, 0x00, 0x00, 0x40, 0xF0, 0x00, 0x00, 0x40

}

}, Local0)

DTGP (Arg0, Arg1, Arg2, Arg3, RefOf (Local0))

Return (Local0)

}

}

------------------------------------------------------




User Feedback

Recommended Comments



@borquee

Which model is ur M/b?. If the kexts didn't work, try VIA_VT2021.zip attached. That will work and includes dsdt edit for the codec

Share this comment


Link to comment
Share on other sites

Same story with me: GA-Z77-D3H-MVP / i73770k. Installed both kexts as suggested, still not a squeak from the headphone socket. Anything I've missed? Something in the BIOS perhaps?

Share this comment


Link to comment
Share on other sites

I got this working on the GA-Z77X-D3H board.

I've had to go through the advanced method.

( DSDT editor and tutorial of usage is here: http://www.olarila.com/forum/viewtopic.php?f=18&t=62 )

The simple method didn't work for me, and neither the HDEF.txt patch (at least not fully).

I was getting "DTGP" is undefined after patching the dsdt in the editor (and with this error the .aml wouldn't compile properly). After some further searches, I found the solution.

I had to add above the "Method (_WAK ...) the following function according to what's stated here on the wiki:

http://osxonthinkpads.wikidot.com/dsdt-edits#toc1

Method (DTGP, 5, NotSerialized)

{

If (LEqual (Arg0, Buffer (0x10)

{

/* 0000 */ 0xC6, 0xB7, 0xB5, 0xA0, 0x18, 0x13, 0x1C, 0x44,

/* 0008 */ 0xB0, 0xC9, 0xFE, 0x69, 0x5E, 0xAF, 0x94, 0x9B

}))

{

If (LEqual (Arg1, One))

{

If (LEqual (Arg2, Zero))

{

Store (Buffer (One)

{

0x03

}, Arg4)

Return (One)

}

If (LEqual (Arg2, One))

{

Return (One)

}

}

}

Store (Buffer (One)

{

0x00

}, Arg4)

Return (Zero)

}

If you want to look 'for inspiration purposes' into my dsdt.aml file - you can check it out here: http://cl.ly/IlXJ

I'd suggest you to avoid copy pasting it directly though even if you have the same mainboard. It's better to go through the standard procedure as documented by the original poster.

Share this comment


Link to comment
Share on other sites

Thanks, I tried this method with the following results:

I deleted the original APPLEHDA and installed the new APPLEHDA and VIA2021 using kext utility. I restart and so far so good, no panics.

I then copied the DSDT.aml you gave above into the /extra folder, restart and get a kernel panic.

I have the GA-Z77-D3H (not x, m or DS3H) on F14. Processor is the i3570 and I am using HD4000. The bios setting are on default expect SATA which is set to ACHI.

Something must be causing the kernel panic on boot with the DSDT, especially since I am running the the same motherboard. I have tried editing the DSDT manually and the sound shows up in the preference panel, however no sound comes out of the speakers...

Any ideas?

Share this comment


Link to comment
Share on other sites

@Tim182,

There's quite a difference in between Z77X and Z77 boards. Even if we both had the same exact mainboard, copy pasting the DSDT.aml wouldn't have worked (due to the differences in the devices we had plugged into the board).

That's why I recommended not to copy paste the .aml file, but instead using just to look at the end result - what fields got entered into the audio HD device, along the function that I had manually added.

Share this comment


Link to comment
Share on other sites

great job. i'm working on via vt1708s. well, i'm editing 1708s' AppleHDA according to your Drivers. Now i'm a little confused.

Why You have done this:

"sudo perl -pi -e ?s|\x83\x19\xd4\x11|\x00\x00\x00\x00|g? /System/Library/Extensions/AppleHDA.kext/Contents/MacOS/AppleHDA"

x00\x00\x00\x00 seems to be nothing...

and Now after loading my pathed applehda, there is nothing in system report.

thks.

Share this comment


Link to comment
Share on other sites

Just wanted to say keep up the good work!

Unfortunately this APPLEHDA does not seem to work under 10.8.2 anymore. Also trying to look into it

Share this comment


Link to comment
Share on other sites

Great, thanks for your help. I just managed to get it to work under 10.8.2 by simply repatching using terminal and the layout files but am still stuck with stereo.

Looking forward to the update and please let me know if I can help somehow. Also interested in getting this to work fully!

Share this comment


Link to comment
Share on other sites

@Tim

Start everything from scratch. Delete the patched AppleHDA & VT2021 kexts from S/L/E and restore the original from 10.8.2 using kext utility. Retart

Next patch AppleHDA, replace layout and platform.xml.zlib file, run kext utility and install VT2021.kext. restart

Patch DSDT.aml file with new HDEF patch (included pinconfig data). Restart. Done

For your info, I tried to make the front audio panel work, but without success. cant make front & rear mic at same time, can't get the correct path. Weird.

Anyway, I'll keep the research going and i'll update here in case of success

Share this comment


Link to comment
Share on other sites

@Nithy, wow did you really get SPDIF to work? That's amazing work! Thanks!

Can't wait to get home and test this properly!

Share this comment


Link to comment
Share on other sites

Hello,

i have a problem with optical audio...

I followed the guide properly and the green audio jack works well. in the sound panel i have Optical out but if i select it i can't ear any sound. I noticed that the optical out don't make any red light (it's like if it's not have kind of power).

any advice? thx

Share this comment


Link to comment
Share on other sites

@simothebest

Okay! thats a real bug which i figured out recently. In platforms.xml.zlib the connection patch is wrongly entered under path map id 1. I'll update it hear soon

@ Lukashan

Buddy, you no need to use the second terminal command. only d first one. The patched Audio codec in first command is Realtek 889 codec

Share this comment


Link to comment
Share on other sites

Thanks for your answer Nithy, you're awesome!

Ok so it's possible to fix that? i can have some kind of hope that my system will work, then??!

i will wait for your patch, form my personal interest can you explain what is the problem? and why for someone this guide works well and for me no? thx u man

Share this comment


Link to comment
Share on other sites

@simothebest

Updated here. Remove AppleHDA & VIA VT2021 kexts from S/L/E. Install new AppleHDA kext attached. No more VIA VT2021 kext needed. Patch the installed AppleHDA with the given command & finally use new HDEF patch attached. Done

For your info,

In platform.xml.zlib file the connection for SPDIF was wrongly entered by me. The actual connection is Node 45 (Pin) > Node 14 (Amp Output) which is now rectified

Share this comment


Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Add a comment...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.