Hello, I recently bought a SANE-supported USB document scanner (Fujitsu S1300i), in the hope of using it on my OpenBSD desktop. After a bit of murking around with firmware blobs, I eventually managed to make it work once. At that is where I'm stuck.
To put it more precisely, after turning on the device, I get exactly once successful use of `scanimage`, and only timeouts afterwards. At first I thought of an issue with not sending the firmware blob, but then I wrote a culled-down use of libusb which only queries the device status, and I get the same symptoms: status is read fine on the first try after powering the device, and then only read timeouts (but the command-writing part is still successful). Here is the code in question: https://upload.instinctive.eu/5DpBeF32WUvs1f2Yc3TC34fbz38/test-usb.c (sorry for the lazy style) It is probably worth pointing that the exact same code, compiled on linux with the same libusb version, and the exact same device, manages to query repeatedly the device status both before and after sending the frimware blob. So I belive there is a bug somewhere in libusb port or in OpenBSD USB stack. My guess would be something that is not correctly cleaned-up after the first use. Since you all probably don't have the device, I don't expect a fix, but I would be very interested in what I can do to further diagnose the issue. I guess it would be nice to spy on what is going on in the USB wire, but I don't have that kind of hardware. So I was hoping you could help me navigate the USB stack to dump useful information. I have some dumps from libusb-debug, but I cannot find anything useful here, both runs are identical until the timeout. Maybe you can spot something more? https://upload.instinctive.eu/a6TAzULS9R6k82g_U9go4XjmDAo/libusb-debug-first.txt https://upload.instinctive.eu/kn7VfrcHo1FLaDuU_Lk4L8FqhNI/libusb-debug-second.txt In case it matters, I'm running CURRENT, with `what /bsd` printing OpenBSD 6.6-current (GENERIC.MP) #643: Tue Feb 11 00:08:34 MST 2020 Any ideas? Thanks in advance for your help, Natasha
