Instrument Control (GPIB, Serial, VISA, IVI)

cancel
Showing results for 
Search instead for 
Did you mean: 

Can#T Evaluate LabView, get only errors

... as I wrote, the instruments working, the interface is RS232, baud rate and parity were ok. Instruments dont have settings for \n or \r, sorry.

I can send commands to the instruments, which works, but can't read messages.

 

I have RS232 and GPIB, my instruments doesnt have USB, so RS232 is the better option cause GBIP needs bulky cabels, plugs and expensive interface cards.

 

With best regards

 

Gerhard

0 Kudos
Message 11 of 19
(3,100 Views)

.. I made screenshots of a session ...

 

With best regards

 

Gerhard

0 Kudos
Message 12 of 19
(3,098 Views)
Sorry, I'm getting an error trying to open the zip file.

I think you just have an issue with the correct termination character. The way a read works by default, is to terminate when the byte count is reached, the term character is detected, or the timeout is reached. If the specified term character is not detected, you will get a timeout.

I'm sure that somewhere in the manual it mentions whether you should be using a carriage return or line feed. Maybe even both.
0 Kudos
Message 13 of 19
(3,089 Views)

.. ok, I tried the file, no problem? It is a windows zip file.

 

There were actually two problems.

 

1 Some instruments 34401A for instance didnt send an answer, or there is some trouble with the termination character, will go in this today.

 

2 Cant start LabView sample with a functional instrument. The sample opens, no problem, but as soon as I click the start button I get an error message. As a newbee left with 3 days of evaluation time, thats not fine. Maybe someone can help me out of this problem. The other problem can be solved later I think. The 34401A is a classic instrument and I hope there is a solution for that instrument.

 

 

I attached the last shot, showing the error after running the 33120A sample. The 33120A do basic communication without error, so I hoped the sample potentially works, but ...

 

With best regards

 

Gerhard

0 Kudos
Message 14 of 19
(3,081 Views)
You've got 45 days for evaluation. You just have to request it.

As I mentioned, you have to specify the VISA Resource name. As I mentioned, just click on the pull-down. This is the arrow on the right side of the control. You'll get s list of available resources. Select the com port.
0 Kudos
Message 15 of 19
(3,067 Views)

Hi Dennis,

 

thanks, evaluation extended.

 

Ahh, as a software engineer using Visual Studio I guess, that controls showing the square handles didnt run! Ok, NI controls were running and showing this handles, ok.

 

I select the correct COM port, and the sample readout the instrument, but after some seconds, I get some error again. It seems that the conversation between the instrument and LabVIEW is interrupted, but there is no other program running ....

 

With best regards

 

Gerhard

0 Kudos
Message 16 of 19
(3,061 Views)

Hi,

 

ok, tried different settings, and get different errors ...

 

With the VISA tool I can set the termination character, but in the sample?? I think, that a sample for the 33120A should have the correct settings, but?

 

The instrument shows the 'Rmt' icon on his display, so some sort of communication takes place, but I can't change the frequency. Or to be precise, I set a new frequency with LabView but the display of the instrument remains the same. I didn't check the output, cause I have to leave now for a meeting. But I guess, that the display has to change. And after some seconds I get the errors. The error in the screenshot 5 also shows an error on the instrument and I get a beep, but this error is cleared out immeditately (from LabView?) the error described in screenshot 6 didn't bring the Err icon on the instrument and also no beep. I guess thats an driver issue only.

 

With best regards

 

Gerhard

0 Kudos
Message 17 of 19
(3,056 Views)
The query interrupted error often happens when a command is sent before the instrument can fully respond to a previous command like a read. I don't have a 33120 to test the code with and if I did, I would not be using a serial port. There may be an additional delay required in the code.

Per your last comment, the termination character in MAX must match the instrument's. It does not change what the instrument uses.
0 Kudos
Message 18 of 19
(3,052 Views)

.. my instrument only have GBIP and serial, so what can I do?

 

The sample code should work. If I have to patch it, ok, how?

 

With best regards

 

Gerhard

0 Kudos
Message 19 of 19
(3,049 Views)