Tenho problemas ao usar o dispositivo hid feito por mim no meu Ubuntu 17.10. Funciona bem no Windows e em outra máquina com o Kubuntu 18.04.
Eu já removi todas as minhas regras do udev, reiniciei o udev, reiniciei o PC, mas nada muda.
Sempre que eu conecto o dispositivo, ele é adicionado e removido imediatamente.
Aqui está a udevadm monitor
saída:
KERNEL[6204.330291] add /devices/pci0000:00/0000:00:1c.5/0000:06:00.0/usb5/5-1/5-1.4 (usb)
KERNEL[6204.332824] add /devices/pci0000:00/0000:00:1c.5/0000:06:00.0/usb5/5-1/5-1.4/5-1.4:1.0 (usb)
KERNEL[6204.337649] add /devices/pci0000:00/0000:00:1c.5/0000:06:00.0/usb5/5-1/5-1.4/5-1.4:1.0/0003:0483:5750.0006 (hid)
KERNEL[6204.337676] add /class/usbmisc (class)
KERNEL[6204.337781] add /devices/pci0000:00/0000:00:1c.5/0000:06:00.0/usb5/5-1/5-1.4/5-1.4:1.0/usbmisc/hiddev0 (usbmisc)
KERNEL[6204.337902] add /devices/pci0000:00/0000:00:1c.5/0000:06:00.0/usb5/5-1/5-1.4/5-1.4:1.0/0003:0483:5750.0006/hidraw/hidraw3 (hidraw)
UDEV [6204.339176] add /class/usbmisc (class)
UDEV [6204.342657] add /devices/pci0000:00/0000:00:1c.5/0000:06:00.0/usb5/5-1/5-1.4 (usb)
KERNEL[6204.343301] remove /devices/pci0000:00/0000:00:1c.5/0000:06:00.0/usb5/5-1/5-1.4/5-1.4:1.0/usbmisc/hiddev0 (usbmisc)
KERNEL[6204.343321] remove /usbmisc (class)
KERNEL[6204.343441] remove /devices/pci0000:00/0000:00:1c.5/0000:06:00.0/usb5/5-1/5-1.4/5-1.4:1.0/0003:0483:5750.0006/hidraw/hidraw3 (hidraw)
KERNEL[6204.343467] remove /devices/pci0000:00/0000:00:1c.5/0000:06:00.0/usb5/5-1/5-1.4/5-1.4:1.0/0003:0483:5750.0006 (hid)
UDEV [6204.344076] remove /usbmisc (class)
UDEV [6204.349535] add /devices/pci0000:00/0000:00:1c.5/0000:06:00.0/usb5/5-1/5-1.4/5-1.4:1.0 (usb)
UDEV [6204.353769] add /devices/pci0000:00/0000:00:1c.5/0000:06:00.0/usb5/5-1/5-1.4/5-1.4:1.0/0003:0483:5750.0006 (hid)
UDEV [6204.353793] add /devices/pci0000:00/0000:00:1c.5/0000:06:00.0/usb5/5-1/5-1.4/5-1.4:1.0/usbmisc/hiddev0 (usbmisc)
UDEV [6204.353805] remove /devices/pci0000:00/0000:00:1c.5/0000:06:00.0/usb5/5-1/5-1.4/5-1.4:1.0/usbmisc/hiddev0 (usbmisc)
UDEV [6204.353819] add /devices/pci0000:00/0000:00:1c.5/0000:06:00.0/usb5/5-1/5-1.4/5-1.4:1.0/0003:0483:5750.0006/hidraw/hidraw3 (hidraw)
UDEV [6204.354254] remove /devices/pci0000:00/0000:00:1c.5/0000:06:00.0/usb5/5-1/5-1.4/5-1.4:1.0/0003:0483:5750.0006/hidraw/hidraw3 (hidraw)
UDEV [6204.355106] remove /devices/pci0000:00/0000:00:1c.5/0000:06:00.0/usb5/5-1/5-1.4/5-1.4:1.0/0003:0483:5750.0006 (hid)
KERNEL[6204.921022] add /devices/parport0/ppdev0.0 (parport)
KERNEL[6204.921041] remove /devices/parport0/ppdev0.0 (parport)
UDEV [6204.922874] add /devices/parport0/ppdev0.0 (parport)
UDEV [6204.923290] remove /devices/parport0/ppdev0.0 (parport)
KERNEL[6209.296515] add /devices/parport0/ppdev0.0 (parport)
UDEV [6209.298376] add /devices/parport0/ppdev0.0 (parport)
KERNEL[6209.348220] remove /devices/parport0/ppdev0.0 (parport)
UDEV [6209.349800] remove /devices/parport0/ppdev0.0 (parport)
O mais estranho para mim são essas 2 linhas:
UDEV [6204.353819] add /devices/pci0000:00/0000:00:1c.5/0000:06:00.0/usb5/5-1/5-1.4/5-1.4:1.0/0003:0483:5750.0006/hidraw/hidraw3 (hidraw)
UDEV [6204.354254] remove /devices/pci0000:00/0000:00:1c.5/0000:06:00.0/usb5/5-1/5-1.4/5-1.4:1.0/0003:0483:5750.0006/hidraw/hidraw3 (hidraw)
Como resultado, não hidraw3
há hiddev0
arquivos em / dev
Por favor, sugira algo que eu possa tentar ver a razão desse comportamento.
Obrigado.
Atualizar Aqui está a saída dmesg:
[ 1897.305402] usb 3-6: new full-speed USB device number 13 using xhci_hcd
[ 1897.446811] usb 3-6: New USB device found, idVendor=0483, idProduct=5750
[ 1897.446820] usb 3-6: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[ 1897.446825] usb 3-6: Product: Smart Display
[ 1897.446829] usb 3-6: Manufacturer: QS
[ 1897.446832] usb 3-6: SerialNumber: 00000000001A
[ 1897.448254] hid-generic 0003:0483:5750.0008: hiddev0,hidraw3: USB HID v1.01 Device [QS Smart Display] on usb-0000:00:14.0-6/input0
dmesg
depois de conectar o dispositivo, para ver se há algum erro ou razão para o evento de remoção.