Jump to content
5410 posts in this topic

Recommended Posts

Thank you for your help @MacPeet I will test later today.

I recently got the laptop back from my wife, (and it is for sale and could leave my hands any moment), but before that happened I just wanted to see if I could fix that long standing audio muting issue, and I did, and since the rest of the config "worked" with a bit of sleep, (the built in mic worked, the HP worked, the speaker worked, and the headset line-in worked after wake or issuing the pin switch command using alcverb)

 

I knew it was not ideal to PR but it was 1000 times better than what we had before, and I was afraid I wouldn't get a chance to keep testing further, and at least that way It would possibly help someone down the line. As luck would have it, the laptop is still home, and with your help we can hopefully figure the input side and leave a 100% working solution.

 

  • Like 1
3 hours ago, MacPeet said:

Try this with ID15 ManualMode and ID16 SwitchMode!

 

Archiv.zip 1.68 MB · 1 download

 

ID15 = nothing, no inputs, no outputs

ID16 = only internal mic works, headset/line in never appears | speaker/headphone switch/sound ok

Sorry, my mistake.

ID15 should work now too.

This is a trial for HP Elite X2 G3.

With ID12 in the release, the speakers break after 2 minutes in battery mode, with my trials everything was fine.

Combination sockets in switch mode are often difficult.

 

Archiv.zip

2 hours ago, MacPeet said:

Sorry, my mistake.

ID15 should work now too.

This is a trial for HP Elite X2 G3.

With ID12 in the release, the speakers break after 2 minutes in battery mode, with my trials everything was fine.

Combination sockets in switch mode are often difficult.

 

Archiv.zip 1.68 MB · 1 download

 

ID15 = only internal mic works, headset/line in never appears | speaker and headphone sound ok no autoswitch

ID16 = only internal mic works, headset/line in never appears | speaker (no sound) /headphone (ok) autoswitch ok

 

This codec is very frustrating, everything happens internally and there is no indication (other than working/not working) as to how to set inputs/outputs beyond the obvious, but that doesn't really work, so some switching must occur when plug detect happens and the inputs reconfigure internally. the way it kinda works is by letting the pins map, and then switching using vref so it is now an input, and somehow the routing works, so it is internally patched, like the speaker out. but if we do that before appleHDA maps the pins, then the node is disabled. I just installed Catalina and I'm trying VoodoHDA and see if it can give some insight into how the headset mic works, but by default both mics are plugged to the same input node 19, so the headset node is disabled at boot by voodoohda. I'll try to patch it so internal mic defaults to node 20 and maybe voodoohda will give us a clue.

Edited by theroadw
more info added

Thank you for your effort.

 

Edit:

 

@theroadw

 

The user with HP Elite X2 G3 has now tested your pull request, it works well. He had problems with ID12. Your ID14 is better. 👍

Edited by MacPeet
  • Like 1

I have done extensive testing and just can't figure out why the node can't be in the correct state on boot AND be recognized by MacOS.

The workaround is simple enough, to have a shell script execute "alcverb 0x19 0x707 0x24" on boot, or perform a sleep/wake cycle.

Everything else works, and I can't put more time into this.

16 hours ago, theroadw said:

Everything else works, and I can't put more time into this.

 

It's not necessary. The important devices work. Other users can continue to develop. Thank you for your efforts.

1 hour ago, MacPeet said:

 

It's not necessary. The important devices work. Other users can continue to develop. Thank you for your efforts.

Thanks @MacPeet for your help.

 

For future development, I found that the conexant codecs are similar across many models in the linux driver, so my layout may work on many other CX codecs.

 

https://github.com/torvalds/linux/blob/master/sound/pci/hda/patch_conexant.c

 

Also an autoswitch program like ALCPlugFix could help with automatic input select using the patches from the above llnk.

Linux is not macOS. Some things are often different or cannot be configured that way.
I'm not a big fan of VoodooHDA, even if it often works there, but a lot of things have to be set up correctly and the quality is often worse. I've often looked at VoodooHDA dumps, but it's not always possible for macOS.
I'm also not a big fan of additional ALCPlugFix.
On my Lenovo there was an ID28, which only had noise on HP. ALCPlugFix seems to have fixed this, but then I developed a manual mode where everything worked without ALCPlugFix.
All in all, these combo sockets are just difficult. In the past, with a separate socket, this was never a problem.

