All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] EMU10K1.conf
@ 2003-12-27  0:31 Dominik 'Aeneas' Schnitzer
  2004-01-05 16:51 ` Takashi Iwai
  0 siblings, 1 reply; 6+ messages in thread
From: Dominik 'Aeneas' Schnitzer @ 2003-12-27  0:31 UTC (permalink / raw)
  To: alsa-devel

[-- Attachment #1: Type: text/plain, Size: 1348 bytes --]

Hi,

I finally got my emu10k1 soundcard working with full 5.1 surround :-)

It took me 2 days, getting alsa to know and sound working properly. I
finally found out that /usr/share/alsa/cards/EMU10K1.conf was b0rked and
modified it so everything now works properly. Things which prevented it
from working properly were:

 - Rear/Center&&LFE Volume Controls in the config file were set to 0 and
locked!..

 - surround51 was statically bound to the non-digital output and locked
(to the analogue output), so there was no way to get surround sound on
my digital-out.

 - other volume controls were locked too, I had a look at Audigy.conf
and reduced the locked controls to the minimum required.


The patch attached for /usr/share/alsa/cards/EMU10K1.conf is actually
very trivial and a cleanup of the old file, it would be cool if you'd
apply the patch to the ALSA config file in CVS, I'm sure it would help a
lot of people which have no rear sound with the emu10k1.


/me now leans back and enjoys alsa and Lord Of The Rings II Extended
Version in _FULL_ Digital Dolby 5.1 :))))

best wishes,
dominik.
-- 
Dominik 'Aeneas' Schnitzer <dominik@schnitzer.at>
http://www.schnitzer.at/dominik/ - Update 03/08/31: Birthday Party

PGP Fingerprint: E839 B9EA F518 899D AA35  BB67 0DBF 7AB2 5FE6 525A
PGP Public Key: http://www.schnitzer.at/dominik/public.key

[-- Attachment #2: EMU10K1.conf --]
[-- Type: text/plain, Size: 2893 bytes --]

#
# Configuration for the EMU10K1 chip
#

<confdir:pcm/front.conf>

EMU10K1.pcm.front.0 {
	@args [ CARD ]
	@args.CARD {
		type string
	}
	type hw
	card $CARD
	device 0
}

<confdir:pcm/rear.conf>

EMU10K1.pcm.rear.0 {
	@args [ CARD ]
	@args.CARD {
		type string
	}
	type hooks
	slave.pcm {
		type hw
		card $CARD
		device 0
	}
	hooks.0 {
		type ctl_elems
		hook_args [
			{
				name "EMU10K1 PCM Send Volume"
				index { @func private_pcm_subdevice }
				lock true
				value [ 0 0 0 0 0 0 255 0 0 0 0 255 ]
			}
		]
	}
}	

<confdir:pcm/center_lfe.conf>

EMU10K1.pcm.center_lfe.0 {
	@args [ CARD ]
	@args.CARD {
		type string
	}
	type hooks
	slave.pcm {
		type hw
		card $CARD
		device 0
	}
	hooks.0 {
		type ctl_elems
		hook_args [
			{
				name "EMU10K1 PCM Send Volume"
				index { @func private_pcm_subdevice }
				lock true
				value [ 0 0 0 0 255 0 0 0 0 255 0 0 ]
			}
			{
				name "EMU10K1 PCM Send Routing"
				index { @func private_pcm_subdevice }
				lock true
				value [ 0 1 2 3 6 7 0 1 6 7 0 1 ]
			}
		]
	}
}	

<confdir:pcm/surround40.conf>

EMU10K1.pcm.surround40.0 {
	@args [ CARD ]
	@args.CARD {
		type string
	}
	type multi
	slaves [
		{
			pcm {
				@func concat
				strings [
					"cards.EMU10K1.pcm.front.0:CARD=" $CARD
				]
			}
			channels 2
		}
		{
			pcm {
				@func concat
				strings [
					"cards.EMU10K1.pcm.rear.0:CARD=" $CARD
				]
			}
			channels 2
		}
	]
	bindings [
		{ slave 0 channel 0 }
		{ slave 0 channel 1 }
		{ slave 1 channel 0 }
		{ slave 1 channel 1 }
	]
}

<confdir:pcm/surround41.conf>
<confdir:pcm/surround50.conf>
<confdir:pcm/surround51.conf>

EMU10K1.pcm.surround51.0 {
	@args [ CARD ]
	@args.CARD {
		type string
	}
	type multi
	slaves [
		{
			pcm {
				@func concat
				strings [
					"cards.EMU10K1.pcm.front.0:CARD=" $CARD
				]
			}
			channels 2
		}
		{
			pcm {
				@func concat
				strings [
					"cards.EMU10K1.pcm.rear.0:CARD=" $CARD
				]
			}
			channels 2
		}
		{
			pcm {
				@func concat
				strings [
					"cards.EMU10K1.pcm.center_lfe.0:CARD=" $CARD
				]
			}
			channels 2
		}
	]
	bindings [
		{ slave 0 channel 0 }
		{ slave 0 channel 1 }
		{ slave 1 channel 0 }
		{ slave 1 channel 1 }
		{ slave 2 channel 0 }
		{ slave 2 channel 1 }
	]
}

<confdir:pcm/iec958.conf>

EMU10K1.pcm.iec958.0 {
	@args [ CARD AES0 AES1 AES2 AES3 ]
	@args.CARD {
		type string
	}
	@args.AES0 {
		type integer
	}
	@args.AES1 {
		type integer
	}
	@args.AES2 {
		type integer
	}
	@args.AES3 {
		type integer
	}
	type hooks
	slave.pcm {
		type hw
		card $CARD
		device 3
	}
	hooks.0 {
		type ctl_elems
		hook_args [
			{
				name "IEC958 Playback Default"
				lock true
				preserve true
				value [ $AES0 $AES1 $AES2 $AES3 ]
			}
			{
				name "IEC958 Optical Raw Playback Switch"
				lock true
				preserve true
				value [ 1 1 ]
			}
			{
				name "SB Live Analog/Digital Output Jack"
				lock true
				preserve true
				value 1
			}
		]
	}
}

[-- Attachment #3: EMU10K1-conf.patch --]
[-- Type: text/x-patch, Size: 1148 bytes --]

--- EMU10K1.conf.orig	2003-12-25 23:57:56.000000000 +0100
+++ EMU10K1.conf	2003-12-27 01:02:00.000000000 +0100
@@ -12,7 +12,7 @@
 	type hw
 	card $CARD
 	device 0
-}	
+}
 
 <confdir:pcm/rear.conf>
 
@@ -31,12 +31,6 @@
 		type ctl_elems
 		hook_args [
 			{
-				name "Wave Surround Playback Volume"
-				preserve true
-				lock true
-				value [ 0 0 ]
-			}
-			{
 				name "EMU10K1 PCM Send Volume"
 				index { @func private_pcm_subdevice }
 				lock true
@@ -63,38 +57,6 @@
 		type ctl_elems
 		hook_args [
 			{
-				name "Wave Center Playback Volume"
-				preserve true
-				lock true
-				value 0
-			}
-			{
-				name "Wave LFE Playback Volume"
-				preserve true
-				lock true
-				value 0
-			}
-			{
-				name "Headphone Center Playback Switch"
-				index 1
-				preserve true
-				lock true
-				value true
-			}
-			{
-				name "Headphone LFE Playback Switch"
-				index 1
-				preserve true
-				lock true
-				value true
-			}
-			{
-				name "SB Live Analog/Digital Output Jack"
-				preserve true
-				lock true
-				value 0
-			}
-			{
 				name "EMU10K1 PCM Send Volume"
 				index { @func private_pcm_subdevice }
 				lock true

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH] EMU10K1.conf
  2003-12-27  0:31 [PATCH] EMU10K1.conf Dominik 'Aeneas' Schnitzer
@ 2004-01-05 16:51 ` Takashi Iwai
  2004-01-06 11:23   ` Dominik 'Aeneas' Schnitzer
  0 siblings, 1 reply; 6+ messages in thread
From: Takashi Iwai @ 2004-01-05 16:51 UTC (permalink / raw)
  To: Dominik 'Aeneas' Schnitzer; +Cc: alsa-devel

At Sat, 27 Dec 2003 01:31:52 +0100,
Dominik 'Aeneas' Schnitzer wrote:
> 
> [1  <text/plain (7bit)>]
> Hi,
> 
> I finally got my emu10k1 soundcard working with full 5.1 surround :-)
> 
> It took me 2 days, getting alsa to know and sound working properly. I
> finally found out that /usr/share/alsa/cards/EMU10K1.conf was b0rked and
> modified it so everything now works properly. Things which prevented it
> from working properly were:
> 
>  - Rear/Center&&LFE Volume Controls in the config file were set to 0 and
> locked!..

"Wave XXX Volume" controls should be zero for multi-channel outputs
indeed, because these are volumes of signals duplicated from the front
channel to surround/center/lfe channels.
locking could be optional, though.


>  - surround51 was statically bound to the non-digital output and locked
> (to the analogue output), so there was no way to get surround sound on
> my digital-out.

hmm, i'm not sure about this.  surround51 was designed for outputs
from three analog jacks.

what do you get from digital out with surround51?
does the card send non-encoded raw 6-channel PCM over spdif?

>  - other volume controls were locked too, I had a look at Audigy.conf
> and reduced the locked controls to the minimum required.

on Audigy, the signal routing and control elements are fairly
different from SB Live.  so, you cannot copy it simply...


Takashi


-------------------------------------------------------
This SF.net email is sponsored by: IBM Linux Tutorials.
Become an expert in LINUX or just sharpen your skills.  Sign up for IBM's
Free Linux Tutorials.  Learn everything from the bash shell to sys admin.
Click now! http://ads.osdn.com/?ad_id=1278&alloc_id=3371&op=click

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH] EMU10K1.conf
  2004-01-05 16:51 ` Takashi Iwai
