I have a serial device that I'm acquiring data from. My LabVIEW vi will not read any data from the port unless I read the port first with hyperterminal. I not sure why.
This sounds like a port initialization problem. Are you using the "Configure Port" VIs (either VISA or serial depending on how you are reading the port)? Check that the Configure VI has all the inputs with the correct values.
Can you describe the steps that you have to take? Since two applications can not have the same port open at the same time, I'm curious as to the sequence you're using.
Here are the steps I am doing. 1) Run my vi. The vi initializes, reads, then closes the serial port. 2) Since LV isn't recieving data I open and connect to the port with hyperterminal. After seeing the data from hyperterminal I disconnect. 3) Then I restart my vi, and I can see the data from LV
Are you using hardware flow control? If this is the case then you should use VISA for serial communication, as the traditional serial vi's might have some problems setting hardware flow control.
If you don't already have one, connect an indicator to the error code out of the initialize VI (and other serial port VIs) and see if the VI is having trouble initializing the port. Step through the program and try to find out where the problem is coming from. Compare these results to the "after hyperterminal" results to see if there are any differences.
If you aren't already using it, use the Bytes at Serial Port VI to make sure that there is something to read before reading.
Some instruments require proof of connection (send a single CR to it) before they will send data. Give this a try.
To those saying to use VISA: Using VISA is not always a possibility. We have 3 different GPIB c ards in computers and some of them will not work if NI VISA is loaded. So we use the serial port VIs constantly.
I hope these suggestions will help in finding where the problem is occurring.