anybody tried usb interface with linux yet?

That are my observations, too. Haven't been near my Axe-Fx II during the last weekend so I could do no further testing. But building a dedicated pulseaudio conf file for the Axe-Fx II and adding an appropriate entry to 90-pulseaudio.rules could possibly help. There are already some of such conf files (located: /usr/share/pulseaudio/alsa-mixer/profile-sets) for the M-Audio Fasttrack Pro and some Native Instruments devices. Maybe the file default.pa has to be modified by adding some lines to manually load module-alsa-sink and module-alsa-source with parameters for the Axe-Fx II. There seem to be at least some successful attempts on doing so to make RME and Terratec sound cards work.
 
Basically the problem was that ALSA could not set the hardware parameters....
Since some of the features it tries to use are not implemented by the soft firmware, using the interface fails.

Linux ain't my thing (yet...). Just a wild guess which might help. Is there a way for you to enumerate the specific functionality that you want Linux to support, perhaps
you could pass your own struct, or there might be a function/proceedure access to do so.

As you know, the Linux forums are the best place to try for an answer to a specific question. Not sure which would be best, isn't there a linux flavor geared towards being
a DAW?
 
After all it works!

Sorry for the silence during the last weeks, had a shitload of work to do...

But now not only progress has been made - since yesterday my Axe-FX II not only works as a MIDI interface but also as a sound card! :D

Last evening I had the time and chance to work on this subject with Daniel Mack (thanks to him again) from the alsa-user mailing list. The only reason why the Axe-FX II does not work with Linux out of the box is that the Axe (at the moment) neither responds to set sample rate requests nor get sample rate requests. So we built a patch for the files clock.c and format.c (located under /usr/src/linux-kernelversion/sound/usb/) to work around this:

Code:
diff --git a/sound/usb/clock.c b/sound/usb/clock.c
index 379baad..b05111d 100644
--- a/sound/usb/clock.c
+++ b/sound/usb/clock.c
@@ -255,6 +255,13 @@ static int set_sample_rate_v2(struct snd_usb_audio *chip, int iface,
 	int err, crate;
 	int clock = snd_usb_clock_find_source(chip, fmt->clock);
 
+	/*
+	 * Fractal Audio Systems AXE-FX II does not respond to sample rate
+	 * set requests. The only valid rate is 48000.
+	 */
+	if (chip->usb_id == USB_ID(0x2466, 0x8003) && rate == 48000)
+		return 0;
+
 	if (clock < 0)
 		return clock;
 
diff --git a/sound/usb/format.c b/sound/usb/format.c
index ddfef57..7a9e82a 100644
--- a/sound/usb/format.c
+++ b/sound/usb/format.c
@@ -279,6 +279,20 @@ static int parse_audio_format_rates_v2(struct snd_usb_audio *chip,
 	int nr_triplets, data_size, ret = 0;
 	int clock = snd_usb_clock_find_source(chip, fp->clock);
 
+	/*
+	 * Fractal Audio Systems AXE-FX II does not respond to sample rate
+	 * query requests. The only valid rate is 48000.
+	 */
+	if (chip->usb_id == USB_ID(0x2466, 0x8003)) {
+		fp->nr_rates = 1;
+		fp->rate_min = 48000;
+		fp->rate_max = 48000;
+		fp->rates = SNDRV_PCM_RATE_48000;
+		fp->rate_table = kmalloc(sizeof(int), GFP_KERNEL);
+		fp->rate_table[0] = 48000;
+		return 0;
+	}
+
 	if (clock < 0) {
 		snd_printk(KERN_ERR "%s(): unable to find clock source (clock %d)\n",
 				__func__, clock);

You can save the code above as a diff file and apply it using the patch command.

After applying the patch the snd-usb-audio module has to be recompiled. Once the previous version of this module has been removed from the kernel and the newly built module has been added to the kernel, playback and capturing devices of the Axe-FX II appear - and are functional now. I successfully recorded and played audio using arecord, audacity and ardour. :D

All testing was done using openSUSE 12.1 (kernel 3.1.9-1.4-desktop, 64bit) and ALSA 1.0.24.

volt

P.S. There is no more need to use the modification of quirks-table.h as described in post #11.
 
Sorry, coming into this discussion a little late, I would love to get the Axe II working in Linux. To get this straight, we run the initial script that allows the Linux file-system to load the Axe II as a USB module (post #1). We also apply the patch from post #23 and then we should be good to go? Does it still required a kernel >= 3.0? I'll try this on my Ubuntu 11.04 box this weekend. Thanks for all the great work!!
 
Sorry, coming into this discussion a little late, I would love to get the Axe II working in Linux. To get this straight, we run the initial script that allows the Linux file-system to load the Axe II as a USB module (post #1).

Yes.

We also apply the patch from post #23 and then we should be good to go?

Yes. Apply the patch, recompile the snd-usb-audio module and add it to the kernel. No further drivers or the like are needed.

For convenience purposes you can add the following two lines to the file named usb.ids:

Code:
2466  Fractal Audio Systems
	8003  Axe-Fx II

Then e.g. lsusb names the Axe-FX II properly.

Does it still required a kernel >= 3.0? I'll try this on my Ubuntu 11.04 box this weekend. Thanks for all the great work!!

Sorry, I only did test with kernel 3.1.9, but I guess that it would also work with earlier kernel versions if the ALSA version is identical.
 
Thanks for your work on this, Volt.

I ran your install script on a Raspberry Pi with the latest Raspbian build. I was mainly interested in seeing if I could use the RPi to load USB firmware into the Axe. It works perfectly. I can use this to prepare the AxeII for direct connection to an iPad via the camera connection USB adapter.
 
I'm almost finished installing the driver and such. updated the usb.ids and lsusb notices the axe fx II.
switching it off and turning it on works too, I think the firmware get's loaded automatically.
when I use Gnome ALSA mixer it shows "USB audio" but it's empty and nothings there.
I can't find the clock.c and the format.c, where are those files?!
I have a feeling I only need to update those two files.

and btw, I downloaded the latest mac driver installer and replaced the hex file with a newer one (13kb) to match the firmware installed on my axe fx II.

I'm almost there, I just need the the last bits now, please help me volt-kenobi, you'r my only hope ;)
 
Yes, I just updated the firmware file in my downloadable package (This has nothing to do with matching the firmware of the Axe-Fx II btw).

clock.c and format.c are under /usr/src/linux-xxx/sound/usb for me. You need to have the kernel sources installed of course.
 
Last edited:
I've only used ubuntu for a year now. So I don't really understand kernel sources I'm afraid :/
What is it that I need to finish this up?
 
Back
Top Bottom