How to connect usb microphone to jetson tx2?

I have a USB blue yeti x microphone and I want to connect it to my Jetson tx2 developer kit.
When I connect the USB cable and run the lsusb command, it shows the microphone device as:
Bus 001 Device 004: ID 046d:0ad1 Logitech, Inc.

However, there is no device in setting/sound/input to select as a microphone.

I would appreciate it if you could help me to solve this issue.

You might find this URL useful (don’t know, I don’t have one of those microphones, but it looks like a nice mic):
https://www.omgubuntu.co.uk/2011/12/how-to-set-up-blue-yeti-mic-in-ubuntu

Regarding the part about no device special file, the driver to the microphone is separate from the USB pipe. However, if you monitor “dmesg --follow” when no microphone is plugged in, then you’ll see log lines added as you plug in the microphone. What are the new log lines you see from plugging in the microphone?

Also, what is the output (after the mic is plugged in) from “lsmod”? What do you see from:
sudo lsusb -d 046d:0ad1 -vvv

EDIT: I forgot to ask, does the URL I gave work on a Linux PC? If so, on that PC, what do you see in the “dmesg --follow” when you plug in the microphone (it might mention drivers)?

Thank you for your response.

when I plug in the microphone these lines appear in log lines of “dmesg --follow” command:

[19995.726945] tegra-xusb 3530000.xhci: exiting ELPG done
[19995.755106] usb usb2: usb_suspend_both: status 0
[19995.954858] usb 1-2: new full-speed USB device number 46 using tegra-xusb
[19995.978099] usb 1-2: New USB device found, idVendor=046d, idProduct=0ad1
[19995.978126] usb 1-2: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[19995.978142] usb 1-2: Product: Yeti X
[19995.978157] usb 1-2: Manufacturer: Blue Microphones
[19995.978171] usb 1-2: SerialNumber: 2231SG002DQ8_888-000480140206
[19996.002152] hid-generic 0003:046D:0AD1.0005: hidraw0: USB HID v1.11 Device [Blue Microphones Yeti X] on usb-3530000.xhci-2/input3

and when I run “sudo lsusb -d 046d:0ad1 -vvv” while the mic is plugged in, I see blow log:

