UART communication with Sensirion sensor

I have attached a Sensirion SPS30 sensor to the board via USB. It does show up when I check with dmesg

[27852.844668] usb 1-4: new full-speed USB device number 4 using tegra-xusb
[27853.000282] usb 1-4: New USB device found, idVendor=0403, idProduct=6001, bcdDevice= 6.00
[27853.000310] usb 1-4: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[27853.000320] usb 1-4: Product: FT232R USB UART
[27853.000327] usb 1-4: Manufacturer: FTDI
[27853.000334] usb 1-4: SerialNumber: AB0LNBX2
[27853.008201] ftdi_sio 1-4:1.0: FTDI USB Serial Device converter detected
[27853.009003] usb 1-4: Detected FT232RL
[27853.010305] gpiochip3: registered GPIOs 301 to 304 on ftdi-cbus
[27853.010666] usb 1-4: FTDI USB Serial Device converter now attached to ttyUSB0

However, when I attempt to use this driver I get this error:

Error opening UART. Ensure it's not otherwise used / UART init failed

How to troubleshoot this issue?

Look at the permissions. Assuming it is “/dev/ttyUSB0”:
ls -l /dev/ttyUSB0

Normally an unused UART will be group “dialout”. If the group is “tty”, then it is being used by a serial console (not likely). It is possible that the error message is just inaccurate and it is really telling you “permission denied”. If it is group dialout, and you have not added your user to that group, then do so now and try again. Assuming your user login name is “nvidia” it would work like this:
sudo usermod -aG dialout nvidia
(this appends group dialout as a supplemental group to user nvidia)

Thank you so much, fixing permissions solved this issue.

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