I have a application, it had been running on a machine well for months. I use VISA to do communication between PC and PIC.
Suddenly at some points, it reports error from Property Node (arg 1) in VISA Configure Serial Port (Instr).vi. Since then, it fails to work.
Hyperterminal works. I check MAX, the COM port there and looks fine. What's the problem?
By the way, I am using VISA 4.2. Maybe somehow it crashed?
Thanks a lot for any help.
Solved! Go to Solution.
I think argument 1 in VISA configure serial port is the timeout value. Was this value changed?
What error specifically did you get? I have heard of this kind of behavior happening when the port is no longer available. Perhaps another program (like Active Sync or another one which tries to use the USB ports) has blocked LabVIEW from accessing this COM port. Try using a different USB slot and ensuring other programs are not using this COM port.
If you open up VISA Configure Serial Port.VI you will see a property node used to set the values.
"Time out" is the first argument (top) and is the first arg that it tries to write to and there for the first and only error.
Check that your "VISA resource name" is valid or is gettnig changed somewhere else.
For if the VISA is not valid the error you will get will be when it tries to write to the 1st arg.
Thank you, Ben and Omar for your reply.
Here the screen copy of the error message and the test vi.
COM port is there. We see it from MAX and Hyperterminal works.
As I mentioned, the same application worked on the same machine for months. Very Strange. Is it possible that LabView runtime or VISA runtime crash somehow?
Thanks for any advice.
How are you running this VI?
You should only need to setup your serial port once at the beginning of the program. There is no need to continually reconfigure your serial port.
I am still leaning to an invalid VISA Ref. It could be invalid because (as metioned earlier) another app has control of the com port (MAX or Hyperterminal)
Run the VISA Configure Serial Port.vi as a stand alone selecting the VISA resource name from the drop down to see if you still get an error.
Next in your "setup Serial.vi", put a Not A Number/Path/Refnum? check on the output of the VISA Configure to see if it is valid.
The first time you run your VI the input will be invalid, but if it point to a valid com port that LabVIEW is able open, the out put VISA should then be come valid. Depending on your VISA clean up setting the next time you run it the input VISA might be valid before call the VISA Configure.
The reason is that hard drive was running out of space and there was error. Somehow that caused VISA runtime crash.
We cleaned up C: drive to free some space and then repaired VISA runtime. Now it's running happily.
Thanks a lot, everyone, for your help.