5 hours ago, MacPeet said:

@theroadw

 

If you haven't sold yet...
With SwitchMode inputs 19-26 and 19-25, Line-In is displayed.
The boost entries may still be too high or unnecessary.

 

 

 

 

 

@MacPeet you are a genius!

 

Adjusted my layout to use node 19 on both inputs and it works perfectly, also added the vref node to pinconfigs, everything works! if headphones are plugged, internal mic stays on, if headset is plugged, mic switches to line input and sound is correct. Audio out works perfectly in headphones/headset and speakers and also across sleep/wake and battery power. So I would call this a 100% solution.

My quicktime audio test recordings using both inputs sound ok, so I left the boost as it was.

 

Thank you!

Edited by theroadw
  • Like 2
  • 2 weeks later...

Hello, I was hoping to get some help adding a new laptop to be supported with Apple ALC

I have the following information:

 

1. Laptop model/Motherboard model

Razer Blade 16 (2024)

 

2. Codec name

ALC0298

\FUNC_01&VEN_10EC&DEV_0298&SUBSYS_1A58300A&REV_1001\5&14f0b3c4&0&0001

 

3. Layout used with the info what works for you (ideally if you try them all)

I have tried all, and have had no luck

 

4. OS X versions you tried

14.1.1 (23B81)

 

5. Autogenerated Info.plist made with the help of this utility.
I have included it here.


I realize this info to include was on page 1 and now we are on page 216, so there might be more information that I need to share. Please let me know what I can do.

Thanks for the help
 

Info.plist

  • 5 months later...

Hi, I have a problem with AppleALC and my ALC1150 audio device. The motherboard is an ASUS RAMPAGE V EDITION 10. MacOS Ventura.

AppleALC is loaded correctly because in IORegistry the audio device is automatically renamed to HDEF and the AppleHDAController and IOHDACodecDevice entries appear, only that the latter is empty.

I tried to set alcid among the boot arguments with all the layouts suggested by the wiki, without success.

I also entered the SSDT-HPET for IRQ conflict resolution...

Can anyone help me??

Thanks!

On 12/10/2024 at 12:22 PM, verdazil said:

@NeXtor, test Method 2.1: Patching with SSDT-HPET_RTC_TIMR-fix, look at https://github.com/5T33Z0/OC-Little-Translated/tree/main/01_Adding_missing_Devices_and_enabling_Features/IRQ_and_Timer_Fix_(SSDT-HPET)

This method helped me in a similar situation.

 

I followed the guide but without success. I managed to get the sound card to work by disabling VT-D in the bios but with VT-D disabled (I tried all combinations with DisableIOMapper, dart=0, etc...) Ventura freezes a few seconds after starting.

2 hours ago, verdazil said:

Have you edited the SSDT-HPET_RTC_TIMR-fix Table according to your DSDT?

 

I tried again and I saw that it doesn't deactivate HPET but creates HPE0. In IORegistry I have both HPET and HPE0

 

This is my ORIGINAL RTC-TMR-HPET from DSDT:

Device (RTC)
{
    Name (_HID, EisaId ("PNP0B00") /* AT Real-Time Clock */)  // _HID: Hardware ID
    Name (_CRS, ResourceTemplate ()  // _CRS: Current Resource Settings
    {
        IO (Decode16,
            0x0070,             // Range Minimum
            0x0070,             // Range Maximum
            0x01,               // Alignment
            0x02,               // Length
            )
        IO (Decode16,
            0x0074,             // Range Minimum
            0x0074,             // Range Maximum
            0x01,               // Alignment
            0x04,               // Length
            )
        IRQNoFlags ()
            {8}
    })
}

Device (TMR)
{
    Name (_HID, EisaId ("PNP0100") /* PC-class System Timer */)  // _HID: Hardware ID
    Name (_CRS, ResourceTemplate ()  // _CRS: Current Resource Settings
    {
        IO (Decode16,
            0x0040,             // Range Minimum
            0x0040,             // Range Maximum
            0x01,               // Alignment
            0x04,               // Length
            )
        IO (Decode16,
            0x0050,             // Range Minimum
            0x0050,             // Range Maximum
            0x01,               // Alignment
            0x04,               // Length
            )
        IRQNoFlags ()
            {0}
    })
}