Bus 001 Device 049: ID 046d:0ad1 Logitech, Inc.
Device Descriptor:
bLength 18
bDescriptorType 1
bcdUSB 2.00
bDeviceClass 0 (Defined at Interface level)
bDeviceSubClass 0
bDeviceProtocol 0
bMaxPacketSize0 64
idVendor 0x046d Logitech, Inc.
idProduct 0x0ad1
bcdDevice e.02
iManufacturer 1 Blue Microphones
iProduct 2 Yeti X
iSerial 3 2231SG002DQ8_888-000480140206
bNumConfigurations 1
Configuration Descriptor:
bLength 9
bDescriptorType 2
wTotalLength 232
bNumInterfaces 4
bConfigurationValue 1
iConfiguration 0
bmAttributes 0xc0
Self Powered
MaxPower 500mA
Interface Descriptor:
bLength 9
bDescriptorType 4
bInterfaceNumber 0
bAlternateSetting 0
bNumEndpoints 0
bInterfaceClass 1 Audio
bInterfaceSubClass 1 Control Device
bInterfaceProtocol 0
iInterface 0
AudioControl Interface Descriptor:
bLength 10
bDescriptorType 36
bDescriptorSubtype 1 (HEADER)
bcdADC 1.00
wTotalLength 72
bInCollection 2
baInterfaceNr( 0) 1
baInterfaceNr( 1) 2
AudioControl Interface Descriptor:
bLength 12
bDescriptorType 36
bDescriptorSubtype 2 (INPUT_TERMINAL)
bTerminalID 2
wTerminalType 0x0101 USB Streaming
bAssocTerminal 0
bNrChannels 2
wChannelConfig 0x0003
Left Front (L)
Right Front (R)
iChannelNames 0
iTerminal 0
AudioControl Interface Descriptor:
bLength 10
bDescriptorType 36
bDescriptorSubtype 6 (FEATURE_UNIT)
bUnitID 6
bSourceID 2
bControlSize 1
bmaControls( 0) 0x03
Mute Control
Volume Control
bmaControls( 1) 0x00
bmaControls( 2) 0x00
iFeature 0
AudioControl Interface Descriptor:
bLength 9
bDescriptorType 36
bDescriptorSubtype 3 (OUTPUT_TERMINAL)
bTerminalID 4
wTerminalType 0x0301 Speaker
bAssocTerminal 0
bSourceID 6
iTerminal 0
AudioControl Interface Descriptor:
bLength 12
bDescriptorType 36
bDescriptorSubtype 2 (INPUT_TERMINAL)
bTerminalID 1
wTerminalType 0x0201 Microphone
bAssocTerminal 0
bNrChannels 2
wChannelConfig 0x0003
Left Front (L)
Right Front (R)
iChannelNames 0
iTerminal 0
AudioControl Interface Descriptor:
bLength 10
bDescriptorType 36
bDescriptorSubtype 6 (FEATURE_UNIT)
bUnitID 5
bSourceID 1
bControlSize 1
bmaControls( 0) 0x03
Mute Control
Volume Control
bmaControls( 1) 0x00
bmaControls( 2) 0x00
iFeature 0
AudioControl Interface Descriptor:
bLength 9
bDescriptorType 36
bDescriptorSubtype 3 (OUTPUT_TERMINAL)
bTerminalID 3
wTerminalType 0x0101 USB Streaming
bAssocTerminal 0
bSourceID 5
iTerminal 0
Interface Descriptor:
bLength 9
bDescriptorType 4
bInterfaceNumber 1
bAlternateSetting 0
bNumEndpoints 0
bInterfaceClass 1 Audio
bInterfaceSubClass 2 Streaming
bInterfaceProtocol 0
iInterface 0
Interface Descriptor:
bLength 9
bDescriptorType 4
bInterfaceNumber 1
bAlternateSetting 1
bNumEndpoints 1
bInterfaceClass 1 Audio
bInterfaceSubClass 2 Streaming
bInterfaceProtocol 0
iInterface 0
AudioStreaming Interface Descriptor:
bLength 7
bDescriptorType 36
bDescriptorSubtype 1 (AS_GENERAL)
bTerminalLink 2
bDelay 1 frames
wFormatTag 1 PCM
AudioStreaming Interface Descriptor:
bLength 14
bDescriptorType 36
bDescriptorSubtype 2 (FORMAT_TYPE)
bFormatType 1 (FORMAT_TYPE_I)
bNrChannels 2
bSubframeSize 3
bBitResolution 24
bSamFreqType 2 Discrete
tSamFreq[ 0] 44100
tSamFreq[ 1] 48000
Endpoint Descriptor:
bLength 9
bDescriptorType 5
bEndpointAddress 0x01 EP 1 OUT
bmAttributes 1
Transfer Type Isochronous
Synch Type None
Usage Type Data
wMaxPacketSize 0x0120 1x 288 bytes
bInterval 1
bRefresh 0
bSynchAddress 0
AudioControl Endpoint Descriptor:
bLength 7
bDescriptorType 37
bDescriptorSubtype 1 (EP_GENERAL)
bmAttributes 0x01
Sampling Frequency
bLockDelayUnits 0 Undefined
wLockDelay 0 Undefined
Interface Descriptor:
bLength 9
bDescriptorType 4
bInterfaceNumber 2
bAlternateSetting 0
bNumEndpoints 0
bInterfaceClass 1 Audio
bInterfaceSubClass 2 Streaming
bInterfaceProtocol 0
iInterface 0
Interface Descriptor:
bLength 9
bDescriptorType 4
bInterfaceNumber 2
bAlternateSetting 1
bNumEndpoints 1
bInterfaceClass 1 Audio
bInterfaceSubClass 2 Streaming
bInterfaceProtocol 0
iInterface 0
AudioStreaming Interface Descriptor:
bLength 7
bDescriptorType 36
bDescriptorSubtype 1 (AS_GENERAL)
bTerminalLink 3
bDelay 1 frames
wFormatTag 1 PCM
AudioStreaming Interface Descriptor:
bLength 14
bDescriptorType 36
bDescriptorSubtype 2 (FORMAT_TYPE)
bFormatType 1 (FORMAT_TYPE_I)
bNrChannels 2
bSubframeSize 3
bBitResolution 24
bSamFreqType 2 Discrete
tSamFreq[ 0] 44100
tSamFreq[ 1] 48000
Endpoint Descriptor:
bLength 9
bDescriptorType 5
bEndpointAddress 0x82 EP 2 IN
bmAttributes 1
Transfer Type Isochronous
Synch Type None
Usage Type Data
wMaxPacketSize 0x0126 1x 294 bytes
bInterval 1
bRefresh 0
bSynchAddress 0
AudioControl Endpoint Descriptor:
bLength 7
bDescriptorType 37
bDescriptorSubtype 1 (EP_GENERAL)
bmAttributes 0x01
Sampling Frequency
bLockDelayUnits 0 Undefined
wLockDelay 0 Undefined
Interface Descriptor:
bLength 9
bDescriptorType 4
bInterfaceNumber 3
bAlternateSetting 0
bNumEndpoints 2
bInterfaceClass 3 Human Interface Device
bInterfaceSubClass 0 No Subclass
bInterfaceProtocol 0 None
iInterface 0
HID Device Descriptor:
bLength 9
bDescriptorType 33
bcdHID 1.11
bCountryCode 0 Not supported
bNumDescriptors 1
bDescriptorType 34 Report
wDescriptorLength 139
Report Descriptors:
** UNAVAILABLE **
Endpoint Descriptor:
bLength 7
bDescriptorType 5
bEndpointAddress 0x83 EP 3 IN
bmAttributes 3
Transfer Type Interrupt
Synch Type None
Usage Type Data
wMaxPacketSize 0x0040 1x 64 bytes
bInterval 10
Endpoint Descriptor:
bLength 7
bDescriptorType 5
bEndpointAddress 0x03 EP 3 OUT
bmAttributes 3
Transfer Type Interrupt
Synch Type None
Usage Type Data
wMaxPacketSize 0x0040 1x 64 bytes
bInterval 10
Device Status: 0x0001
Self Powered

