925.532552] usb 1-1.2: usbfs: process 5519 (node) did not claim interface 0 before use
on hotplug events my iobroker javasscript adapter crashes:
host.ioBrokerPIB3
2020-10-29 11:59:45.379
error
instance system.adapter.javascript.1 terminated with code 1 (JS_CONTROLLER_STOPPED)
host.ioBrokerPIB3
2020-10-29 11:59:45.378
error
Caught by controller[0]: at Transfer.transferDone (/opt/iobroker/node_modules/iobroker.javascript/node_modules/usb/usb.js:454:10)
host.ioBrokerPIB3
2020-10-29 11:59:45.378
error
Caught by controller[0]: at InEndpoint.EventEmitter.emit (domain.js:483:12)
host.ioBrokerPIB3
2020-10-29 11:59:45.377
error
Caught by controller[0]: at InEndpoint.emit (events.js:314:20)
host.ioBrokerPIB3
2020-10-29 11:59:45.377
error
Caught by controller[0]: at Object.onceWrapper (events.js:420:28)
host.ioBrokerPIB3
2020-10-29 11:59:45.376
error
Caught by controller[0]: at InEndpoint. (/opt/iobroker/node_modules/iobroker.javascript/node_modules/node-co2-monitor/co2_monitor.js:90:33)
host.ioBrokerPIB3
2020-10-29 11:59:45.375
error
Caught by controller[0]: at Interface.attachKernelDriver (/opt/iobroker/node_modules/iobroker.javascript/node_modules/usb/usb.js:330:21)
host.ioBrokerPIB3
2020-10-29 11:59:45.374
error
Caught by controller[0]: Error: LIBUSB_ERROR_BUSY
javascript.1
2020-10-29 11:59:44.770
error
(1086) Error: LIBUSB_ERROR_BUSY at Interface.attachKernelDriver (/opt/iobroker/node_modules/iobroker.javascript/node_modules/usb/usb.js:330:21) at InEndpoint. (/opt/iobroker/node_mo
javascript.1
2020-10-29 11:59:44.769
error
(1086) Error: LIBUSB_ERROR_BUSY
javascript.1
2020-10-29 11:59:44.768
error
(1086) An error happened which is most likely from one of your scripts, but the originating script could not be detected.
(4453) Error: LIBUSB_ERROR_BUSY at Interface.attachKernelDriver (/opt/iobroker/node_modules/iobroker.javascript/node_modules/usb/usb.js:330:21) at InEndpoint. (/opt/iobroker/node_mo
javascript.1
2020-10-29 12:03:15.620
error
(4453) Error: LIBUSB_ERROR_BUSY
javascript.1
2020-10-29 12:03:15.619
error
(4453) An error happened which is most likely from one of your scripts, but the originating script could not be detected.
It seems like @humanhire did use and include everything right and he can't reproduce my issue.
It seems like it's related to lib_usb and raspberry pie and kernel.
Used https://github.com/huhamhire/node-co2-monitor/blob/master/co2_monitor.js
it detached kernel driver https://github.com/huhamhire/node-co2-monitor/blob/master/co2_monitor.js#L58
though i see at dmesg:
925.532552] usb 1-1.2: usbfs: process 5519 (node) did not claim interface 0 before use
on hotplug events my iobroker javasscript adapter crashes:
When I unbind the adapter myself echo '1-1.2:1.0' >/sys/bus/usb/drivers/usbfs/unbind
The adapter crashes again:
It seems like @humanhire did use and include everything right and he can't reproduce my issue. It seems like it's related to lib_usb and raspberry pie and kernel.
Can someone help me further? My udev rules are in place and I can read from the device. This is related to https://github.com/tessel/node-usb/issues/390
Thank you
Raspberry 3b+ Debian Buster Linux 5.4.72-v7+ #1356 SMP Thu Oct 22 13:56:54 BST 2020 armv7l GNU/Linux Node.js v12.19.0 NPM 6.14.8