2 Replies Latest reply on Dec 30, 2014 2:10 PM by AlexT_Intel

    How to config usb microphone in Edison?

    josper04

      Hi people!

       

      I'm starting with Intel Edison, I'm trying to connect a microphone to the board, but I can't make it work.


      I already installed packages:

      • alsa (v 1.0.27)
      • alsa-utils (v 1.0.27)
      • kernel-module-snd-usb-audio (v 3.10.17)
      • libusb (v 1.0)
      • libav (v 0.8.9)

       

      I connected my microphone in miniUSB input (J16) with usbOTG.

      IMG_20141213_105120.jpg

       

      If I run:

      root@edison:~# alsamixer

      Captura de pantalla1.png


      root@edison:~# lsusb

      Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

      Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub

       

      root@edison:~# arecord -l

      **** List of CAPTURE Hardware Devices ****

      card 0: Loopback [Loopback], device 0: Loopback PCM [Loopback PCM]

        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: Loopback [Loopback], device 1: Loopback PCM [Loopback PCM]

        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

       

      root@edison:~# arecord -L

      null

          Discard all samples (playback) or generate zero samples (capture)

      default:CARD=Loopback

          Loopback, Loopback PCM

          Default Audio Device

      sysdefault:CARD=Loopback

          Loopback, Loopback PCM

          Default Audio Device

       

      root@edison:~# dmesg | grep -i usb

      [0.204562] usbcore: registered new interface driver usbfs
      [0.204662] usbcore: registered new interface driver hub
      [0.204870] usbcore: registered new device driver usb
      [0.763611] usbcore: registered new interface driver asix
      [0.763694] usbcore: registered new interface driver cdc_subset
      [0.763826] usbcore: registered new interface driver cdc_ncm
      [0.766295] ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
      [0.766637] usbcore: registered new interface driver cdc_acm
      [0.766654] cdc_acm: USB Abstract Control Model driver for USB modems and ISDN adapters
      [0.766764] usbcore: registered new interface driver usb-storage
      [0.766953] usbcore: registered new interface driver usbserial
      [0.767035] usbcore: registered new interface driver pl2303
      [0.767104] usbserial: USB Serial support registered for pl2303
      [1.585718] usbcore: registered new interface driver usbhid
      [1.585738] usbhid: USB HID core driver
      [1.657393] pmic_ccsm pmic_ccsm: USB ID Detected. Notifying OTG driver
      [2.464360] systemd[1]: Expecting device sys-subsystem-net-devices-usb0.device...
      [4.673415] usb0: MAC 02:00:86:ef:ec:7a
      [4.673437] usb0: HOST MAC f6:17:e1:7c:cf:44
      [5.664256] dwc3-host dwc3-host.2: new USB bus registered, assigned bus number 1
      [5.664713] usb usb1: New USB device found, idVendor=1d6b, idProduct=0002
      [5.664736] usb usb1: New USB device strings: Mfr=3, Product=2, SerialNumber=1
      [5.664756] usb usb1: Product: xHCI Host Controller
      [5.664775] usb usb1: Manufacturer: Linux 3.10.17-poky-edison+ dwc-xhci
      [5.664794] usb usb1: SerialNumber: dwc3-host.2
      [5.666001] hub 1-0:1.0: USB hub found
      [5.667308] dwc3-host dwc3-host.2: new USB bus registered, assigned bus number 2
      [5.667473] usb usb2: New USB device found, idVendor=1d6b, idProduct=0003
      [5.667497] usb usb2: New USB device strings: Mfr=3, Product=2, SerialNumber=1
      [5.667517] usb usb2: Product: xHCI Host Controller
      [5.667536] usb usb2: Manufacturer: Linux 3.10.17-poky-edison+ dwc-xhci
      [5.667555] usb usb2: SerialNumber: dwc3-host.2
      [5.668807] hub 2-0:1.0: USB hub found
      [8.811798] IPv6: ADDRCONF(NETDEV_UP): usb0: link is not ready

      [ 3784.544257] pmic_ccsm pmic_ccsm: USB ID Removed. Notifying OTG driver

      [ 3784.603975] usb usb2: USB disconnect, device number 1

      [ 3784.605406] dwc3-host dwc3-host.2: USB bus 2 deregistered

      [ 3784.605831] usb usb1: USB disconnect, device number 1

      [ 3784.607255] dwc3-host dwc3-host.2: USB bus 1 deregistered

      [ 3797.938268] pmic_ccsm pmic_ccsm: USB ID Detected. Notifying OTG driver

      [ 3798.802915] dwc3-host dwc3-host.2: new USB bus registered, assigned bus number 1

      [ 3798.803308] usb usb1: New USB device found, idVendor=1d6b, idProduct=0002

      [ 3798.803332] usb usb1: New USB device strings: Mfr=3, Product=2, SerialNumber=1

      [ 3798.803352] usb usb1: Product: xHCI Host Controller

      [ 3798.803371] usb usb1: Manufacturer: Linux 3.10.17-poky-edison+ dwc-xhci

      [ 3798.803390] usb usb1: SerialNumber: dwc3-host.2

      [ 3798.804456] hub 1-0:1.0: USB hub found

      [ 3798.811816] dwc3-host dwc3-host.2: new USB bus registered, assigned bus number 2

      [ 3798.812925] usb usb2: New USB device found, idVendor=1d6b, idProduct=0003

      [ 3798.812952] usb usb2: New USB device strings: Mfr=3, Product=2, SerialNumber=1

      [ 3798.812973] usb usb2: Product: xHCI Host Controller

      [ 3798.812992] usb usb2: Manufacturer: Linux 3.10.17-poky-edison+ dwc-xhci

      [ 3798.813011] usb usb2: SerialNumber: dwc3-host.2

      [ 3798.816157] hub 2-0:1.0: USB hub found

       

      If I connect microphone in my laptop. I get:

      josue@laptop-pc ~ $ lsusb

      Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

      Bus 008 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub

      Bus 007 Device 002: ID 0403:6001 Future Technology Devices International, Ltd FT232 USB-Serial (UART) IC

      Bus 007 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub

      Bus 006 Device 004: ID 0d8c:0008 C-Media Electronics, Inc.

      Bus 006 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub

      Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

      Bus 005 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub

      Bus 004 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub

      Bus 003 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub

        • 1. Re: How to config usb microphone in Edison?
          Intel_Alvarado

          Hi josper04,

           

          Take a look at this link  . Make sure you have the snd-bcm2835 module enabled sudo modprobe snd_bcm2835. Also, make sure you have installed the alsa-utils, alsa-firmware, alsa-lib and alsa-plugins packages.

           

          Regards

          Sergio

          • 2. Re: How to config usb microphone in Edison?
            AlexT_Intel

            I would say the reason is quite different here, Sergio

             

            josper04, the microUSB connector you're connecting your device to only supports USB device mode (see USB section of the Intel® Edison Arduino Board Hardware Guide for details), so it won't recognize any peripheral devices there - it's the Edison itself who acts as a peripheral in this case.

             

            To have your microphone (rather - USB sound card I see on your photo) recognized you need to plug it into that full-size USB A port near the power plug (don't forget to flip the small mechanical switch closer to it, to activate).

             

            Try connecting it like that and post the same output you posted initially (which is BTW exactly what is needed to start troubleshooting this sort of issue - kudos for formulating the question properly).