> > >> When I do a jumpstart install the machine is setup > with the default > >> built in speaker set up for audio output. I would > like to be able to > >> have each machine set up with the headphones set > up and the Line out > >> working. But having the built in speaker disabled. > Kind of the > >> opposite of the default settings in Solaris 10. > > Try "man audioplay"? Ignore the "play" part of the > command name, which > is just a decoy to make the command hard to find. It > says... > > The audioplay utility copies the named audio > files (or the > standard input if no filenames are present) > to the audio > device. If no input file is specified and > standard input is > a tty, the port, volume, and balance settings > specified on > the command line will be applied and the program > will exit. > So you would presumably use something like "audioplay > -p line" (but you > may need to make sure stdin is a TTY). Not sure that > you can specify > both headphones *and* line out with this command > though. But the source > code is public, so you could presumably fix this if > you really want.
Something that does this nicely already exists; google for audioctl.c solaris You may have to grab it out of the google cache and undo the html-ification; that's what I did, since the site was non-responsive. It looks like a fork or clone of something older by someone else, but of the same name (although the usage is different). Seems to work ok for me: ./audioctl -v =75 =headphone +speaker gain 75 29% balance 32 50% m+0 m+0% ports headphone unmuted Adjusted: gain 75 29% balance 32 50% m+0 m+0% ports speaker headphone unmuted One might want to re-implement this with a more civilized command line. But it does appear to do the job. This message posted from opensolaris.org
