LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Error -420 Query UNTERMINATED (from USBTMC)

I got the same error when the Keithley is set to the TSP command set. Switching to SCPI solved the problem (Front Panel: Push Menu - Settings). Keithley's Test Script Builder uses TSP, the LV driver requires SCPI.

0 Kudos
Message 11 of 20
(2,811 Views)

Hi all

I am trying to talk to the Keithley Sourcemeter 2410 through NI VISA I/O . I am using a GPIB-USB connection. I have already configured the SMU 2410 to the SCPI settings through the front panel. I see the instrument in the NI MAX software.

When I use the following commands through the I/O of VISA, I get the following results:

_____________________________________________________________________

Command: *IDN?

   Write: Write Operation (*IDN?)
              No Error

   Read: Read Operation
              Return Count: 82 bytes
              KEITHLEY\sINSTRUMENTS\sINC.,MODEL\s2410,4116375,
              C33\s\s\sMar\s31\s2015\s09:32:39/A02\s\s/J/M\n

____________________________________________________________________

After this I try to use the sourcemeter for measuring current using the following command sequence. I WRITE these commands into the I/O of VISA, one by one:

*RST

:SOUR:FUNC VOLT

:SOUR:VOLT:MODE FIX

:SOUR:VOLT:RANG 0.2

:SOUR:VOLT:LEV 0

:SENS:FUNC "CURR"

:SENS:CURR:PROT 100e-3

:SENS:CURR:RANG 10e-3

:OUTP ON

:READ?

 

_____________________________________________________________________

I see no change on the display of the sourcemeter. Nothing changes.

 

Can you please tell me where I am going wrong?

Also, if you need more information regarding this, let me know.

 

Thanks

Avinay 

0 Kudos
Message 12 of 20
(2,797 Views)

@avinaysyr wrote:

Hi all

I am trying to talk to the Keithley Sourcemeter 2410 through NI VISA I/O . I am using a GPIB-USB connection. I have already configured the SMU 2410 to the SCPI settings through the front panel. I see the instrument in the NI MAX software.

When I use the following commands through the I/O of VISA, I get the following results:

_____________________________________________________________________

Command: *IDN?

   Write: Write Operation (*IDN?)
              No Error

   Read: Read Operation
              Return Count: 82 bytes
              KEITHLEY\sINSTRUMENTS\sINC.,MODEL\s2410,4116375,
              C33\s\s\sMar\s31\s2015\s09:32:39/A02\s\s/J/M\n

____________________________________________________________________

After this I try to use the sourcemeter for measuring current using the following command sequence. I WRITE these commands into the I/O of VISA, one by one:

*RST

:SOUR:FUNC VOLT

:SOUR:VOLT:MODE FIX

:SOUR:VOLT:RANG 0.2

:SOUR:VOLT:LEV 0

:SENS:FUNC "CURR"

:SENS:CURR:PROT 100e-3

:SENS:CURR:RANG 10e-3

:OUTP ON

:READ?

 

_____________________________________________________________________

I see no change on the display of the sourcemeter. Nothing changes.

 

Can you please tell me where I am going wrong?

Also, if you need more information regarding this, let me know.

 

Thanks

Avinay 


Does anything show up in the read buffer?  That's the main thing.

Bill
CLD
(Mid-Level minion.)
My support system ensures that I don't look totally incompetent.
Proud to say that I've progressed beyond knowing just enough to be dangerous. I now know enough to know that I have no clue about anything at all.
Humble author of the CLAD Nugget.
Message 13 of 20
(2,792 Views)

:READ? is a query.  (Anything with a question mark is a query.)  You have to either do a write followed by a read, or use the query button (which is really just a write followed by a read, made conveniently into one button).

Bill
CLD
(Mid-Level minion.)
My support system ensures that I don't look totally incompetent.
Proud to say that I've progressed beyond knowing just enough to be dangerous. I now know enough to know that I have no clue about anything at all.
Humble author of the CLAD Nugget.
Message 14 of 20
(2,788 Views)

Thank you for your reply.

After each time I WRITE the command, I get the following error on READing it:

 

Read Operation
Error

VISA: (Hex 0xBFFF0015) Timeout expired before operation completed.

 

It doesn't make sense to me. Can you help me out with this?

0 Kudos
Message 15 of 20
(2,786 Views)

Can you :SENSE:CURR? instead?

Bill
CLD
(Mid-Level minion.)
My support system ensures that I don't look totally incompetent.
Proud to say that I've progressed beyond knowing just enough to be dangerous. I now know enough to know that I have no clue about anything at all.
Humble author of the CLAD Nugget.
0 Kudos
Message 16 of 20
(2,783 Views)

I tried that but I'm still getting the same error.

Read Operation
Error

VISA: (Hex 0xBFFF0015) Timeout expired before operation completed.

0 Kudos
Message 17 of 20
(2,781 Views)

Wow.  I am at a loss.  The *IDN? query was successful, so we know communications is fine, yet a simple read won't work.  All those SCPI commands look right, except the :SENS:FUNC "CURR" has quote marks around it.  I don't know if this even relevant, though.

Bill
CLD
(Mid-Level minion.)
My support system ensures that I don't look totally incompetent.
Proud to say that I've progressed beyond knowing just enough to be dangerous. I now know enough to know that I have no clue about anything at all.
Humble author of the CLAD Nugget.
0 Kudos
Message 18 of 20
(2,775 Views)

What is interesting is that even after that first reset command I enter, I still get the same error.

_______________________________________________________________

Command : *RST 

 

WRITE:Write Operation (*RST)

             Return Count: 4 bytes

READ: Read Operation
            Error

            VISA: (Hex 0xBFFF0015) Timeout expired before operation completed.

_______________________________________________________________

Also, same thing happens when I READ after WRITE(ing) the next command 

:SOUR:FUNC VOLT

 

What could possibly be wrong? Anything to do with communications?

 

Also, sometimes I get the 420 QUERY UNTERMINATED error as well when I use some example VIs on LV

 

0 Kudos
Message 19 of 20
(2,773 Views)

Remember that you only read when you are doing a query (with the question mark).  If you read at any other time, you should get a timeout because there is nothing to be read.

 

I can only suggest that you read this to see if you can get it up and running.

Bill
CLD
(Mid-Level minion.)
My support system ensures that I don't look totally incompetent.
Proud to say that I've progressed beyond knowing just enough to be dangerous. I now know enough to know that I have no clue about anything at all.
Humble author of the CLAD Nugget.
0 Kudos
Message 20 of 20
(2,767 Views)