@ 2004-01-06 11:23   ` Dominik 'Aeneas' Schnitzer
  2004-01-07 17:07     ` Takashi Iwai
  0 siblings, 1 reply; 6+ messages in thread
From: Dominik 'Aeneas' Schnitzer @ 2004-01-06 11:23 UTC (permalink / raw)
  To: Takashi Iwai; +Cc: alsa-devel

On Mon, 2004-01-05 at 17:51, Takashi Iwai wrote:
> "Wave XXX Volume" controls should be zero for multi-channel outputs
> indeed, because these are volumes of signals duplicated from the front
> channel to surround/center/lfe channels.
> locking could be optional, though.

Hi!

For me "Wave XXX Volume" controls (using digital out) work like
intended:

Wave: Front Speakers Volume
Wave Center: Center Speaker
Wave LFE: LFE
Wave Surround: Rear Speakers

But setting "Wave Surround Playback Volume" to 0 in the
EMU10K1.pcm.rear.0 section has the effect that no sound is coming out of
the rear boxes.

And setting "Wave Center Playback Volume" and "Wave LFE Playback Volume"
to 0 (in EMU10K1.pcm.center_lfe.0) has the effect that no sound is
coming out of the center and LFE speakers.

Generally this means that with the current alsa configuration only the 2
front speakers have sound (when using the digital out jack).

