LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Get Volume Info does not error when USB missing on sbRIO-9651

If the drive has been disconnected then the get volume info command will return results for the internal flash instead of the previous usb drive.

So if you monitor the total volume size that's reported from the function you'll know if the drive has been disconnected, this applies for any Linux RT target with USB connectivity.
Craig H. | CLA CTA CLED | Applications Engineer | NI Employee 2012-2023
0 Kudos
Message 11 of 12
(787 Views)

I've found the same problem using the SD card and a USB.... I wanted to know if the unit was connected.

 

First I used the Get Volume info (that works fine in other older cRIOs). Then I tried to read the content, but it was no empty... Also the size was a fake...

 

A way that I've found to know if the unit is connected is try to do a "dummie write". I try to create (and delete) a folder. In this case, the function returns an error if the unit is not connected. I'm using the paths "/media/mmcblk0p1/" for SD and  "/media/sda1/" for USB (as U and V can be mapped swapped).

 

I hope that helps you.

 

 

   Jaume



Certified LabVIEW Architect

Certified LabVIEW Embedded Systems Developer


NI Certified Professional Instructor




Message 12 of 12
(626 Views)