The link you sent me works fine for Linux PC and the following line will appear in the log file of “dmesg --follow” as I plug in the mic:

[ 148.783078] usb 3-2: new full-speed USB device number 7 using xhci_hcd
[ 149.315628] usb 3-2: New USB device found, idVendor=046d, idProduct=0ad1
[ 149.315631] usb 3-2: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[ 149.315632] usb 3-2: Product: Yeti X
[ 149.315633] usb 3-2: Manufacturer: Blue Microphones
[ 149.315634] usb 3-2: SerialNumber: 2231SG002DQ8_888-000480140206
[ 149.315719] usb 3-2: ep 0x83 - rounding interval to 64 microframes, ep desc says 80 microframes
[ 149.315722] usb 3-2: ep 0x3 - rounding interval to 64 microframes, ep desc says 80 microframes
[ 149.350022] hid-generic 0003:046D:0AD1.0004: hiddev0,hidraw1: USB HID v1.11 Device [Blue Microphones Yeti X] on usb-0000:03:00.0-2/input3

and microphone will show up in “setting/sound/input” and it works fine, however in jetson tx2, nothing will show up in the sound setting as an input device.

I won’t be able to answer what the final software requirement is for the microphone, but it looks like the basics are in place. There is probably other user space software needed. However, device special files can have different names depending on drivers and load order. What do you see from:
find /dev -name 'hid*'
(these are “Human Interface Devices”…some drivers for this come with USB, but these are not actually USB drivers; they are drivers for devices following a standard API which connect over USB, and having those indicates you have the driver)

thank you for the quick reply.

when I run "find /dev -name ‘hid*’ " on jetson tx2, I see:
/dev/hidraw0

