MATLAB: Does SLDRT not support USB devices

I would like to use Simulink Desktop Real-Time (SLDRT) with one of the following NI data acquisition devices that are connected to my PC via USB port:
  • NI USB (e.g. USB-6009)
  • NI ELVIS III
  • NI MyRIO
  • NI CompactRIO
The desired sample rate would be around 30kHz. Will I be able to use these devices with Simulink Desktop Real-Time?

Best Answer

Simulink Desktop Real-Time does not support USB devices because of the insufficient performance of the USB interface in sample-by-sample mode.
For example, in the USB-6009 data sheet:
there are two sample rates mentioned: 48 kS/s (i.e. 48 kHz) and 150 Hz.
The first sample rate of 48 kHz is for the following use case: when you trigger data acquisition session, the device reads the samples into its internal memory (no USB communication required), and when finished, you read all the samples via USB (when fast response is no more a requirement). This workflow cannot be used in a closed-loop SLDRT model that needs each sample to be processed immediately after it is measured. 
On the other hand, there is the second sample rate of 150 Hz, for software-triggered operations on analog output. While this sample-by-sample mode would be suitable for SLDRT, this maximum achievable rate of 150 Hz is simply too low to be of interest for the SLDRT product.