Subject: Re: mixer?
To: Rolf Grossmann <email@example.com>
From: Brandon Reed <firstname.lastname@example.org>
Date: 04/10/1995 21:41:42
On Mon, 10 Apr 1995, Rolf Grossmann wrote:
> on Mon, 10 Apr 1995 02:15:41 +0200 Brandon Reed wrote
> concerning "Re: mixer?" something like this:
> > Can anyone tell me what I can do to the mixer device once I've got it?
> Sure :) You can open it and use ioctl to set values.
> > ie: can I do something like:
> > echo volume=50 > /dev/mixer ??
> > It makes sense to me.
> No, you can't. And although it might be quite nice, I don't think we would
> like to have code for parsing this stuff inside the kernel. It really isn't
> that hard to write C code to do that stuff.
any samples floating around?
how about a mixer binary (stick it in as a small file in /usr/bin or
somewhere more appropriate ) that calls the mixer device and performs
the basic functions like main volume/gain/etc. If the mixer i/o is the same
on every platform it should be pretty standard, or if the io controls
are system dependent add it to the kernel make so that when someone
selects the audio device in their config it's automgaically produced for
their enjoyment. it doesn't have to be
pretty just functional If you use a well-defined set of codes it should
be exremely easy to parse. If people want some nifty X based applet they
can get one somewhere else. I don't think I should need to write my own
program just to turn down the volume.
Was there any functionality for this in the 1.0 soundblaster code?
I never used it so I don't know.
codes might be like:
mixer gain.play 100 (for 100%)
mixer volume 100
mixer gain.record 100
mixer right 50 (50% shift to right on a stereo card)
mixer left 50 ..
With the PAS there's about 4 possible input/output channels
(OUT/IN, MIC, INTERNAL, CD-internal)
and other gains that can be set as well like:
BASS, TREBLE, midi, balance
If the first field doesn't comply to a known variable die
if the second field > 100 or < 0 die
I could write this part but unfortunately I only know Fortran
and Basic :(
If someone can produce simple code other people can make it fancy later.
> > I tried the "GROSS audio tools" that were posted a while back
> > but when I try:
> > audioplay /dev/audio < /tmp/byte.au
> > it hangs the device [...]
> Hmmm cat /tmp/byte.au >/dev/audio works fine for me. But that audio code is
Yup I get audio files screaming out the speakers at me at max gain and max
volume, sounds _really_ crappy and the interupt click every half second
is really annoying, it shouldn't have to poll the sound cards interupt so
often, just open DMA and feed it I believe that's what it's there for.
This works for me as well, but the "GROSS audio tools" which were
posted on this list on Thu, 23 Feb 1995 08:39:31 don't work quite so well.
> quite new. Maybe your tools need some porting?
They were distributed here I assumed they were written for this purpose,
someone else reported that they worked for them so I grabbed to code from
my files and compiled it hoping it would have some sort of volume control,
when it wouldn't run I looked around for anything I could find on mixers
but there wasn't anything on the system or the source trees that was
self-obvious so I asked the first question (I've seen the /dev/mixer
device on linux machines that was my only clue)
Is there anything I need to add other thatn the device to get it to work?
> On the other hand, the fact that you couldn't kill the play process suggests
> some other, more severe, error.
quite severe really.
I couldn't suspend/kill/interupt anything the process.
> Bye, Rolf
Alaric, | Archery: A deeply seated hatred of paper with bright
Mka Brandon Reed | coloured circles printed on it.