Receiving 480Mb/s from Jetson Orin NX

Lambert Lihe

New member
Greetings everyone:

I think I may have a stupid question, but I have been searching for hours and not found a an answer yet. Hope you can help me a bit.
I am considering to switch to Teensy4.1 board due to its high speed usb performance.
I am doing a project where I have a stream of data need to be read from SPI port (about 8M/s) and then it to a Jetson Orin NX with USB-serial.

According to the website, Teensy4.1 can and only sent full-speed USB, 12 or 480 Mb/s, and will ignore the baud rate rate setting on the embedded code on Teensy board.

However, I am wondering how can I receive data on the Jetson side?(Running on Linux). Usually with UART/Serial, we set a Baud rate for it to read, but in this case, we do not have such rate. What should I do with the setting? Can this baud rate setting also be ignored, and it will automatically go to full speed as well?
Or I would need another set of library and driver? if so, where I can find them?

Thank you so much for your time.
 
T_4.x will connect at the faster of 12 or 480 Mbps as the Host allows.

AFAIK the baud rate request - ignored by Teensy - is for the host to sync when the device is limited by something like a USB/UART chip.

Depending on the Host the Teensy might actually transfer and maintain over 200 Mbps (on linux as Paul tested ~250?) and less than that to Windows based on receiving and buffering the data and having the program consume it.

On the Jetson the program - if it specifies a baud rate - should request the desired speed as the OS may throttle feeding from the buffering ... seems this showed up somewhere.
 
T_4.x will connect at the faster of 12 or 480 Mbps as the Host allows.

AFAIK the baud rate request - ignored by Teensy - is for the host to sync when the device is limited by something like a USB/UART chip.

Depending on the Host the Teensy might actually transfer and maintain over 200 Mbps (on linux as Paul tested ~250?) and less than that to Windows based on receiving and buffering the data and having the program consume it.

On the Jetson the program - if it specifies a baud rate - should request the desired speed as the OS may throttle feeding from the buffering ... seems this showed up somewhere.

So, This would means I can also ignore the Baudrate on the host side while using a serial protocol library?
 
Generally, AFAIK - except as noted in the last line of post #2. The actual speed observed will be observable.

Thank you for answering. but,I am sorry, I am not quite get that line on post #2, does it means it would not work on Jetson? or does it means the speed may be compromised.
As a matter of fact. I do not need crazy speed. 12M/s or higher would be more than enough for me.

Thanks
 
So, This would means I can also ignore the Baudrate on the host side

Correct. The baud rate setting isn't used by the actual USB data communication.

It is communicated from your PC to Teensy, where your code running on Teensy can read it with Serial.baud(). Normally you wouldn't have any reason to do this, but it is useful if your code implements a USB-Serial converter where you configure 1 of the 8 hardware serial ports and forward all the data back and forth. In that case, you can read the number software on the PC set and configure the actual serial port to the intended baud rate (which is how all USB-Serial chips work).

Detailed documentation here:

https://www.pjrc.com/teensy/td_serial.html

Even though most of that page was written before Teensy 4, much of the info about how to achieve higher speeds is still very relevant. You'll get terrible performance if you handle 1 byte at a time, especially on the PC side. The USB protocol implements flow control (similar in concept to RTS/CTS but baked deep into the actual USB protocol) so even though the communication is at 12 or 480 Mbit/sec, the actual speed you will get depends on how efficient your software is on both side. Often we have seen inefficient software (recently slow Python and GUIs) that really limits the overall transfer rate, so even though you might think a 600 MHz microcontroller would be the limiting factor, often it is the software on the PC side that limits the speed.

Forget about the meaningless baud rate setting and focus on written efficient code on both sides!
 
Thank you for answering. but,I am sorry, I am not quite get that line on post #2, does it means it would not work on Jetson? or does it means the speed may be compromised.
As a matter of fact. I do not need crazy speed. 12M/s or higher would be more than enough for me.

Thanks

That last line relates to some post or real world (non teensy) OS specific interface IIRC (but I don't recall the specifics) - as noted when a slower rate was asked for the OS/program stack contrived to limit the produced speed to that rate.
It wasn't Jetson per se - perhaps it was python or something seen in writing C code. But asking for a meager rate produced a meager rate.

The note was "request the desired speed" - that is ask for the full speed if given the option and then that limit won't be a factor - should those same limitations apply.
 
Back
Top