Measurement Studio for .NET Languages

cancel
Showing results for 
Search instead for 
Did you mean: 

How can I configure EOS character in VB.net + measurement studio ?

Hi all,

I would like to control Oxford temperature controller ITC503 via GPIB with VB.net and measurement studio.

The equipment requires that sent commands are terminated by a Carriage Return (CR) and responses
from the equipment are also terminated by CR.

I could set or change parameters of the equipment correctly by the code gpib.Write("command" & vbCr).
However, if I try to get responses by sending the code gpib.ReadString(), it always falls into timeout.
I guess this is because the EOS is not correctly configured.
I have already succeeded in accepting responses in MAX by setting EOS bite to 13.

I would be grateful if someone knows how to set EOS character in VB.net + measurement studio.

Thank you.
0 Kudos
Message 1 of 3
(3,968 Views)

Hi muramasa,

 

You can set the EOS to CR by using the viSetAttribute function and setting VI_ATTR_TERMCHAR to 0xD.

Please let me know if this helps.

0 Kudos
Message 2 of 3
(3,922 Views)

Hi, Kitajima-san,

 

Thank you very much.

I could settle the problem by adding following codes.

 

gpib.EndOfStringCharacter = 13
gpib.EndOfStringComparison = 0
gpib.SetEndOnWrite = False
gpib.TerminateReadOnEndOfString = True
gpib.SetEndOnEndOfString = False

 

Best regards,

muramasa

0 Kudos
Message 3 of 3
(3,908 Views)