LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

NI Simulator query question

Solved!
Go to solution

Hello. I have an NI Instrument Simulator that I have been testing using the VISA test panel in MAX to test. I am not quite sure what is happening however, when I query a simple *IDN?, it will read 00062\r\n". Then when I query it again, it reads "National\sInstruments\sGPIB\sand\sSerial\sDevice\sSimulator\sRev\sB.1\n". When I query it again, it reads the "00062\r\n" again. It flip-flops between the two with each query. Does this me that I will need to continually query twice, to get the desired data read? I am not sure how to put this in a Vi. I have tried a lot of different things but it always come out the same. Even if I clear the register and tried an individual write then read, it does the same thing. Is this to be expected, and how do I do this within a Vi?

Thanks much for your support.

0 Kudos
Message 1 of 13
(3,841 Views)
Either do two consecutive reads or disable the termination character and do a single read with the VISA Bytes at Serial Port to determine how many bytes to read.

I have no idea why the ancient simulator is sending two lines of data. An actual instrument will not do that. As long as you are just pretending to have an instrument, it probably does not matter that much. You could even skip the *IDN? query.
Message 2 of 13
(3,830 Views)
To expand on Sir Dennis's answer. A real.instrument will document in the manual the information that is returned. Typically, in addition to manufacturer and model number you will get version numbers for the firmware and sometimes the hardware too.

Mike...

Certified Professional Instructor
Certified LabVIEW Architect
LabVIEW Champion

"... after all, He's not a tame lion..."

For help with grief and grieving.
Message 3 of 13
(3,814 Views)
Also note that you could have gotten a real instrument for the price of the simulator. A real instrument could be used to acquire actual signals and would be of use outside the classroom.
Message 4 of 13
(3,803 Views)

It was just that it was coming out of my pocket and the simulator was $35. Also, I needed something compact that could travel back and forth with me. Thank you

0 Kudos
Message 5 of 13
(3,762 Views)
I see your point, but here in Houston they have a VERY cool place called EPO. You could get an old voltmeter or something with a gpib interface for about that -- who cares if it hasn't been calibrated since some time during the Nixon administration.

Mike...

Certified Professional Instructor
Certified LabVIEW Architect
LabVIEW Champion

"... after all, He's not a tame lion..."

For help with grief and grieving.
Message 6 of 13
(3,747 Views)

Could you give an example please? I looked around Ebay and found nothing except actual test instruments that were incredibly pricey. Thank you

0 Kudos
Message 7 of 13
(3,741 Views)
Solution
Accepted by ceilingwalker
You need to refine your Google-fu skills. I was thinking of something like this - http://www.amazon.com/TekPower-TP4000ZC-RS232-Interaced-Ranging-Multimeter/dp/B000OPDFLM/ref=cm_cr_p...
Message 8 of 13
(3,733 Views)

Thank you

0 Kudos
Message 9 of 13
(3,725 Views)

@Dennis_Knutson wrote:
You need to refine your Google-fu skills. I was thinking of something like this - http://www.amazon.com/TekPower-TP4000ZC-RS232-Interaced-Ranging-Multimeter/dp/B000OPDFLM/ref=cm_cr_p...

I purchased it but am having trouble getting NI MAX to read from it.

0 Kudos
Message 10 of 13
(3,632 Views)