By removing the locks and 0-settings, its possible to control the other
volumes too -> and thus unlocking the other speakers too. :)

> >  - surround51 was statically bound to the non-digital output and locked
> > (to the analogue output), so there was no way to get surround sound on
> > my digital-out.
> 
> hmm, i'm not sure about this.  surround51 was designed for outputs
> from three analog jacks.
> 
> what do you get from digital out with surround51?

With the modified config-file and setting xine to use surround51 I get
True surround 5.1 sound. I have a 5.1 test-audio file, which I used for
testig - Its not just duplication of the front speakers signal.

Using the unmodified config and setting xine to use surround51, the card
switches to analogue out, the receiver blinks (no connection) and
nothing happens. If I remove the analogue-out lock in the config, only
the 2 front speakers work. Removing the 0 volume locks (and increasing
volumes in the mixer) everything works.

> does the card send non-encoded raw 6-channel PCM over spdif?

No, digital out sends the data over this creative-coaxial cable. AFAI
understand, spdif is only (?) used for sending raw Encoded AC3 data to a
5.1 receiver in order to let the receiver decode it.

> >  - other volume controls were locked too, I had a look at Audigy.conf
> > and reduced the locked controls to the minimum required.
> 
> on Audigy, the signal routing and control elements are fairly
> different from SB Live.  so, you cannot copy it simply...

I didn't copy the routing part, I just inspired :-) myself in the
Audigy.conf files. For the audigy digital-out and the other volumes
weren't locked and set to 0; so I tried this out for the EMU10k1 too and
it worked :D

I hope this helps a bit!
dominik.
-- 
Dominik 'Aeneas' Schnitzer <dominik@schnitzer.at>
http://www.schnitzer.at/dominik/ - Update 03/08/31: Birthday Party

PGP Fingerprint: E839 B9EA F518 899D AA35  BB67 0DBF 7AB2 5FE6 525A
PGP Public Key: http://www.schnitzer.at/dominik/public.key


