08-17-2005 06:19 AM
09-02-2005 05:46 AM
1. You don't need the sequency structure any more (at least in this basic case).2. Your code is optimized. Typically subVIs are developed so that if an error has occurred previously, the subVI will execute much simpler code.3. You can find the source of errors much more easily.
09-02-2005 07:56 AM
Thanks for the reply. The idea of using the error output to sequence the operation of the program is a good one, but the instrument driver VI's I have dont have error outputs on them. The IVI controls do however.
I think I have two problems here, the instrument when it returns data, doesnt always return the same number of lines in the same order! Eg sometimes I get a date stamp, followed by data, then more data and the alarm settings, then other times I get a mixture of => for OK and the data.
Then the other problem seems to be one of communicating via RS232.
09-05-2005 10:17 AM
the => is the 'message understood' response left over in the buffer by your last command send. ?> means ERROR (Page 4-8 in manual)
I used to read the data in scan mode with the NEXT? command (and 'SCAN 1' 🙂 . After each received values string I send NEXT? again.
Time by time, as you noted, you get a ?>/GRRR/ instread of the values string. My impression is, that this arrives because of a spike on the rs232 line that was misinterpreted by the fluke.
However since I check my received string for exactly this phrase before interpreting it (with spreadsheet string to array) this problem was gone.