Device (HPET)
{
    Name (_HID, EisaId ("PNP0103") /* HPET System Timer */)  // _HID: Hardware ID
    OperationRegion (HPTC, SystemMemory, 0xFED1F404, 0x04)
    Field (HPTC, DWordAcc, NoLock, Preserve)
    {
        HPTS,   2, 
            ,   5, 
        HPTE,   1, 
        Offset (0x04)
    }

    Method (_STA, 0, NotSerialized)  // _STA: Status
    {
        If (HPTE)
        {
            Return (0x0F)
        }
        Else
        {
            Return (0x00)
        }
    }

    Name (CRS0, ResourceTemplate ()
    {
        Memory32Fixed (ReadWrite,
            0xFED00000,         // Address Base
            0x00000400,         // Address Length
            )
    })
    Name (CRS1, ResourceTemplate ()
    {
        Memory32Fixed (ReadWrite,
            0xFED01000,         // Address Base
            0x00000400,         // Address Length
            )
    })
    Name (CRS2, ResourceTemplate ()
    {
        Memory32Fixed (ReadWrite,
            0xFED02000,         // Address Base
            0x00000400,         // Address Length
            )
    })
    Name (CRS3, ResourceTemplate ()
    {
        Memory32Fixed (ReadWrite,
            0xFED03000,         // Address Base
            0x00000400,         // Address Length
            )
    })
    Method (_CRS, 0, Serialized)  // _CRS: Current Resource Settings
    {
        Switch (ToInteger (HPTS))
        {
            Case (0x00)
            {
                Return (CRS0) /* \_SB_.PCI0.LPC0.HPET.CRS0 */
            }
            Case (0x01)
            {
                Return (CRS1) /* \_SB_.PCI0.LPC0.HPET.CRS1 */
            }
            Case (0x02)
            {
                Return (CRS2) /* \_SB_.PCI0.LPC0.HPET.CRS2 */
            }
            Case (0x03)
            {
                Return (CRS3) /* \_SB_.PCI0.LPC0.HPET.CRS3 */
            }

        }

        Return (CRS0) /* \_SB_.PCI0.LPC0.HPET.CRS0 */
    }
}

 

This is SSDT-HPET_RTC_TIMR-fix.aml:

DefinitionBlock ("", "SSDT", 2, "OCLT", "HRTfix", 0x00000000)
{
    External (_SB_.PCI0.LPC0, DeviceObj)
    External (_SB_.PCI0.LPC0.RTC_, DeviceObj)
    External (_SB_.PCI0.LPC0.TMR_, DeviceObj)
    External (HPTE, IntObj)

    Scope (\)
    {
        If (_OSI ("Darwin"))
        {
            HPTE = Zero
        }
    }

    Scope (_SB.PCI0.LPC0.RTC)
    {
        Method (_STA, 0, NotSerialized)  // _STA: Status
        {
            If (_OSI ("Darwin"))
            {
                Return (Zero)
            }
            Else
            {
                Return (0x0F)
            }
        }
    }

    Scope (_SB.PCI0.LPC0.TMR)
    {
        Method (_STA, 0, NotSerialized)  // _STA: Status
        {
            If (_OSI ("Darwin"))
            {
                Return (Zero)
            }
            Else
            {
                Return (0x0F)
            }
        }
    }

    Scope (_SB.PCI0.LPC0)
    {
        Device (HPE0)
        {
            Name (_HID, EisaId ("PNP0103") /* HPET System Timer */)  // _HID: Hardware ID
            Name (_UID, Zero)  // _UID: Unique ID
            Name (BUF0, ResourceTemplate ()
            {
                IRQNoFlags ()
                    {0,8}
                Memory32Fixed (ReadWrite,
                    0xFED00000,         // Address Base
                    0x00000400,         // Address Length
                    )
            })
            Method (_STA, 0, NotSerialized)  // _STA: Status
            {
                If (_OSI ("Darwin"))
                {
                    Return (0x0F)
                }
                Else
                {
                    Return (Zero)
                }
            }

            Method (_CRS, 0, Serialized)  // _CRS: Current Resource Settings
            {
                Return (BUF0) /* \_SB_.PCI0.LPC0.HPE0.BUF0 */
            }
        }

        Device (RTC0)
        {
            Name (_HID, EisaId ("PNP0B00") /* AT Real-Time Clock */)  // _HID: Hardware ID
            Name (_CRS, ResourceTemplate ()  // _CRS: Current Resource Settings
            {
                IO (Decode16,
                    0x0070,             // Range Minimum
                    0x0070,             // Range Maximum
                    0x01,               // Alignment
                    0x02,               // Length
                    )
                IO (Decode16,
                    0x0074,             // Range Minimum
                    0x0074,             // Range Maximum
                    0x01,               // Alignment
                    0x04,               // Length
                    )
            })
            Method (_STA, 0, NotSerialized)  // _STA: Status
            {
                If (_OSI ("Darwin"))
                {
                    Return (0x0F)
                }
                Else
                {
                    Return (Zero)
                }
            }
        }

        Device (TMR0)
        {
            Name (_HID, EisaId ("PNP0100") /* PC-class System Timer */)  // _HID: Hardware ID
            Name (_CRS, ResourceTemplate ()  // _CRS: Current Resource Settings
            {
                IO (Decode16,
                    0x0040,             // Range Minimum
                    0x0040,             // Range Maximum
                    0x01,               // Alignment
                    0x04,               // Length
                    )
                IO (Decode16,
                    0x0050,             // Range Minimum
                    0x0050,             // Range Maximum
                    0x01,               // Alignment
                    0x04,               // Length
                    )
            })
            Method (_STA, 0, NotSerialized)  // _STA: Status
            {
                If (_OSI ("Darwin"))
                {
                    Return (0x0F)
                }
                Else
                {
                    Return (Zero)
                }
            }
        }
    }
}

 

