[Discuss] Generic USB devices

markw at mohawksoft.com markw at mohawksoft.com
Fri Jun 9 14:29:05 EDT 2023


I just bought a digital multi-meter, an OWON 1041 (1241 actually). I had
the hardest time getting it to work.

My workbench is next to my 3D printer. I am using a raspberry PI with a
display and keyboard to run my 3D printer with octoprint. I thought it
would be cool to multi-task this computer to also be my "lab" system.

It was no problem getting my USB logic analyzer to work. That was cool. I
tried getting my new meter to work with pyvisa so I could use it for
logging. For the life of me, I couldn't get it to work.

I moved it to my desktop, installed the software, but nothing. I
eventually worked through it and found that the serial baud rate was
wrong. Evidently earlier versions of this meter had RS-232 and that had
9600 baud vs the USB which has 115200. That was frustrating, but
manageable.

Moving back the the raspberry pi, still didn't work. I knew it could work,
but why wasn't it?

Now comes the interesting part:

pi at pi-top:~/scpi $ lsusb
Bus 001 Device 005: ID 258a:000c HAILUCK CO.,LTD USB KEYBOARD
Bus 001 Device 008: ID 17ef:3899 Lenovo 128GB
Bus 001 Device 009: ID 1a86:7523 QinHeng Electronics CH340 serial converter
Bus 001 Device 011: ID 0925:3881 Lakeview Research Saleae Logic
Bus 001 Device 006: ID 1a86:7523 QinHeng Electronics CH340 serial converter
Bus 001 Device 004: ID 0409:0059 NEC Corp. HighSpeed Hub
Bus 001 Device 003: ID 0424:ec00 Microchip Technology, Inc. (formerly
SMSC) SMSC9512/9514 Fast Ethernet Adapter
Bus 001 Device 002: ID 0424:9514 Microchip Technology, Inc. (formerly
SMSC) SMC9514 Hub
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

Do you see the two "QinHeng Electronics CH340 serial converter" entries?
One is my 3D printer the other is the OWON meter.

There is literally no sane way to statically determine which one is which.

I suppose I could write a program that connects to each and does a query
based on some API, but that seems like a work-around for a poor design.






More information about the Discuss mailing list