LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General > LinuxQuestions.org Member Success Stories
User Name
Password
LinuxQuestions.org Member Success Stories Just spent four hours configuring your favorite program? Just figured out a Linux problem that has been stumping you for months?
Post your Linux Success Stories here.

Notices

Reply
 
Search this Thread
Old 02-19-2004, 02:07 PM   #1
farmerdan
Member
 
Registered: Feb 2004
Location: IA-MO State Line
Distribution: Ubuntu 10.04
Posts: 59

Rep: Reputation: 15
Sound System, CD/RW and Me Now All Play Well Together


This is going to be a long and involved post. If you're interested, grab your favorite beverage, put in a CD and kick your shoes off. The force will guide you, Young Skywalker.

Not only do I want to describe how I fixed something, but I also want to describe how and where I found the information to do so. I have seen here, and in other forums, many requests for help--including the specific problem that I just corrected--that go nowhere. I think that this phenomenon occurs when a poster doesn't supply enough specific information that a helper needs to help. When the poster is asked for more info, like "What are the results of cat /proc, the poster may or may not know where or how to get that info. [In this specific example, the request for more info is as non-specific as the request for help may have been.] One of my goals here is to demonstrate some of the where and how to find info.

First the basics: I run an Athlon AMD 1 Ghz. An Audigy2 Platinum-ex sound system drives Creative 6.1 speakers. I have a triple boot system--ME, XP and Linux--Mandrake 9.2--with two Western Digital 80G hard drives and an HP 300n DVD +RW(CD/RW) drive. I want to ultimately do the audio-video work that I did in W-w-w-in (I can't type it). Also have a printer and a scanner.

Basic Principle One: It took me awhile to realize that a super computer user like me didn't have a clue as to what to do in Linux. I developed the phrase, "I don't know what I don't know." To get help one must first ask a question. If one doesn't know enough to ask the question, how does one get help? The answer--RT?M (Editors Note: I do not include the "F" in that acronym because many people think it means something other than "Fine.")

But where is T?M? Many things are not included in the README for certain things--like ALSA drivers.
Code:
locate foo | less
is invaluable. I use less because I never know when my request is going to send zillions of pages of info flying past my eyes. There are lots and lots of documents that come with the kernel, the applications and the software packages. The output of locate will reveal the location of the documentation AND OTHER NEAT THINGS.

Basic Principle Two: The help one receives requires action. Posting "I think I should delete XXXX and substute a sim link to YYY. Any thoughts?" Many times brings no response.

I've found that it's more appropriate to take the action and then report on what happened--even if you broke it and fixed it again. I think that the other popular (?) operating system generates a gut level insecurity about changing things in the bowels of the computer. I know that I stared at my command line once for fifteen minutes before I hit "Enter" because of that.

If it's backed up you can't break it. I created a directory on another partition called SAVEMYA??. It has only files named *.unhose--modules.conf.unhose, for example. If I screw up, I need only
Code:
cp *.unhose /directory/realname
Problem Description: I had no sound in RedHat 9. I learned through the forums that OSS, the classic linux sound drivers didn't support my sound system and that only the version of emu10k1 on CVS at SourceForge supported it. I also learned through the forums that the ALSA drivers, which may replace OSS did support my sound system, but that they were not included in RedHat 9. The only way I could do that was to compile the drivers myself. I got so confused, I couldn't turn around. Then I learned that Mandrake 9.2 had native ALSA drivers and took the easy way out.

In Mandrake I had stereo only sound and only in my games--no cd's. Now the stage is set for the "rest of the story."

I searched this forum, and two others and googled ALSA. I found "ALSA-sound-mini-HOWTO" at The Linux Documentation Project [Another Editor's Note: The other HOWTO's mentioned in this post can be found here also.] In an obscure paragraph it said that the ALSA drivers, by default, are muted. To get sound I had to open a mixer and unmute the channels. I did this and low and behold, I could play files from the hard drive in any player that I had installed. However, I couldn't play cd's from any player except ALSA Player and they sounded weak and tinny.

I did a "locate" on somethingand this is when I discovered /usr/src/linux-2.22-26mdk/Documentation/. I learned that this directory exists with all distributions--it belongs to the kernel. In it I found ide.txt and ide-cd.txt which told me everything I wanted to know about ide drivers and cd drivers. "The Linux Loadable Kernel Module HOWTO"--which I believe now should be in every users library--taught me how to explore the /dev/ and /proc/ file systems.

Armed with all of this new knowlege I wanted to see what the computer was really doing. I'm sure that everyone has seen all those lines go screaming by at boot. Well, they contain a lot of debugging info and you can get them by
Code:
dmesg
This is another one in which you may wish to use | less. Another method is
Code:
dmesg | grep hdc                  /*for example/
With either of these methods you can "zero-in-on" what your looking for. My results, for the appropriate information, are
Code:
dmesg
ide_setup:  hdc=ide-scsi
....
hdc:  Hewlett-Packard DVD Writer 300, ATAPI CD/DVD-ROM drive
....
hdc:  attached ide-scsi driver
scsi0 : SCSI host adapter emulation for IDE ATAPI devices
           Vendor: HP        Model: DVD Writer 300n  Rev: 3.00
           Type:     CD-ROM                                       ANSI SCSI revision: 02
....
Attached scsi CD-ROM sr0 at scsi, channel 0, id0, lun0
sr0:  scsi3-mmc drive:  32x32x writer cd/rw xa/form2 cdda tray
Uniform CD-ROM driver Revision 3.12
If I were responding to a request for help on this issue this is exactly the information I would want the requester to supply. It has all I need and nothing else.

This told me--and I learned all of this by reading the documents that I have referenced--that my CDROM had been captured as hdc and assigned to scsi-emulation. It also told me that everything I had was recognized. I did
Code:
cat /proc/modules
anyway and verified that all the sound and bus drivers that I needed were active and ready to go. That meant that my problem was one of configuration and not ability.

In "The Linux 2.4 SCSI subsystem HOWTO" I learned that many cd reading, writing, recording, ripping and playing software NEED access to the CDROM via the scsi-emulation. This coupled with the info from dmesg told me that I had been looking in the wrong spot in /dev/. /dev/cdrom was trying to interact with the ide drivers and not the scsi emulation. I ran
Code:
 rm /dev/cdrom
ln -s /dev/hdc /dev/cdrom
Since I had learned that you can't play from a mounted device (ide-cd.txt) and since somewhere along the line /dev/cdrom0--which also pointed to the ide drives--existed I changed
  • etc/fstab
    from: none /mnt/cdrom supermount dev=dev/scd0...
    to: none /mnt/cdrom supermount dev=dev/cdrom0...

But now, I had NO SOUND IN ANY PLAYER. Back to the forums to yell for help. Someone brought up the question about the infamous little, four-wire connector that runs between the CD Drive and the sound card. Rats!!!!! I looked. Sure enough it wasn't hooked up. But, on the other hand there was no place on my sound card to connect it! Back to the forums searching for XMMS--I had chosen this one for my testing.

I discovered that there are two ways for a player to detect sound: 1)from the sound card and 2)directly from the cd. In the first casem, that infamous little wire needs to be hooked up--and I couldn't do it. For the second case, I discovered an input plugin for XMMS, xmms-cdread that is available in rpm format for most of the distros. (Google "xmms-cdread" and surf through the hits.) I installed that and NOW MY CD'S SOUND GREAT!!!!! Additionally, I don't have to mount and remount the file system for data cd's.

THE END

I know that this has been long. I wanted to talk about more than just the mechanics of what I did. I like to understand what I'm doing rather than just blindly following directions. I also hope that my description of the process was helpful to anyone else who is just starting out. I had a lot of frustration trying to "learn what I didn't know."

I still need to get the other players working, but it will probably be easy. I need to then make sure I can burn. Maybe tomorrow I will compile my own kernel.

Thanks for reading this.
 
Old 03-08-2004, 06:46 PM   #2
archlyn
Member
 
Registered: Jul 2003
Distribution: Gentoo Linux
Posts: 64

Rep: Reputation: 15
I loved your story. It reminded me of... well me, as I had acted on similar occasions. I applaud your tanacitry and congratulate you on your success, Kudos
 
Old 03-08-2004, 07:11 PM   #3
farmerdan
Member
 
Registered: Feb 2004
Location: IA-MO State Line
Distribution: Ubuntu 10.04
Posts: 59

Original Poster
Rep: Reputation: 15
Hey archlyn, thanks for the feedback. Yeah, it seems that a lot of the frustration in learning all this stuff is really laughable in hind sight.

As an epilogue to the stroy, I upgraded xmms and the initial problem started all over again--xmms-cdread doesn't work with the latest and greatest. I have obtained the kernel 2.6.3 source and am trying to upgrade--just to be able to manipulate my cd/dvd player/burner. This is a real story too. My first kernel.

There's not enough bandwidth for me to be able to post what would be a three volume book so far when that project is successful.

Thanks again.
 
Old 03-08-2004, 09:00 PM   #4
archlyn
Member
 
Registered: Jul 2003
Distribution: Gentoo Linux
Posts: 64

Rep: Reputation: 15
Wheeeeeee!!!! A kernel recompile! ALWAYS fun!! Ya know, in the scant few years that I've been trying to teach myself Linux, recompiling the kernel has always been the one thing that I've never had any luck at all in doing, Until the 2.6.x kernel series. I wish you the best of luck.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Trying to play sound in USB audio Micro System sanmartin Linux - Hardware 2 12-16-2005 04:11 PM
I can't hear any sound when I play a cd or mp3...but tested with system tools->Sound Niceman2005 Linux - General 6 10-31-2005 10:51 AM
play a song in remote system no sound suguname Linux - Networking 6 03-10-2005 02:44 AM
FC2: Sound Card (SiS SI7012) Detect But Donot Play Sound rajanaeem Linux - Hardware 0 10-22-2004 04:41 PM
Problems getting sound to play under Mandrake w/2 sound cards HGeneAnthony Linux - Hardware 1 07-02-2004 03:19 PM


All times are GMT -5. The time now is 01:31 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration