Welcome new user! You can search existing questions and answers without registering, but please register to post new questions and receive answers.

Serial and streaming over USB?

0 votes
Pardon the newbie question, but is there any technical reason why sending both serial data (detected object coordinates, once per frame) and streaming video over the same USB connection would be a bad idea?  We did a quick test using a Raspberry Pi and it seemed to work but we want to make sure there is no risk of either data being corrupted in this arrangement.
asked Dec 15, 2017 in User questions by billjester3 (120 points)

1 Answer

0 votes
Both are fully supported at the same time. When video is streaming, it uses so-called USB isochronous transfers, which guarantee real time flow. This can use up to 80% of the total USB 2.0 bandwidth of 480 Mbit/s. The real time guarantee is achieved by reserving some time slots on a 8 MHz clock signal. The rest of the bandwidth, outside any reserved isochronous slots, is available for so-called USB bulk transfers, which are used by serial over USB.

When not streaming video out of jevois, no isochronous bandwidth reservation is made, so you get the full 480 Mbit/s for serial.

In some work in progress, my students are sending hundreds of keypoint descriptors (128 bytes each, then converted to ascii) for each frame while also streaming video, with no problem.

Of course if you have lots of other devices sending lots of bulk packets on the same USB bus as jevois, congestion might occur. In such case, try to move these other devices to a different USB bus.
answered Dec 15, 2017 by JeVois (39,960 points)