LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Labview with FTDI D2XX drivers?

Actully I am tring VCP now. Istarted with the Basic Serial Write and Read example. I can communicate with the device but I cant't read the string I send. Again I am not sure do I need to physically short RXF and TXE ?

0 Kudos
Message 51 of 84
(3,753 Views)

The D2XX driver is nice for the ability to address the FTDI device by its unique serial number which will never change.  Using VCP (Virtual COM Port), if the COM Port number changes, then you would have to update your VI with the new COM Port number.  This can happen when you plug it into different USB ports. 

 

The VISA or NI-Serial pallettes can be used with the FTDI devices instead of the D2XX drivers by specifying the COM port number as the VISA resource.  These methods would use the VCP drivers to talk to the FTDI device.

0 Kudos
Message 52 of 84
(3,821 Views)

I have seen the examples for D2XX, but couldn't find anything for VCP.  Could you post the example code that you are working with?

0 Kudos
Message 53 of 84
(3,820 Views)

I havn't worked with the FT245R chip so i do not know how much assistance i can provide.  Taking a quick look at the data sheet, I didn't see anything about tieing those two pins together.  I did see that TEST should be tied to ground.  It may be worth the effort to send an email to ftdi's technical support.

 

http://www.ftdichip.com/FTContact.htm#USA

 

 

Sincerely,

Gary

 

0 Kudos
Message 54 of 84
(3,814 Views)

Thanks glstill

I have just sent an email and I hope they help me on hardware setup 

I am using one of the NI examples for visa commucation called " Basic Serial Write and Read example "  and I still can not read what I send

0 Kudos
Message 55 of 84
(3,803 Views)

I've used both the DLL and the VCP. The DLL (the project was 5 or 6 years ago) only suffered if you didn't close the channel at the end of the program i.e. pressing the stop button. The only way to get communications back was to de-enumerate the device by unplugging the USB cable. I've since gone to the VCP and I read the registry if I need the comm port (usually for the science types that I work with I tell them that they have to understand the com port number by reading the device manager, it gets them involved.) I have never seen a glitch with FTDI serial cables on Windows 7 and with VISA.

0 Kudos
Message 56 of 84
(3,793 Views)
That's exactly right about aborting an application where the close function doesn't get called. After unplugging and plugging back in I have also seen where the open function errors out a few times and then starts working. This doesn't happen every time but does occasionally.
0 Kudos
Message 57 of 84
(3,787 Views)

Hi , I am using the FIFO with  VCP and directly using VISA

 

I have few questions and I greatly appreciate your help.

 

1-Has can I utilize digital input -outputs  D0 to D7 using VISA.

 

2- Where can I find VISA commands desciptions such as "*IDN?\n" 

 

3-Finally I think the USB FIFO chip can perform error handling such as CRC Check. Could you please let me know how can I do it using VISA and what is the cammand. I am using ft245r fifo

0 Kudos
Message 58 of 84
(3,729 Views)

1) I think i found a solution to communicate with the digital i/o but it may require using the D2XX library instead of VISA.  Perhaps the same commands could be implemented for VISA, but they are already available in the D2XX library.  I found something called Bit Bang mode which is a special FT232R and FT245R device mode that changes the 8 IO lines into an 8 bit bi-directional data bus.

http://www.ftdichip.com/Support/Documents/AppNotes/AN_232R-01_Bit_Bang_Mode_Available_For_FT232R_and...

 

The FT Prog utility may be able to let you put it in this mode manually.  http://www.ftdichip.com/Support/Documents/AppNotes/AN_124_User_Guide_For_FT_PROG.pdf

 

 

2)  All i found was this info on *IDN?\n" and nothing on VISA command descriptions

 

"Once you have determined the GPIB address of your instruments, it is easy to establish communications to verify that you can send and receive data to and from the instrument. Because most instruments are 488.2 compliant, you can query the instrument for its identification by sending it “*IDN?.” Instruments will typically respond with the manufacturer’s name, model name, and various alphanumeric characters that the manufacturer uses to track firmware revisions." -

 

http://www.ni.com/white-paper/2967/en

 

3) Not sure.....

 

 

 

0 Kudos
Message 59 of 84
(3,718 Views)

This thread has been a treasure trove of good info.  I have also been wrestling with communication with an FTDI chipset.  I'm using a VCP and my program communicates just fine with VISA drivers, but when communication is unexpectedly interrupted (loss of power to unit under test or someone accidentally unplugs the USB communication cable) and I try to restart any communication, neither Windows 7 nor Labview (2010) will see the VCP anymore.  Sometimes it takes multiple reboots of both the PC and the FTDI device under test before I can finally see the VCP again.  And by saying I don't see the VCP anymore I'm also referring to looking for it in Windows Device Manager as well as LV.  This doesn't happen every time, but often enough to be a nuisance.  Anyone else have that problem with enumeration?

********************************************
Amateur programmer for over 10 years!
********************************************
0 Kudos
Message 60 of 84
(3,709 Views)