Jump to content

ATI AC 97 Sounds (SB400) effort


Andras Kenez
 Share

696 posts in this topic

Recommended Posts

For those also attempting to code this driver:

 

here's what I've got so far.....swap this file with the one from scousi's download, compile, and then copy the kext file into your /System/Library/Extensions folder

 

you will see that the driver loads, detects and communicates with teh hardware, but has some dma trouble and thinks that the dam is constantly running. the good news is that mac os x sees it and you are even able to control the volume, but no sound yet., so that's what we're at.

 

 

ps. dont forget to change the file extension back to .cpp

AppleAC97AudioATIIXP.cpp.txt

Link to comment
Share on other sites

nothing in particular, i was just hoping that if more eyes looked at the code we could figure out what is going wrong with the dma engine.

 

 

scousi's error is this

Mar 29 21:26:03 MACPortable kernel[0]: HW Position = 0x102d50b4 engine ID = 0x1,REG=0xc

 

mine is the same but i dont have a hardware position address

Mar 29 21:26:03 MACPortable kernel[0]: HW Position = 0x0 engine ID = 0x1,REG=0xc

Link to comment
Share on other sites

I found another bug in the code

 

It seams that it tries to load the via sound driver first, fails, then tries to load the ATIIXP driver. This may be related to the problem with the engine, as it may attempting to use the engine of the VIA driver and crapping out because of it. What's interesting is that it gets as far as it does.

 

[edit]

I changed the plist in XCode to the default code, so the VIA driver no longer loads,

had to delete the Extensions.mkext and Extensions.kextcache files though.

 

Alright that's all for now folks

[/edit]

 

That or there's another error in the code that I'm not seeing

 

Scousi, may I ask why the device id for the VIA was set to 0x43771002 when it is supposed to be something else?

43771002 appears to be the PCI-ISA bridge.

 

The investigation continues......

Link to comment
Share on other sites

I found another bug in the code

 

It seams that it tries to load the via sound driver first, fails, then tries to load the ATIIXP driver. This may be related to the problem with the engine, as it may attempting to use the engine of the VIA driver and crapping out because of it. What's interesting is that it gets as far as it does.

 

[edit]

I changed the plist in XCode to the default code, so the VIA driver no longer loads,

had to delete the Extensions.mkext and Extensions.kextcache files though.

 

Alright that's all for now folks

[/edit]

 

That or there's another error in the code that I'm not seeing

 

Scousi, may I ask why the device id for the VIA was set to 0x43771002 when it is supposed to be something else?

43771002 appears to be the PCI-ISA bridge.

 

The investigation continues......

 

That's because at first I used the VIA code as the baseline and put 4370 there. When I wanted to to remove it, I was too lazy to look up the original so I put an arbitrary 4377 there. I gues we should put the original back in.

 

PS - My VIA never loads as I load the driver manually while I'm debugging.

 

The problem I have is that the function atiixp_out_enable_transfer from atiixp.c wasn't implemented. When I run this enabler, it screws up the initialization. So I'm trying to figure out the correct place of where to run this in the sequence of things.

 

I've checked the status of the codec by reading all the proper H/W addresses and it's in the proper state. The buffer descriptor is now initialized OK (there was a few bugs in that code since I was inserting in the "next" pointer of the linked list the virtual address rather than the h/w address). The volume controls are actually changing the volume registers inside the chip also.

 

The reason the DMA engine is looping I think, is that since the h/W pointer is never advancing, the driver tries to restart the engine all the time. I guess we could try to stub the h/w pointer return and fake an increasing value to see the effect.

 

It's a long process mainly because of the reboots required + the IOLog buffer seems to skip some messages. If I had firewire on my laptop, I could remotely step through the driver code.

 

I think that we are fairly close.

Link to comment
Share on other sites

Just a quick question to the devs. I've been told by dimbulb that the internal 56k modem in HP/Compaq laptops is a part of the sound system (Windows XP calls the modem "AC97 Data Fax SoftModem with SmartCP"). Thus, can one assume that this sound driver may allow OSX to recognise the internal modem component, or will it purely be for sound only?

 

Thanks for the hard work!

Link to comment
Share on other sites

the short is, no this driver is for sound, but yeah, they are related....much of the same code is used in the modem driver from linux, but is, a separate driver.

 

besides? who uses dial-up anymore?

(a bit satirical)

Link to comment
Share on other sites

Just a quick question to the devs. I've been told by dimbulb that the internal 56k modem in HP/Compaq laptops is a part of the sound system (Windows XP calls the modem "AC97 Data Fax SoftModem with SmartCP"). Thus, can one assume that this sound driver may allow OSX to recognise the internal modem component, or will it purely be for sound only?

 

Thanks for the hard work!

 

 

I've never used the modem on myLaptop in XP. I don't even know if it works! I don't think there will be great demand for the modem to work. I want to focus our effort on sound. I haven't had time to spend a single hour this past week for the driver. Hopefully, the next week will be better.

Link to comment
Share on other sites

Oh okay, that's understandable. You guys have been putting in plenty of effort into this as it is.

 

I just thought that since the modem is a part of the sound system you guys may have that on the agenda, too. Personally I live in a fairly broadband-deprived country, and thus, am quite dependant on my 56k modem whenever I don't have access to a WiFi hotspot. If a modem driver was developed you guys would most certainly be worshipped by anyone else who is in the same situation as me, I'm sure. But, having said that, I understand how you would prefer to focus your time, skills and effort on areas that have high levels of demand.

Link to comment
Share on other sites

Out of curiosity has anyone else tried messing with the code. I see there's been downloads, so I guess others have looked at it, has tanyone else attempting hacking at it?

 

I downloaded it yesterday, and I'll try to have a look at it tonite if I have some time :graduated:

Link to comment
Share on other sites

Out of curiosity has anyone else tried messing with the code. I see there's been downloads, so I guess others have looked at it, has tanyone else attempting hacking at it?

 

I've downloaded it, but haven't yet had time to look into it... I'm graduating in 2 weeks so that might give me some time.

Link to comment
Share on other sites

Sorry about the lack of posts.

 

I haven't been able to do much work on the driver in the last week as I have had a lot of work with school, just finished up a few thousand lines of code for my CS class, but now that's submitted and done, I will be able to focus some time on the Sound driver.

 

so that's the latest news over here.

Link to comment
Share on other sites

Oh okay, that's understandable. You guys have been putting in plenty of effort into this as it is.

 

I just thought that since the modem is a part of the sound system you guys may have that on the agenda, too. Personally I live in a fairly broadband-deprived country, and thus, am quite dependant on my 56k modem whenever I don't have access to a WiFi hotspot. If a modem driver was developed you guys would most certainly be worshipped by anyone else who is in the same situation as me, I'm sure. But, having said that, I understand how you would prefer to focus your time, skills and effort on areas that have high levels of demand.

I know as someone who is JUST outside of a hotspot at my work area would really appreciate a modem driver, I brought it up on the IRC once and I pretty much got laughed at :blink:

Link to comment
Share on other sites

yeah, i've been hit with a lot of work with school, just when i think im done, i have another project, essay, and test. yeah, that and I broke the lcd on my laptop, so I haven't been able to use it for about a week. If all goes well, I should be able to buy another laptop, same specs, to continue work on the driver.

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
 Share

×
×
  • Create New...