Solution
When working with USB and SD devices on NI Real-Time (RT) controllers, the first step is to
identify the OS of the controller (Phar Lap, VxWorks, and Linux Real-Time). Based on the OS of the controller, the directory path will be defined as follows:
- When using Phar Lap or VxWorks controllers, you must point to the drive that is enumerated when the USB drive or SD Card is connected. By default, the external drive should be named with the drive letter U: for the first drive, V: for the second, and so on.
- When using Linux RT controllers, you must use the partition where the USB or SD was mounted. You can use the lsblk command through the Linux terminal (if a monitor and target are connected to your controller) or via SSH to verify the mounting point (directory path). The image shows the lsblk command executed via SSH:
The same LabVIEW functions are used for writing to a specific drive in LabVIEW Real-Time as in Windows. The following is an example program that would write to the primary external drive depending on the OS of the RT controller: