03-09-2007 02:45 PM
03-09-2007 02:53 PM
I should mention, the commands are exactly the same in "Concatenate Strings"(through the string indicator) and the ""String to Write"( I just coped the commands into it).
But only the latter one worked.
03-09-2007 03:24 PM
03-09-2007 03:46 PM
Hi, Lynn,
Thanks! I will try your suggestion.
"What kind of error message do you get?"
In fact, there is no error message in Labview. The problem is that the instrument indicates the command has error. The instrument does not understand the command.
03-09-2007 03:51 PM
Hi, Lynn,
"Move the Close VISA Session to outside the loop."
I can not move the VISA Close outside the for loop or the case structure. It is not allowed, the wires (VISA resource name and the error wires) are broken.
Do you have any more suggestions?
Thanks!
03-09-2007 04:00 PM
Yes you can, the wire are most likly broken for one ot both of these reasons.
1. Make sure you disable the auto indexing on the for loop, right click on the tunnel of the for loop and disable indexing.
2. When you have wires leaving a case structure you are required to connect the wires in each case. So in the false case just connect the tunnels on the right side of the case structure to the tunnels on the left, or right click on the tunnels on the left of the case structure and select Use Default if unwired.
03-09-2007 04:04 PM
03-09-2007 04:18 PM
03-09-2007 04:48 PM - edited 03-09-2007 04:48 PM
Hello, everyone:
It seems that this does not solve the problem.
I even simplify the circuit like below shown, where I tried to input the command string "*CLS\n" into the instrument. But the instrument response an error.
However, if I use "Basic Serial Write and Read.vi", and copy "*CLS\n" into the box of "string to write", the instrument will response without error.
I can not see any difference between these two.
Could you please help me.
Thanks very much for help!
Stone
Message Edited by Little Stone on 03-09-2007 04:48 PM
Message Edited by Little Stone on 03-09-2007 04:50 PM
03-09-2007 04:58 PM