6

This is aplay -l output from Raspberry Pi:

**** List of PLAYBACK Hardware Devices ****
card 0: ALSA [bcm2835 ALSA], device 0: bcm2835 ALSA [bcm2835 ALSA]
  Subdevices: 8/8
  Subdevice #0: subdevice #0
  Subdevice #1: subdevice #1
  Subdevice #2: subdevice #2
  Subdevice #3: subdevice #3
  Subdevice #4: subdevice #4
  Subdevice #5: subdevice #5
  Subdevice #6: subdevice #6
  Subdevice #7: subdevice #7
card 0: ALSA [bcm2835 ALSA], device 1: bcm2835 ALSA [bcm2835 IEC958/HDMI]
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 1: RPiCirrus [RPi-Cirrus], device 0: WM5102 AiFi wm5102-aif1-0 []
  Subdevices: 1/1
  Subdevice #0: subdevice #0

I try to record audio from Cirrus audio card with the arecord alsa command:

arecord -f S16_LE -c2  -D hw:1,0 -r 44100  ~/Desktop/test.wav

Should I set -D flag as

-D hw:1,0

or

-D plughw:1,0

and what is the difference between them?

Greenonline
  • 2,969
  • 5
  • 27
  • 38
tatiana_c
  • 163
  • 1
  • 5

1 Answers1

9

hw accesses the hardware device directly.

plughw inserts sample rate and format conversion plugins, if needed.

CL.
  • 571
  • 5
  • 9