Quote:
Originally Posted by knc1
[...]
Note 3:
It would be nice to play with this, to see if the OTG dongle support recently added to the silent Kindles could be made to support the microphone input. [...]
|
Okay, I did a test on my PW3 -- a KUAL extension that displays some audio stats, then attempts to record 10 seconds, and then play it back. Not successful. The script exited almost immediately, before it had time to record anything. Here is the script I launched from KUAL:
PHP Code:
root@kindle /]# cat /mnt/us/extensions/gmecho/bin/gmecho.sh
#!/bin/sh
(
echo " #> cat /proc/asound/cards"
cat /proc/asound/cards
echo " #> arecord -l"
arecord -l
echo " #> arecord -d 10 /tmp/test-mic.wav"
arecord -d 10 /tmp/test-mic.wav
echo " #> aplay /tmp/test-mic.wav"
aplay /tmp/test-mic.wav
) > /mnt/us/gmecho.log 2>&1
[root@kindle /]#
When that script was run from KUAL (after my PW3 stopped complaining about the missing voice file), with a headset and microphone inserted into the USB dongle, it created this log file:
PHP Code:
[root@kindle root]# cat /mnt/us/gmecho.log
#> cat /proc/asound/cards
0 [Set ]: USB-Audio - USB Headphone Set
USB Headphone Set at usb-fsl-ehci.0-1, full speed
#> arecord -l
**** List of CAPTURE Hardware Devices ****
card 0: Set [USB Headphone Set], device 0: USB Audio [USB Audio]
Subdevices: 1/1
Subdevice #0: subdevice #0
#> arecord -d 10 /tmp/test-mic.wav
Recording WAVE '/tmp/test-mic.wav' : Unsigned 8 bit, Rate 8000 Hz, Mono
Aborted by signal Terminated...
#> aplay /tmp/test-mic.wav
ALSA lib confmisc.c:768:(parse_card) cannot find card '0'
ALSA lib conf.c:4154:(_snd_config_evaluate) function snd_func_card_driver returned error: No such file or directory
ALSA lib confmisc.c:392:(snd_func_concat) error evaluating strings
ALSA lib conf.c:4154:(_snd_config_evaluate) function snd_func_concat returned error: No such file or directory
ALSA lib confmisc.c:1251:(snd_func_refer) error evaluating name
ALSA lib conf.c:4154:(_snd_config_evaluate) function snd_func_refer returned error: No such file or directory
ALSA lib conf.c:4633:(snd_config_expand) Evaluate error: No such file or directory
ALSA lib pcm.c:2211:(snd_pcm_open_noupdate) Unknown PCM default
aplay: main:608: audio open error: No such file or directory
[root@kindle root]#
When I run
twobob's "
Balsamic" demo (also from a KUAL extension), it does play audio (for awhile, before it segfaults on my PW3), but recording seems to not work, unless I need extra parameters on the "
arecord" command...
EDIT: Though as you can see, "aplay" was complaining about "no sound card" before it whined about a missing sound file. So twoboob's Balsamic demo MUST be accessing the sound hardware differently than arecord and aplay, because his demo works. So perhaps we CAN get microphone input to work, using whatever "trick" twobob used to get sound output working on these USB dongles.