-------------------------------------------------------
This SF.net email is sponsored by: IBM Linux Tutorials.
Become an expert in LINUX or just sharpen your skills.  Sign up for IBM's
Free Linux Tutorials.  Learn everything from the bash shell to sys admin.
Click now! http://ads.osdn.com/?ad_id=1278&alloc_id=3371&op=click

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH] EMU10K1.conf
  2004-01-06 11:23   ` Dominik 'Aeneas' Schnitzer
@ 2004-01-07 17:07     ` Takashi Iwai
  2004-01-07 17:50       ` Dominik 'Aeneas' Schnitzer
  0 siblings, 1 reply; 6+ messages in thread
From: Takashi Iwai @ 2004-01-07 17:07 UTC (permalink / raw)
  To: Dominik 'Aeneas' Schnitzer; +Cc: alsa-devel

At Tue, 06 Jan 2004 12:23:35 +0100,
Dominik 'Aeneas' Schnitzer wrote:
> 
> On Mon, 2004-01-05 at 17:51, Takashi Iwai wrote:
> > "Wave XXX Volume" controls should be zero for multi-channel outputs
> > indeed, because these are volumes of signals duplicated from the front
> > channel to surround/center/lfe channels.
> > locking could be optional, though.
> 
> Hi!
> 
> For me "Wave XXX Volume" controls (using digital out) work like
> intended:
> 
> Wave: Front Speakers Volume
> Wave Center: Center Speaker
> Wave LFE: LFE
> Wave Surround: Rear Speakers
> 
> But setting "Wave Surround Playback Volume" to 0 in the
> EMU10K1.pcm.rear.0 section has the effect that no sound is coming out of
> the rear boxes.

did you raise "Surround Digital Playback" volume?
(not "Surround", it's an entry of AC97).

> And setting "Wave Center Playback Volume" and "Wave LFE Playback Volume"
> to 0 (in EMU10K1.pcm.center_lfe.0) has the effect that no sound is
> coming out of the center and LFE speakers.

also "Center Playback" and "LFE Playback" volumes?

> Generally this means that with the current alsa configuration only the 2
> front speakers have sound (when using the digital out jack).
> 
> By removing the locks and 0-settings, its possible to control the other
> volumes too -> and thus unlocking the other speakers too. :)
> 
> > >  - surround51 was statically bound to the non-digital output and locked
> > > (to the analogue output), so there was no way to get surround sound on
> > > my digital-out.
> > 
> > hmm, i'm not sure about this.  surround51 was designed for outputs
> > from three analog jacks.
> > 
> > what do you get from digital out with surround51?
> 
> With the modified config-file and setting xine to use surround51 I get
> True surround 5.1 sound. I have a 5.1 test-audio file, which I used for
> testig - Its not just duplication of the front speakers signal.
 
the switch of "SB Live Analog/Digital" can be removed if it works for
you.  it was set to make sure the center "analog" jack works.
(in the recent models, the digital out is shared with the center/lfe
jack.)
with my emu10k1 board, i don't get any valid signals over
center/digital jack unless AC3 is played.  it might depend on the
receiver.  perhaps creative has its own protocol?

but, anyway, "Wave Surround" and "Wave Center" don't make sense at
all.  they are volumes of duplicated signals.  the volumes of
surround/center/lfe channels are different mixer elements.

also, if you want to send AC3 via spdif, you should use iec958 (aka
spdif) in xine.


Takashi


-------------------------------------------------------
This SF.net email is sponsored by: Perforce Software.
Perforce is the Fast Software Configuration Management System offering
advanced branching capabilities and atomic changes on 50+ platforms.
Free Eval! http://www.perforce.com/perforce/loadprog.html

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH] EMU10K1.conf
  2004-01-07 17:07     ` Takashi Iwai
@ 2004-01-07 17:50       ` Dominik 'Aeneas' Schnitzer
  2004-01-07 18:09         ` Takashi Iwai
  0 siblings, 1 reply; 6+ messages in thread
From: Dominik 'Aeneas' Schnitzer @ 2004-01-07 17:50 UTC (permalink / raw)
  To: Takashi Iwai; +Cc: alsa-devel

On Mit, 2004-01-07 at 18:07, Takashi Iwai wrote: 
> the switch of "SB Live Analog/Digital" can be removed if it works for
> you.  it was set to make sure the center "analog" jack works.
> (in the recent models, the digital out is shared with the center/lfe
> jack.)
> with my emu10k1 board, i don't get any valid signals over
> center/digital jack unless AC3 is played.  it might depend on the
> receiver.  perhaps creative has its own protocol?
> 
> but, anyway, "Wave Surround" and "Wave Center" don't make sense at
> all.  they are volumes of duplicated signals.  the volumes of
> surround/center/lfe channels are different mixer elements.

