LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 08-12-2007, 06:53 PM   #1
ncsuapex
Member
 
Registered: Dec 2004
Location: Raleigh, NC
Distribution: CentOS 2.6.18-53.1.4.el5
Posts: 770

Rep: Reputation: 44
sox/lame playback problem(thumping sound)


background.

I have a am/fm stereo receiver connected to my line in on my PC. I used to be able to use the following command to record audio from the line in. It worked fine on my Slackware box. Long story short I am trying the same command using a Slax 5.1.8rc CD.

commandsupposed to be a one line command)

sox -t ossdsp -w -s -r 44100 -c 2 /dev/dsp -t raw - | lame -x -m s - /path/to/mp3.mp3

I have the path to mp3 going to a harddrive thats in the PC formatted with ext2
Ive tried playing it back with mplayer and kplayer


Problem is when I play it back it plays the audio but it has a "thumping" sound and I can't figure out why.

any ideas?


sox: Version 12.18.1
LAME version 3.96.1


I also posted this on the slax forum but figured someone here could help.


UPDATE:

sox -t ossdsp -w -s -r 44100 -c 2 /dev/dsp -t raw - | lame -x -m s - test.wav
Assuming raw pcm input file : Forcing byte-swapping
LAME version 3.96.1 (http://lame.sourceforge.net/)
Using polyphase lowpass filter, transition band: 17249 Hz - 17782 Hz
Encoding <stdin> to test.wav
Encoding as 44.1 kHz 128 kbps stereo MPEG-1 Layer III (11x) qval=3


mplayer test.wav
MPlayer 1.0pre8-3.4.6 (C) 2000-2006 MPlayer Team
CPU: Intel Celeron Covington/Pentium II Deschutes,Tonga/Pentium II Xeon (Family: 6, Model: 5, Stepping: 2)
CPUflags: MMX: 1 MMX2: 0 3DNow: 0 3DNow2: 0 SSE: 0 SSE2: 0
Compiled with runtime CPU detection.


Playing test.wav.
Audio file file format detected.
==========================================================================
Opening audio decoder: [mp3lib] MPEG layer-2, layer-3
AUDIO: 44100 Hz, 2 ch, s16le, 128.0 kbit/9.07% (ratio: 16000->176400)
Selected audio codec: [mp3] afm: mp3lib (mp3lib MPEG layer-2, layer-3)
==========================================================================
mcop warning: user defined signal handler found for SIG_PIPE, overriding
[AO ARTS] Connected to sound server.
[AO ARTS] Stream opened.
[AO ARTS] buffer size: 20480
[AO ARTS] buffer size: 2048
AO: [arts] 44100Hz 2ch s16le (2 bytes per sample)
Video: no video
Starting playback...
A: 1.5 (01.5) of 25.0 (25.0) 4.7%

Last edited by ncsuapex; 08-12-2007 at 07:01 PM. Reason: added info
 
Old 08-12-2007, 11:52 PM   #2
MS3FGX
LQ Guru
 
Registered: Jan 2004
Location: NJ, USA
Distribution: Slackware, Debian
Posts: 5,852

Rep: Reputation: 361Reputation: 361Reputation: 361Reputation: 361
It might help if you uploaded a short clip of the resulting audio file. Somebody with experience using SOX and LAME may recognize it and be able to diagnose the problem better.

I am going to assume the sound output is clean if you play a standard MP3 on this machine?
 
Old 08-13-2007, 09:54 AM   #3
ncsuapex
Member
 
Registered: Dec 2004
Location: Raleigh, NC
Distribution: CentOS 2.6.18-53.1.4.el5
Posts: 770

Original Poster
Rep: Reputation: 44
Ok this is weird...

more background:

The speakers play sound fine if:
It's a known good mp3 file (one that I didn't record myself)
I record an internet audio stream and play it back using mplayer


I took a mp3 I recorded using the above script and played it on another PC and it played fine..


 
  


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 On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Sound mixing using SOX IndianMaverick Linux - Software 0 05-17-2007 02:08 AM
LXer: E-Mail tunes with SoX the Swiss Army knife of sound LXer Syndicated Linux News 0 01-25-2007 11:54 PM
Soud Card configuration problem - ForteMedia FM801 with no sound playback easuter Linux - Hardware 10 01-04-2006 08:37 AM
Xawtv / Sox Sound problems (K7N2 w nvsound) conn-fused Linux - Software 0 10-07-2004 05:03 AM
CMedia sound - sox but no cat Rodney Riggs Linux - Newbie 4 08-26-2002 03:57 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 05:13 AM.

Main Menu
Advertisement
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
Open Source Consulting | Domain Registration