LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Using VISA to read data from a FTDI device (FT2232) via its VCP


@RTSLVU wrote:

You should watch this video: VIWeek 2020/Proper way to communicate over serial


Have you watched this video yet?

It is a great resource all around and a great second step for those that tried the built-in examples, played around a bit and hit a brick wall.

0 Kudos
Message 11 of 17
(624 Views)

@TylerM8 wrote:

I simplified my program and make it stop when error occurred. Now we can see first batch of data has been received but "VISA Read" popped an overrun error immediately after that. Any idea about this issue? 


The immediate answer is to remove your wait from the loop.  For a lot more robust setup, go watch this: VIWeek 2020/Proper way to communicate over serial


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 12 of 17
(614 Views)

If LV throws an overrun error then the LV code isn't reading data fast enough.  The device sending out the data is sending the data too fast for the LV code to read it.  Try lowering the baud rate.  Have you tried lowering the baud rate?

0 Kudos
Message 13 of 17
(599 Views)

Thanks, I'd love to but could't open the video from my country. YouTube is blocked..  😞

0 Kudos
Message 14 of 17
(587 Views)

@TylerM8 wrote:

Thanks, I'd love to but could't open the video from my country. YouTube is blocked..  😞


If you follow my link to the LabVIEW Wiki page, there is a link to the github repository where you can see example code and the power point file.


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 15 of 17
(568 Views)

@BigApple0 wrote:

If LV throws an overrun error then the LV code isn't reading data fast enough.  The device sending out the data is sending the data too fast for the LV code to read it.  Try lowering the baud rate.  Have you tried lowering the baud rate?


Or stop using Bytes at port with VISA read

0 Kudos
Message 16 of 17
(561 Views)

@AeroSoul wrote:

@BigApple0 wrote:

If LV throws an overrun error then the LV code isn't reading data fast enough.  The device sending out the data is sending the data too fast for the LV code to read it.  Try lowering the baud rate.  Have you tried lowering the baud rate?


Or stop using Bytes at port with VISA read


Using the Bytes At Port to see if any data is there is fine.  I have beef against it being used to state how many bytes to read.  But since we are dealing with a streaming source and the fact the code can't keep up, I would remove the wait inside of the loop and the Bytes At Port.  Instead, use the messaging framing protocol to find your messages.  To give any more advice, I need to know that framing protocol.  It is usually a little more difficult to figure out when it is raw/binary/hex data instead of ASCII.


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 17 of 17
(555 Views)