08-06-2019 01:16 PM
I need to build a test fixture for a device that uses a Silicon Labs Dual CP2105 chipset that talks to two different sections of the board to be tested. Since it's USB it will be somewhat random which port enumerates as what when a new DUT gets put in place.
I have a VI that can identify the ports, attached below. I need to take the resulting serial ports found and send an ASCII "??" to them. If in the first line of the response contains "FPGA" that means I have found the right port and I will want to be using that for the rest of my communications.
And idea how to do this? Serial communication is new to me for labview.
Solved! Go to Solution.
08-06-2019 01:25 PM
You would need to cycle through each port.
See below:
The above can be improved, just a sketch of what is possible.
mcduff
08-06-2019 02:20 PM
I had a similar project that I had to enumerate through the serial ports as well as enumerate through each of the BAUD settings.
Doing what mcduff provided is exactly what I did to achieve my goal.
08-06-2019 03:11 PM
Thanks! That pushed me in the right direction. Attached what I ended up with.
08-06-2019 03:24 PM
You can eliminate that first For Loop. It's not needed since your using aliases.
08-06-2019 03:24 PM
Here's a one loop suggestion to try. (I assume you only have one FPGA port attached, otherwise then make an array and get rid of the conditional stop.)
mcduff
08-06-2019 03:46 PM
OK, that works.
Thanks!
08-07-2019 06:52 AM - edited 08-07-2019 06:53 AM
I would also advise using the "expression" input on the Find VISA Resource. With it, you can easily filter out all of the TCP and GPIB resources. For my reuse, I also filter out the COM ports that I know are not what I am looking for (I know are used by other devices, were previously detected and looking for a new port due to USB connection, etc).
03-25-2023 07:37 AM - edited 03-25-2023 07:51 AM
oops, wrong login account of mine, see the next message
03-25-2023 07:57 AM
Does anyone else find that the VISA Find Resource function used
takes a long time (8 seconds for me) to execute ? Even when the list is empty it still takes that long to excute which seems unusually long.
Peter