5024 Posted April 29, 2006 Share Posted April 29, 2006 thnx for keeping us guys updated :- )) sound is not the most important thing in the world, but it would be really nice to see it working one day (its the last non working thing on my laptop (5024wlmi) beside wifi, but that shouldnt be hard to fix ->because i know what the problem is..) Link to comment https://www.insanelymac.com/forum/topic/10903-ati-ac-97-sounds-sb400-effort/page/4/#findComment-105035 Share on other sites More sharing options...
digicide Posted May 10, 2006 Share Posted May 10, 2006 well... i gave the source a look through and have nothing to report... except that you guys are really smart. I've only coded for Nintendo DS and it's the sound that's always giving me problems on that, too... good luck with your laptop Ed. Link to comment https://www.insanelymac.com/forum/topic/10903-ati-ac-97-sounds-sb400-effort/page/4/#findComment-110458 Share on other sites More sharing options...
thedopefishlives Posted May 11, 2006 Share Posted May 11, 2006 I took a look at the source, but I can't make enough of a correlation between it and the Linux kernel source to quite follow what your driver is actually doing. It'll take me a few days to get up to speed, but I should be able to help out eventually. Link to comment https://www.insanelymac.com/forum/topic/10903-ati-ac-97-sounds-sb400-effort/page/4/#findComment-111274 Share on other sites More sharing options...
moid Posted May 11, 2006 Share Posted May 11, 2006 Hey, 5024... I have an Acer 4402 And it shares a configuration very similar to yours... But I tried all the ways, but couldn't succeed in installing OSX native.. How did you do that? Grateful Link to comment https://www.insanelymac.com/forum/topic/10903-ati-ac-97-sounds-sb400-effort/page/4/#findComment-111275 Share on other sites More sharing options...
greggh Posted May 12, 2006 Share Posted May 12, 2006 I have an ATI SB400 board in my new laptop. It came with realtek drivers for the ac97 (Realtek HD.) Is this going to be the same chipset you are trying to support? I am willing to test anything. Link to comment https://www.insanelymac.com/forum/topic/10903-ati-ac-97-sounds-sb400-effort/page/4/#findComment-111320 Share on other sites More sharing options...
EdFlyer Posted May 12, 2006 Share Posted May 12, 2006 I took a look at the source, but I can't make enough of a correlation between it and the Linux kernel source to quite follow what your driver is actually doing. It'll take me a few days to get up to speed, but I should be able to help out eventually. Thanks man, any help is great. As it is, I'll be getting the new laptop in about a week, its in the mail now, so I'll hopefully be able to devote some more time to this. I have an ATI SB400 board in my new laptop. It came with realtek drivers for the ac97 (Realtek HD.) Is this going to be the same chipset you are trying to support? I am willing to test anything. If the device driver for your sound uses the id 1002 4370 then yeah this driver should support it, if not, check to see if your device driver is already supported by a driver on this website. Yeah, so that's the latest news for now. Link to comment https://www.insanelymac.com/forum/topic/10903-ati-ac-97-sounds-sb400-effort/page/4/#findComment-111382 Share on other sites More sharing options...
mito_pm Posted May 12, 2006 Share Posted May 12, 2006 Hi, i'm having problems with that sound card. Well, I really want to help, but my knowledge of drivers is almost null. I'm learning C++, but I need much more than that. Could you give me please a link or the topics that I should learn to help on this driver? I hope you understand what I wrote, i'm from Chile. Thanks. Link to comment https://www.insanelymac.com/forum/topic/10903-ati-ac-97-sounds-sb400-effort/page/4/#findComment-111389 Share on other sites More sharing options...
EdFlyer Posted May 12, 2006 Share Posted May 12, 2006 apple's developer website has stuff on iokit you can read that. the big thing with this driver is to study the linux code and figure out how it works, then to study the mac os x code for other drivers and see how they work, compare them, and then come up with something that works for this sound driver. thanks for the help though, there's some source code posted earlier in the thread with some instructions on how to start with hit. Link to comment https://www.insanelymac.com/forum/topic/10903-ati-ac-97-sounds-sb400-effort/page/4/#findComment-111392 Share on other sites More sharing options...
mito_pm Posted May 12, 2006 Share Posted May 12, 2006 Ok, thanks. I know C and some C++, Unix commands and Linux. But i'm not an expert Well, let's see if in a couple of weeks i can do something. Link to comment https://www.insanelymac.com/forum/topic/10903-ati-ac-97-sounds-sb400-effort/page/4/#findComment-111394 Share on other sites More sharing options...
thedopefishlives Posted May 12, 2006 Share Posted May 12, 2006 The lucky thing is that I've been overwhelmed with Linux kernel details due to my OS project coming due, so at least I can take one look at the Linux atiixp.c file and instinctively know how it works Finals are next week for me, I should have some time in between exams to make an effort to understand the Mach kernel driver system. Link to comment https://www.insanelymac.com/forum/topic/10903-ati-ac-97-sounds-sb400-effort/page/4/#findComment-111539 Share on other sites More sharing options...
greggh Posted May 13, 2006 Share Posted May 13, 2006 Is this going to be the same as the SB450's built in? On linux I use the hda-intel driver for it. Link to comment https://www.insanelymac.com/forum/topic/10903-ati-ac-97-sounds-sb400-effort/page/4/#findComment-111903 Share on other sites More sharing options...
EdFlyer Posted May 13, 2006 Share Posted May 13, 2006 If you use the intel hda audio in linux u'll probably use the AppleAzalia stuff, look around on the forum for that. This driver is for device id 1002 (ati) 4370 Amc Conexant AC-link audio. Link to comment https://www.insanelymac.com/forum/topic/10903-ati-ac-97-sounds-sb400-effort/page/4/#findComment-111929 Share on other sites More sharing options...
Peter Gammelgaard Posted May 13, 2006 Share Posted May 13, 2006 Good that this project is not dead.. Keep up the good work Edflyer.. Link to comment https://www.insanelymac.com/forum/topic/10903-ati-ac-97-sounds-sb400-effort/page/4/#findComment-112013 Share on other sites More sharing options...
EdFlyer Posted May 14, 2006 Share Posted May 14, 2006 for those looking at the source, in the file AppleAC97AudioATIIXP in the function IOByteCount CLASS:getDMAEngineHardwarePointer( IOAC97EngineID engine ) it is supposed to return the position, but it isn't, so that needs to be calculated..........then that will be at least one bug removed from the code. I am going to check the lniux source to see how it handles that, if it does. If anyone comes up with a solution, please post it. Lines 631-653 seem to be the relevant lines. From http://www.linux-m32r.org/lxr/http/source/sound/pci/atiixp.c But i'm not sure how to translate it as of yet, so if anyone can take a look and see what's up that would be nice. Link to comment https://www.insanelymac.com/forum/topic/10903-ati-ac-97-sounds-sb400-effort/page/4/#findComment-112739 Share on other sites More sharing options...
thedopefishlives Posted May 15, 2006 Share Posted May 15, 2006 I'll get that done I don't have anything better to do today, so I should have a patch rolled out by tonight. Link to comment https://www.insanelymac.com/forum/topic/10903-ati-ac-97-sounds-sb400-effort/page/4/#findComment-113096 Share on other sites More sharing options...
EdFlyer Posted May 15, 2006 Share Posted May 15, 2006 thanks, just double check its the same idea in the code. It looks to be the same, based off the comments. Link to comment https://www.insanelymac.com/forum/topic/10903-ati-ac-97-sounds-sb400-effort/page/4/#findComment-113097 Share on other sites More sharing options...
thedopefishlives Posted May 15, 2006 Share Posted May 15, 2006 It's the same idea, but something interesting is happening. I put in the linux-style timeout code with the while loop, and for some reason, yours is timing out. That is, it never appears to read a "correct" value. I think this might be the cause of the DMA engine looping problem, if you care to look into it further. Link to comment https://www.insanelymac.com/forum/topic/10903-ati-ac-97-sounds-sb400-effort/page/4/#findComment-113107 Share on other sites More sharing options...
EdFlyer Posted May 15, 2006 Share Posted May 15, 2006 I was figuring they are related, can you send me the code u changed so I can integrate it into my code and go from there? Thanks. Link to comment https://www.insanelymac.com/forum/topic/10903-ati-ac-97-sounds-sb400-effort/page/4/#findComment-113108 Share on other sites More sharing options...
thedopefishlives Posted May 15, 2006 Share Posted May 15, 2006 Here's the modified .cpp file. I went from scousi's latest upload. AppleAC97AudioATIIXP.cpp.txt Link to comment https://www.insanelymac.com/forum/topic/10903-ati-ac-97-sounds-sb400-effort/page/4/#findComment-113111 Share on other sites More sharing options...
EdFlyer Posted May 15, 2006 Share Posted May 15, 2006 does your volume slider show up with your version of the code? just wondering, cause I have a version of the code that does, but its slightly different code. yeah, in corporated your code into mine, but it still loops inifinitely. At least we are a little closer than before. AppleAC97AudioATIIXP.cpp.txt Link to comment https://www.insanelymac.com/forum/topic/10903-ati-ac-97-sounds-sb400-effort/page/4/#findComment-113159 Share on other sites More sharing options...
thedopefishlives Posted May 15, 2006 Share Posted May 15, 2006 I believe it does, but if it doesn't, no matter. I am curious, Ed, as to how Apple's drivers handle interrupts. In particular, I am not so certain that the driver is triggering the interrupt at the end of DMA transfer, which would stop the DMA engine. I'd like to throw in some debug statements to see if the interrupt executes, but I'm not sure I can find the right spot. Link to comment https://www.insanelymac.com/forum/topic/10903-ati-ac-97-sounds-sb400-effort/page/4/#findComment-113202 Share on other sites More sharing options...
scousi Posted May 15, 2006 Share Posted May 15, 2006 I believe it does, but if it doesn't, no matter. I am curious, Ed, as to how Apple's drivers handle interrupts. In particular, I am not so certain that the driver is triggering the interrupt at the end of DMA transfer, which would stop the DMA engine. I'd like to throw in some debug statements to see if the interrupt executes, but I'm not sure I can find the right spot. You don't really need an interrupt. The chip is just supposed to loop whatever you inserft in the DMA. Apple's audio implementation needs the HW pointer of the where the CODEC is at so it can make deterministic predictions. That's where I was getting some problems. When I read this IO position, it never changes. I don't know if you have the latest lastest code I have but I had managed to clean up some of the IO mappings at the time I was working on the driver. I'm pretty sure that I have the DMA mappings structured correcly. I also had asked ATI for a data sheet but they never even responded. Be carefull with the IOLOG. It doesn't seem to print everything. You can't really rely on it. You might want to stub the getDMAEngineHardwarePointer function and return an incremental value instead of actually reading the chip pointer to see how differently the driver behaves. I suspect that the driver doesn't work because it's not getting moving position. If you fake it , you will at least see how differently the dirver behaves. Hopefully, I will be able to continue working on it soon. Good luck. Link to comment https://www.insanelymac.com/forum/topic/10903-ati-ac-97-sounds-sb400-effort/page/4/#findComment-113339 Share on other sites More sharing options...
Elv13 Posted May 15, 2006 Share Posted May 15, 2006 is it possible to post the lastest full source and the compilled .kext (for fun or hex hacking) and is IXP 150 will be suported? (atiixp module in linux kernel) Link to comment https://www.insanelymac.com/forum/topic/10903-ati-ac-97-sounds-sb400-effort/page/4/#findComment-113349 Share on other sites More sharing options...
EdFlyer Posted May 15, 2006 Share Posted May 15, 2006 so far what is supported is the ati ixp sound 1002 4370, if it responds to this device id it would work, we are using the atiixp.c in linux/bsd as our base of idea for code, so it is very possible that it may work, once we have it working it can be tested to see if its compatible with others. Link to comment https://www.insanelymac.com/forum/topic/10903-ati-ac-97-sounds-sb400-effort/page/4/#findComment-113357 Share on other sites More sharing options...
thedopefishlives Posted May 16, 2006 Share Posted May 16, 2006 You don't really need an interrupt. The chip is just supposed to loop whatever you inserft in the DMA. Apple's audio implementation needs the HW pointer of the where the CODEC is at so it can make deterministic predictions. That's where I was getting some problems. When I read this IO position, it never changes. I don't know if you have the latest lastest code I have but I had managed to clean up some of the IO mappings at the time I was working on the driver. I'm pretty sure that I have the DMA mappings structured correcly. I also had asked ATI for a data sheet but they never even responded. Be carefull with the IOLOG. It doesn't seem to print everything. You can't really rely on it. You might want to stub the getDMAEngineHardwarePointer function and return an incremental value instead of actually reading the chip pointer to see how differently the driver behaves. I suspect that the driver doesn't work because it's not getting moving position. If you fake it , you will at least see how differently the dirver behaves. Hopefully, I will be able to continue working on it soon. Good luck. Ahhhh, okay. I've worked with a lot of hardware, but sound cards are the one thing I haven't messed with in driver terms. It makes sense now why the interrupt wasn't firing - it doesn't have to. So it does indeed appear to be in the getDMAEngineHardwarePointer function. I just don't understand why the hardware pointer doesn't appear to be incrementing. I'll keep poking around the Linux source and let you guys know if there's anything of import that we missed. Link to comment https://www.insanelymac.com/forum/topic/10903-ati-ac-97-sounds-sb400-effort/page/4/#findComment-113377 Share on other sites More sharing options...
Recommended Posts