I want to record sound from 2 devices simultaneously:internal micexternal usb webcam micUsing pulseaudio sound controller, I set either of these devices as default and could record sound with snd_pcm_open(&handle, default, SND_PCM_STREAM_CAPTURE, 0).But now I want to record sound from both devices simultaneously, so i have to opt for naming scheme mentioned here. However I have no success with couple of them.I thought this would solve my problem, but front:CARD=U0x46d0x825,DEV=0 didn't help as the name of device.I get these errors:ALSA lib pcm.c:2239:(snd_pcm_open_noupdate) Unknown PCM ALSA lib pcm.c:2239:(snd_pcm_open_noupdate) Unknown PCMALSA lib pcm_hw.c:1667:(_snd_pcm_hw_open) Invalid value for cardarecord -l gives me:# arecord -l**** List of CAPTURE Hardware Devices ****Home directory not accessible: Permission deniedcard 0: PCH [HDA Intel PCH], device 0: ALC662 rev1 Analog [ALC662 rev1 Analog]  Subdevices: 1/1  Subdevice #0: subdevice #0card 0: PCH [HDA Intel PCH], device 2: ALC662 rev1 Alt Analog [ALC662 rev1 Alt Analog]  Subdevices: 1/1  Subdevice #0: subdevice #0card 1: U0x46d0x825 [USB Device 0x46d:0x825], device 0: USB Audio [USB Audio]  Subdevices: 1/1  Subdevice #0: subdevice #0and # arecord -L gives:# arecord -Lnull    Discard all samples (playback) or generate zero samples (capture)pulse    PulseAudio Sound Serverdefault:CARD=PCH    HDA Intel PCH, ALC662 rev1 Analog    Default Audio Devicesysdefault:CARD=PCH    HDA Intel PCH, ALC662 rev1 Analog    Default Audio Devicefront:CARD=PCH,DEV=0    HDA Intel PCH, ALC662 rev1 Analog    Front speakerssurround40:CARD=PCH,DEV=0    HDA Intel PCH, ALC662 rev1 Analog    4.0 Surround output to Front and Rear speakerssurround41:CARD=PCH,DEV=0    HDA Intel PCH, ALC662 rev1 Analog    4.1 Surround output to Front, Rear and Subwoofer speakerssurround50:CARD=PCH,DEV=0    HDA Intel PCH, ALC662 rev1 Analog    5.0 Surround output to Front, Center and Rear speakerssurround51:CARD=PCH,DEV=0    HDA Intel PCH, ALC662 rev1 Analog    5.1 Surround output to Front, Center, Rear and Subwoofer speakerssurround71:CARD=PCH,DEV=0    HDA Intel PCH, ALC662 rev1 Analog    7.1 Surround output to Front, Center, Side, Rear and Woofer speakersdmix:CARD=PCH,DEV=0    HDA Intel PCH, ALC662 rev1 Analog    Direct sample mixing devicedmix:CARD=PCH,DEV=2    HDA Intel PCH, ALC662 rev1 Alt Analog    Direct sample mixing devicedsnoop:CARD=PCH,DEV=0    HDA Intel PCH, ALC662 rev1 Analog    Direct sample snooping devicedsnoop:CARD=PCH,DEV=2    HDA Intel PCH, ALC662 rev1 Alt Analog    Direct sample snooping devicehw:CARD=PCH,DEV=0    HDA Intel PCH, ALC662 rev1 Analog    Direct hardware device without any conversionshw:CARD=PCH,DEV=2    HDA Intel PCH, ALC662 rev1 Alt Analog    Direct hardware device without any conversionsplughw:CARD=PCH,DEV=0    HDA Intel PCH, ALC662 rev1 Analog    Hardware device with all software conversionsplughw:CARD=PCH,DEV=2    HDA Intel PCH, ALC662 rev1 Alt Analog    Hardware device with all software conversionsdefault:CARD=U0x46d0x825    USB Device 0x46d:0x825, USB Audio    Default Audio Devicesysdefault:CARD=U0x46d0x825    USB Device 0x46d:0x825, USB Audio    Default Audio Devicefront:CARD=U0x46d0x825,DEV=0    USB Device 0x46d:0x825, USB Audio    Front speakerssurround40:CARD=U0x46d0x825,DEV=0    USB Device 0x46d:0x825, USB Audio    4.0 Surround output to Front and Rear speakerssurround41:CARD=U0x46d0x825,DEV=0    USB Device 0x46d:0x825, USB Audio    4.1 Surround output to Front, Rear and Subwoofer speakerssurround50:CARD=U0x46d0x825,DEV=0    USB Device 0x46d:0x825, USB Audio    5.0 Surround output to Front, Center and Rear speakerssurround51:CARD=U0x46d0x825,DEV=0    USB Device 0x46d:0x825, USB Audio    5.1 Surround output to Front, Center, Rear and Subwoofer speakerssurround71:CARD=U0x46d0x825,DEV=0    USB Device 0x46d:0x825, USB Audio    7.1 Surround output to Front, Center, Side, Rear and Woofer speakersiec958:CARD=U0x46d0x825,DEV=0    USB Device 0x46d:0x825, USB Audio    IEC958 (S/PDIF) Digital Audio Outputdmix:CARD=U0x46d0x825,DEV=0    USB Device 0x46d:0x825, USB Audio    Direct sample mixing devicedsnoop:CARD=U0x46d0x825,DEV=0    USB Device 0x46d:0x825, USB Audio    Direct sample snooping devicehw:CARD=U0x46d0x825,DEV=0    USB Device 0x46d:0x825, USB Audio    Direct hardware device without any conversionsplughw:CARD=U0x46d0x825,DEV=0    USB Device 0x46d:0x825, USB Audio    Hardware device with all software conversionsSo what are the correct names I should give in to the above devices to record them simultaneously as per the ALSA specification?I don't want to use pulseaudio API.
what device name should I have to give in snd_pcm_open other than default
c;alsa