Jump to content

trouble with 34970A


67nate

Recommended Posts

I can't seem to comunicate with the Agilent

I was able to when I was using GPIB but now I need to with RS-232 and I can't get it to work.

I'm getting error -1073807246 which is

Property Node (arg 1) in VISA Configure Serial Port (Instr).vi->6temp.vi

So I know somethings wrong with my configuring of the serial port but I don't know what.

I have checked all the settings like baud rate and parity and the are all correct.

Does any have any ideas?

Link to comment

QUOTE(67nate @ Jul 19 2007, 10:00 AM)

I can't seem to comunicate with the Agilent

I was able to when I was using GPIB but now I need to with RS-232 and I can't get it to work.

I'm getting error -1073807246 which is

Property Node (arg 1) in VISA Configure Serial Port (Instr).vi->6temp.vi

So I know somethings wrong with my configuring of the serial port but I don't know what.

I have checked all the settings like baud rate and parity and the are all correct.

Does any have any ideas?

1 'Configure Serial Port' should be outside the loop so the port is configured at start, and never again.

2 Visa Resource Name should be COM1 or COM2 i.e. the serial port in use; in your case you have it set to 34970A?

3 Have you configured the instrument to use 19200/No Parity/Stop bits..etc same as the settings of your COM port?

4 Try running the code without a While loop to see if it even works on a single run.

5 There may be a way to communicate simply with your instrument using NI-MAX to see if you have all the settings right. If it works in MAX it should work with your code (i.e. you have set up the instrument correctly).

Neville.

Link to comment

sorry, I attached the wrong code (it is now updated)

I used Measurement and Automation explorer to communicate and that is working

But labview doesn't But it should be com 1? I wasn't sure if it was that or the 34970A (the one that worked for the GPIB) I tried both and neither work.

It seems like I'm missing something in initilizeing the serial port but I havn't a clue what.

Link to comment

QUOTE(67nate @ Jul 19 2007, 11:45 AM)

sorry, I attached the wrong code (it is now updated)

I used Measurement and Automation explorer to communicate and that is working

But labview doesn't But it should be com 1? I wasn't sure if it was that or the 34970A (the one that worked for the GPIB) I tried both and neither work.

It seems like I'm missing something in initilizeing the serial port but I havn't a clue what.

Run the code with the Lightbulb ON. Is the error coming frm the Init Serial? If so, play around with the parameters until it works.

Data bits 8, Parity None, Stop bits 1, Flow Control Off seem OK values.

Try termination character Enable or Disable and of course set the Baud rate to match, or even Stop Bits None (check your Agilent manual to see what they recommend).

Have you tested with MAX using the Serial connection or GPIB? If serial, try to figure out what the settings for the COM port in MAX are. I seem to remember there was a way to generate code when sending some commands from MAX. Generate code if you can from there, and run that.

Try a very simple program No loop etc to complicate anything (run in execution highlight mode->light bulb ON, so there are delays after every step):

Init Serial Port

Write command *IDN?

Read response (it should be the identifying string for the instrument "Agilent...blah blah serial number..etc.")

Sorry I have no hardware to help any further.

You might look at the example code for the instrument included with the driver. Try running something simple from there.

Neville.

Link to comment

Have you tried to use the instrument driver found on the NI developer network? Its initialization works fine for my 34970A.

Download it here.

I think this will clear up your problem, since you said the instrument is working in MAX it is probably just the way you're initializing things.

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.