Instrument Control (GPIB, Serial, VISA, IVI)

cancel
Showing results for 
Search instead for 
Did you mean: 

USB to Serial Read/Write w/ FTDI Cable

I am trying to communicate with a device through an FTDI cable plugged into a USB port on my computer. It communicates with a serial port on the device. There are only the power, ground, and in/out wires attached to the device. The goal is to send a "\" character and get the serial number of the device back. The device is already programmed to receive this command and return the serial number, I just have no idea how to do this in LabVIEW. I get the feeling this is extremely basic, but I would really appreciate some help.

0 Kudos
Message 1 of 12
(5,098 Views)
Look at the examples that come with LabVIEW. The basic one should work. Right click on the string control and select Normal Display so you don't send the escape code \.
0 Kudos
Message 2 of 12
(5,096 Views)

Are there USB read/write examples? I've been trying to decipher the Basic Serial Write/Read.vi file without success.

0 Kudos
Message 3 of 12
(5,081 Views)

No such thing as a generic USB read/write and if you have the RS-232 version of the FTDI driver installed, all discussion of low level USB communication is just irrelevant.

 

What exactly are you have trouble deciphering? You select the VISA resource by clicing the pull-down, set the com settings (baud, parity, etc.), place your '\' in the 'string to write' control, and run the VI. If you get an error, report the error code. Assuming you have Context Help turned on, the controls, indicators, functions are pretty well explained.

0 Kudos
Message 4 of 12
(5,077 Views)

Ok, so the biggest issue is that I can't find the device. I just installed NI-VISA and will explore it now. I couldn't find any ports or devices before, and I'm beginning to think that I need to find the device through VISA first.

0 Kudos
Message 5 of 12
(5,075 Views)

Now I'm getting this error: Error -1073807202 occurred at Property Node in VISA Configure Serial Port (Instr).vi->basic_serial_write_and_read.vi

0 Kudos
Message 6 of 12
(5,072 Views)

As the explanation for that error says, you have a missing driver and the missing driver is NI-VISA. Download it (click on the Support link above) or use the Drivers DVD that came with LabVIEW.

0 Kudos
Message 7 of 12
(5,070 Views)

I'll try installing from the CD, but I just installed NI-VISA and restarted about 15 minutes ago. I installed NI-VISA 5.0, and I'm running LabView 7.1. Could it be a compatibility issue? Also, I'm running Mac OS X if that makes any difference.

0 Kudos
Message 8 of 12
(5,067 Views)

Did not know you were using such an old version. Yes, there is a compatability issue. Make sure to completely uninstall 5.0.

0 Kudos
Message 9 of 12
(5,064 Views)

Which version should I use then?

 

*Nevermind, I found that I should be using 4.2 or 4.5, I'll try 4.5 and see what happens.

0 Kudos
Message 10 of 12
(5,062 Views)