Linux Sound

ALSA

These notes relate to Debian 4.0 (Etch).

  • alsaconf - reconfigures sound card and loads appropriate modules

  • alsamixer - Set volumes and unmute sound

  • alsactl store

Most of the time running alsaconf unloads and reloads the modules in a working order, but needs doing after each reboot for me.

Note: For some reason alsaconf is not distributed with the alsa-tools package in Ubuntu's 7.10 Gutsy Gibbon. Neither is it included in Debian 6.0 (Squeeze).

  • aplay - (alsa-utils package) plays sound files using ALSA

List ALSA Devices

$ aplay -l
$ cat /proc/asound/cards

Replacing config files (Debian 4.0 Etch)

Backup your system first

  • apt-get remove --purge alsa-utils modutils alsa-base discover

  • apt-get install alsa-utils modutils alsa-base discover

  • update-modules

Others to try re-installing after purge

  • linux-sound-base
  • oss-compat
  • alsa-oss

In the end I identified snd_intel8x0m was listed by lsmod when things were not working, but not listed when they were! I edited /etc/modprobe.d/alsa-base and uncommented the line. Problem solved!

  • # blacklist snd-intel8x0m

Recording Desktop Session

recordmydesktop can be used to record a desktop session, both sound and video.

On a Debian 8 (Jessie), common usage is:

$ recordmydesktop --device pulse

Use the Pulse Audio Volume Control (pavucontrol) application to set the recording device. Whilst recordmydesktop is running, select the 'Recording' tab, then select 'Monitor of Built-in Audio' or similarly named option. You can also control the recording level there.

-- Frank Dean - 16 May 2016

MPEG-4 Audio (.m4a) File Format

Sets the audio bit rate to 256k.

$ ffmpeg -i input.m4a -acodec mp3 -b:a 256k output.mp3

Optionally, set the id3v2 tag to version 2.3 instead of the default 2.4:

$ ffmpeg -i input.m4a -acodec mp3 -b:a 256k -id3v2_version 3 output.mp3

You can view the file's metadata with:

$ ffmpeg -i input.m4a -f ffmetadata -

See also:

-- Frank Dean - 27 Jun 2017

AMR File Format

$ mplayer -ao pcm:fast:file=recording.wav recording.amr
$ lame recording.wav recording.mp3
$ oggenc -o recording.ogg recording.wav

See:

Dell Inspiron 1525 Ubuntu 7.10 Gutsy Gibbon - No Sound

Fixed by:

# cat >>/etc/modprobe.d/alsa-base <<EOF
# Ubuntu Bug # 131133
options snd-hda-intel model=3stack
EOF

See https://wiki.ubuntu.com/GutsyIntelHDAudioController

Resources

Related Topics: SkypeSound, BlueTooth

-- Frank Dean - 24 Apr 2007