From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

USB communication

Solved!
Go to solution

Hi,

Is it possible to read and write a text file using a regular usb flash drive in labview? If so, please suggest the ways to accomplish this.

 

Thanks

0 Kudos
Message 1 of 13
(3,143 Views)
Solution
Accepted by topic author Validus_babu

Can you be more specific as to what you mean? A USB flash drive looks, at least on my machines, like pretty much any other R/W drive space, so reading and writing to it isn't any different (other than possible considerations of max R/W cycles a flash drive has in its lifetime, or possibly R/W speed compared to a fast hard drive). What difficulty are you having?

Putnam
Certified LabVIEW Developer

Senior Test Engineer North Shore Technology, Inc.
Currently using LV 2012-LabVIEW 2018, RT8.5


LabVIEW Champion



0 Kudos
Message 2 of 13
(3,141 Views)

Hi,

 

Thanks for the reply.I completely forgot I can use USB flash drive as a regular drive to read and write files in labview.

 

Thanks

suresh

0 Kudos
Message 3 of 13
(3,135 Views)

Please let me know,

How can  I use USB flash drive as a regular drive to read and write files in labview.

please share it. 

0 Kudos
Message 4 of 13
(2,752 Views)

Hi I12,

 

just plug the USB drive into a free USB port of your computer…

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 5 of 13
(2,742 Views)

@l12ec937 wrote:

Please let me know,

How can  I use USB flash drive as a regular drive to read and write files in labview.

please share it. 


It is exactly just like writing to your hard drive.  You just have to make sure your path is going to the correct drive.


GCentral
There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
0 Kudos
Message 6 of 13
(2,739 Views)

Hi erdW,

I 've tried for that in labview, but it does n,t detects .

here the usb port is in working condition, as well I'm biggener ( labview).

So, please suggest peace of code for the same above.

 

Thank you.

 

0 Kudos
Message 7 of 13
(2,714 Views)

Hi I12,

 

I 've tried for that in labview, but it does n,t detects . here the usb port is in working condition

Does Windows detect the USB drive? Does it get a drive name (like E: or similar)?

Can you show a screenshot of the standard WindowsExplorer showing all drives connected to your computer?

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 8 of 13
(2,712 Views)

@l12ec937 wrote:

Hi erdW,

I 've tried for that in labview, but it does n,t detects .


LabVIEW does not need to detect.  It just needs Windows to create a path to the drive (D:, E:, G:, etc.).  Then you just use the standard file IO.


GCentral
There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
0 Kudos
Message 9 of 13
(2,703 Views)

Like serial communication data transmission, how can I read/write a txt file within the usb flash drive, when ever I want.Please guide me to read/write a txt file within the usb flash drive

0 Kudos
Message 10 of 13
(2,688 Views)