2 hours ago, verdazil said:

Edit the SSDT-HPET_RTC_TIMR-fix Table according to your DSDT!

Remove old sound settings from the bootloader - HPET Table and patches.

 

 

I disabled HPET, now it no longer appears in IORegistry but into boot log I have (AppleHPET) HPET: probeHPET() failed, instead HPE0 appears with IRQs 0-8-11 in IOInterruptSpecifiers, but I still don't have HDEF working.
In ACPI Patch I only have "change Method(GPRW,2,N) to XPRW, pair with SSDT-GPRW.aml".

Boot-args: debug=0x100 alcid=7 npci=0x2000 agdpmod=pikera -v

alcid=7 works with VT-D disabled

Edited by NeXtor

I only use SSDT, without DSDT. What I don't understand is why with all these fixes and patches it doesn't work and if I remove everything related to HPET and with vt-d disabled instead it works even though it makes the operating system unusable because it freezes immediately (another strange thing). If it can help I can post the entire EFI folder...

On 12/10/2024 at 1:56 AM, NeXtor said:

Can anyone help me??

I once had an Asus x99m board, I suffered for a long time, I couldn't get the built-in audio, the sound appeared only after enabling the Above 4G Decoding parameter in the BIOS. Try it - maybe your case?

@ANTIKOI always keep it enabled, but I also tried disabling it and it doesn't solve the problem.

 

@MaLd0nwhat do you suggest? any help is appreciated!! could it be some conflict between peripherals? I don't know, also for this reason I was asking if it could be useful to examine the configuration and the efi folder...help me

 

@verdazilthank you so much for your help, i really appreciate it. if you can think of anything else, i'm ready to try

  • 3 weeks later...

Hello,

 

Can someone have a look on this linux codec dump?

 

1. Laptop model/Motherboard model

HP Zbook Fury 15 G7

 

2. Codec name

ALC285

 

3. Layout used with the info what works for you (ideally if you try them all)

11 > Audio device detected but no speakers, no mic

21 > Audio device detected but no speakers, no mic

31 > Audio device detected but no speakers, no mic

33 > Speakers OK, no mic

52 > Audio device detected but no speakers, no mic

61 > Audio device detected but no speakers, no mic

66 > Speakers OK no mic

71 > Speakers OK, no mic

88 > Audio device detected but no speakers, no mic

 

4. OS X versions you tried

macOS Sonoma 14.7.2 (23H311)

macOS Sequoia 15.3 (24D5034f)

 

5. Autogenerated Info.plist made with the help of this utility.
 Attachment not available on applelife.ru (404 file not found)

 

Thanks and an happy new year to everyone! 🥳

 

linux_dump.txt

@polyzargone according to your laptop's manual, you have a mute key for the internal microphone. Did the internal mic work when you dumped the codec? I only see an external mic listed, though I’m not very familiar with configuring combo jacks.

×
×
  • Create New...