Hi,

I just rechecked everyting. You're right, it's just the "SB Live Analog/Digital"
switch/lock to "0" in EMU10K1.conf which needs to be removed, to make things work.
(I'm using a Creative Cambridge SoundWorks DTT3500 receiver, my sblive/emu10k1 card
has revision 07 (lspci))

As you pointed out, using the surround/center/lfe/wave volume controls everything can be
controlled. The WAVE* volume controls-stuff isn't neccessary.

So basically it boils down to...

--snip--
--- EMU10K1.conf.orig   2003-12-25 23:57:56.000000000 +0100
+++ EMU10K1.conf        2004-01-07 18:36:05.000000000 +0100
@@ -89,12 +89,6 @@
                                value true
                        }
                        {
-                               name "SB Live Analog/Digital Output
Jack"
-                               preserve true
-                               lock true
-                               value 0
-                       }
-                       {
                                name "EMU10K1 PCM Send Volume"
                                index { @func private_pcm_subdevice }
                                lock true
--snip--

...this change in EMU10K1.conf, to make surround51 work. Sorry for the
confusion, I hope this clarified things :-)

thanks && best wishes,
dominik.
-- 
Dominik 'Aeneas' Schnitzer <dominik@schnitzer.at>
http://www.schnitzer.at/dominik/ - Update 03/08/31: Birthday Party

PGP Fingerprint: E839 B9EA F518 899D AA35  BB67 0DBF 7AB2 5FE6 525A
PGP Public Key: http://www.schnitzer.at/dominik/public.key


-------------------------------------------------------
This SF.net email is sponsored by: Perforce Software.
Perforce is the Fast Software Configuration Management System offering
advanced branching capabilities and atomic changes on 50+ platforms.
Free Eval! http://www.perforce.com/perforce/loadprog.html

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [PATCH] EMU10K1.conf
  2004-01-07 17:50       ` Dominik 'Aeneas' Schnitzer
@ 2004-01-07 18:09         ` Takashi Iwai
  0 siblings, 0 replies; 6+ messages in thread
From: Takashi Iwai @ 2004-01-07 18:09 UTC (permalink / raw)
  To: Dominik 'Aeneas' Schnitzer; +Cc: alsa-devel

At Wed, 07 Jan 2004 18:50:42 +0100,
Dominik 'Aeneas' Schnitzer wrote:
> 
> On Mit, 2004-01-07 at 18:07, Takashi Iwai wrote: 
> > the switch of "SB Live Analog/Digital" can be removed if it works for
> > you.  it was set to make sure the center "analog" jack works.
> > (in the recent models, the digital out is shared with the center/lfe
> > jack.)
> > with my emu10k1 board, i don't get any valid signals over
> > center/digital jack unless AC3 is played.  it might depend on the
> > receiver.  perhaps creative has its own protocol?
> > 
> > but, anyway, "Wave Surround" and "Wave Center" don't make sense at
> > all.  they are volumes of duplicated signals.  the volumes of
> > surround/center/lfe channels are different mixer elements.
> 
> Hi,
> 
> I just rechecked everyting. You're right, it's just the "SB Live Analog/Digital"
> switch/lock to "0" in EMU10K1.conf which needs to be removed, to make things work.
> (I'm using a Creative Cambridge SoundWorks DTT3500 receiver, my sblive/emu10k1 card
> has revision 07 (lspci))
> 
> As you pointed out, using the surround/center/lfe/wave volume controls everything can be
> controlled. The WAVE* volume controls-stuff isn't neccessary.
> 
> So basically it boils down to...

ok, then i'll comment out this part on the cvs.

thanks for the confirmation.


Takashi


-------------------------------------------------------
This SF.net email is sponsored by: Perforce Software.
Perforce is the Fast Software Configuration Management System offering
advanced branching capabilities and atomic changes on 50+ platforms.
Free Eval! http://www.perforce.com/perforce/loadprog.html

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2004-01-07 18:09 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-12-27  0:31 [PATCH] EMU10K1.conf Dominik 'Aeneas' Schnitzer
2004-01-05 16:51 ` Takashi Iwai
2004-01-06 11:23   ` Dominik 'Aeneas' Schnitzer
2004-01-07 17:07     ` Takashi Iwai
2004-01-07 17:50       ` Dominik 'Aeneas' Schnitzer
2004-01-07 18:09         ` Takashi Iwai

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.