Galvanically-Isolated USB (+ longer distances) - USB over Ethernet

Status
This old topic is closed. If you want to reopen this topic, contact a moderator using the "Report Post" button.
For measuring it may be important to have the measuring device galvanically isolated from the analyzing computer. Some devices use internal I2S isolators (e.g. RTX6001, some RPi DACs) but most USB audio devices don't.

USB isolators up to full speed (12Mbps) are inexpensive (ADUM etc.), but full speed does not allow duplex higher samplerates. High-speed (480Mbps) isolators are still quite expensive (150USD+).

A dirt-cheap galvanically-isolated data-transfer technology is ethernet. I tested USB-IP protocol offered by linux and it behaves great. RPi4 hosting a USB soundcard, linked with 100Mbps ethernet to a PC. When RPi exports the USB device over network and the PC attaches it, a USB soundcard appears in the PC OS which can be used by any software. Since the USB-IP protocol transfers raw USB communication, the actual USB device drivers are applicable only on the PC side.

Another advantage is the max ethernet distance is much higher than for USB, it may come handy for some use cases.

Duplex 192kHz/24bit/2ch generated 12Mbps of ethernet traffic in both directions (9.2Mbps raw data + overhead). Load on RPi was 20% of one core for each direction, the more powerful PC was at 2 x 8%.

I tried to measure how USB over network affects latency with jack_delay jack delay [Linux-Sound] but could not get any statistically significant difference compared to direct USB connection (ping between the PC and RPi is 300us avg. on my home network).

Since the USB-IP stack has been in linux for many years, even the cheapest ARM boards with 100Mbps ethernet supporting older kernel will do easily (e.g. Orange Pi Zero for 12USD incl. shipping + any USB charger). Or a dirt-cheap router with USB port, running properly-configured OpenWRT.

There are proprietary USB-IP solutions for windows too but they are not possible to use on the inexpensive ARM boards out of the box.

I can imagine the "smart" USB RPi4-based soundcard having the actual USB soundcard connected via the isolated ethernet + small board, as a low-cost galvanic-isolation option. The output/input frontend would be isolated in any case.
 
A refurbished x86 thin client with class II adapter would be the most economical solution - quality good-brand (basically immortal) HW, gigabit ethernet, very reliable power adapter, reliable storage (CF card) all included in price (SD cards for ARM boards are either cheap and unreliable, or a bit costly), solid metal case, using latest linux kernel, trivial installation, wake-on-lan support for fixed installation, etc.

In my projects I have very good experience with Futro S900 - 9EUR + shipping Fujitsu Futro, AMD G-Series G-T44R, S900 Thin Client, 2GB Flash, 2GB DDR3, Citrix | eBay . It would work like a charm in this application.
 
AX tech editor
Joined 2002
Paid Member
In the past, I have been using USB isolators from Intona in Germany. They are more expensive, but work beautifully. They also have a somewhat higher voltage spec (up to 3kV) which was important for me to measure in my high voltage amplifiers.

Recently I got myself a WiFi connected USB scope for total independence from any cabling.
Maybe that is an idea for your project as well - WiFi or Ethernet, same difference ;-)

Jan
 
AX tech editor
Joined 2002
Paid Member
I see. So that WiFi scope probably uses buffered streaming or something. It sure 'feels' like a regular scope.


Edit: yes, streaming rates and record lengths are lower with the WiFi compared to USB 3, if you have the extended memory model. With the standard memory it doesn't seem to make a difference.

Jan
 

Attachments

  • WS6k.PNG
    WS6k.PNG
    19.8 KB · Views: 221
Last edited:
What model is that scope?

I do not think your scope uses some USB-IP emulation for network access. A scope is not a continuous packet device like USB protocol is. USB 480Mbps sends packet every 125us, in proper operation none of the packets get lots. USB drivers can count on reasonable timing. If the USB-IP network layer between the USB device and the USB driver introduced large varying latencies, I would expect many USB drivers to fail. Especially considering the generally poor drivers quality for consumer devices...
 
AX tech editor
Joined 2002
Paid Member
What model is that scope?

I do not think your scope uses some USB-IP emulation for network access. A scope is not a continuous packet device like USB protocol is. USB 480Mbps sends packet every 125us, in proper operation none of the packets get lots. USB drivers can count on reasonable timing. If the USB-IP network layer between the USB device and the USB driver introduced large varying latencies, I would expect many USB drivers to fail. Especially considering the generally poor drivers quality for consumer devices...

It is the WS6-1000XM WiFiScope WS6 high accuracy oscilloscope

Jan
 
It is the WS6-1000XM

Thanks, interesting device.

Look at the measurement workflow described in LibTiePie: Main Page . The control software asks for starting the measurement, and then waits until the device -> library on the host indicates the measured data are available. This mode really does not require low latency and zero packet loss network - the software waits until the data are downloaded. No problem if it takes more time or if packets have to be retransmitted. That is a good design, suitable for wifi. But very different from how the USB works.
 
Last edited:
Status
This old topic is closed. If you want to reopen this topic, contact a moderator using the "Report Post" button.