I also should note that I use the remote desktop connection to connect the jetson board via LAN IP address. Do you think it might cause the problem? but I set the remote audio setting to play on the remote computer, not on the host.

I also have the same problem with the Focusrite Scarlett audio interface. when I connect its USB cable to the jetson board, nothing will show up in the setting as an input or output device.

I should mention that I flashed the board with Jetpack 4.6.3 and ubuntu 18.04.6 is running on jetson tx2.

Every X server (GUI) loads input devices upon startup of that server. It also dynamically loads the NVIDIA GPU driver (if it can’t, then you can’t use GPU acceleration, including CUDA and display). The drivers are binary, which means that the server has to (A) be configured to load the particular drivers for that release ABI, and (B) actually be ABI compatible. An example problem is that an Xorg server upgrade to a completely new release will fail to load the GUI since it can’t load the old NVIDIA driver’s ABI.

A server normally is an API to interact with a buffer. It just happens that by default the buffer is available to the GPU (if the driver is present), and that the buffer has an HDMI or DP socket which a monitor can use to view that buffer.

A virtual server tends to have a buffer too, but instead of an HDMI cable it will also have the ability to network the buffer content. The server just wants a buffer accessible by some specific API, and is completely unaware of whether or not there is a monitor attached. Perhaps the buffer is simultaneously visible to both a local monitor and a network remote client. The software won’t care.

If you’ve replaced the GPU-driver-compatible server with a virtual server which is also compatible with this, then there is no problem. As soon as the server is incompatible with the GPU driver which NVIDIA provides you will probably lose video. This is just the most common problem people see when working with X server changes. The same is also true for input devices: Mice, keyboards, and microphones have dynamic plugin to the X server just like the GUI driver does. Should they break, or simply not be configured, then those components will fail.

What I suggest is to first make sure which X server designation is involved so you can look at the correct log. While you are logged in to that GUI (not remotely…I assume the mic is connected to the Jetson itself and that you are working from the Jetson), in a console, what do you see from:
echo $DISPLAY

Most likely it is “:0”. However, maybe it is “:1” or “:10”. Take that number, and use it to get this file (I’m assuming it is “:0”, but adjust for your case):
/var/log/Xorg.0.log
(so if it is “:1”, then “/var/log/Xorg.1.log”)

Attach that to the forum. There will be a note in the log regarding input devices which might say what is happening.

If you are actually using the remote desktop and a microphone on the remote PC, then a lot changes.
Most likely it is “:0

Thanks for the detailed information.

I am using my laptop as a host with the windows remote desktop connection to access jetson tx2. But I connected the microphone to the USB port of the jetson board, not my laptop.

I ran the “echo $DISPLAY” and it returned 10. However, there is no log file name “Xorg.10.log”. the name of the log file in the “/var/log/” directory is “Xorg.0.log” which I have attached to this message.

Xorg.0.log (12.5 KB)

What it comes down to is that you have the driver, but the X server does not know to associate it with this X server. This is a configuration I am not sure how to deal with.

Normally, if an application is started on the Jetson, then exporting the DISPLAY first causes the execution to become part of that server (it’d have to be executed by the owner of that session). So for example, let’s say that you are on Windows, but using a remote session to the Jetson. If you started firefox from the virtual desktop, then it automatically exports “DISPLAY=:10”; but if you were to use ssh from Windows to the Jetson, and start firefox without export, then it would fail since it does not know what context to use. If you use ssh from Windows to the Jetson, and “export DISPLAY=:10” before starting firefox, then firefox would appear within that virtual session.

The microphone has a device special file which is really part of a driver. This is not a user space application. I don’t know how a session binds that device. If you were to start an application which uses that device, and if you first export (either automatically or manually) the DISPLAY, then this in theory would work. What seems to be lacking is a mechanism to bind this device special file as a default to use when opening programs needing a microphone.

Does anyone here know how to specify that microphone (“/dev/hidraw0”, possibly needing a udev rule) to become a default input device when the microphone is on the Jetson, but the session is a remote desktop on Windows?

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.