04-12-2006 04:28 AM
04-12-2006 08:00 AM - edited 04-12-2006 08:00 AM
@Frida wrote:
Hi,I am working with an old program that I have to cinfigure in some applications. The pont is that the program should read data from an instrument, a HP 34970A. I thought that I can use the "old" VI, that reads from the serial port of the computer, but I cant seem to get it work. I attach the Vi, and if someone have any idea of what is wrong, please tell me!( I don't understand what the "DATA: POIN?" and the "DATA:REM?" means! Any ideas?)Thanks!
Those statements are queries to the HP 34970A.
Have you downloaded the manual for this instrument? If not, it would be a good idea to do so.
Message Edited by nyc on 04-12-2006 09:01 AM
04-12-2006 08:14 AM - edited 04-12-2006 08:14 AM
Hi Frida,
Here is what the User Manual says about the two commands:
DATA: POINTS? command to determine the total number of readings stored in memeory (all channels) from the most recent scan.
DATA: REM? or DATA: REMOVE? number
The command reads and clears the specified number of readings from memory. This allows you to continue a scan without losing data stored in memory. The specified number of readings are cleared from memory, starting with the oldest reading.
If you do not have the user manual, you can download a pdf copy at this link:
http://www.home.agilent.com/upload/cmc_upload/All/34970-90003_users.pdf
Unfortunately, I could not open you vi because I only have LV7.1, and you are using LV8. However, the old vi's should still work. Did you try to get the example working? The one that came with the drivers?
Since you are using the serial port, is the port configured to communicate with the instrument? port number, baud rate, etc..
JLV
Message Edited by JoeLabView on 04-12-2006 09:18 AM
04-13-2006 01:09 AM
Hi,
I have downloaded the manual for the instrument and also installed the drivers. As you said, there were some examples included. But I can't even get the examples to work. Some if them work fine in Labview, no error messages, but I get error messages on the instrument display (among those, "Syntax error"). And in some of them I get an error message in Labview (-1073807339) at the VISA Read or VISA Write. I have tried all the ports in the drop down list, but none of them seems to work better than others. I have set the baudrate to 9600 which has worked fine before with this instrument (as i said, I update an old program and I know the rate was 9600 in the old program).
Does anyone have any ideas, is there something wrong with the instrument, or is it my limited knowledge in labview that limits my performance here?
I am glad to get all the help i can get!
04-13-2006 02:27 AM
04-13-2006 07:20 AM
Well said antea06,
Yes, you should be able to communicate to your instruments using MAX, even through your serial port. It should list all available ports.
You can start by sending the quiery command " *IDN? "to your instrument. It should respond with it's ID.
Here is an explanation of your error code:
"Warning -1073807339 occurred at an unidentified location
Possible reason(s):
VISA: (Hex 0xBFFF0015) Timeout expired before operation completed."
04-13-2006 07:33 AM - edited 04-13-2006 07:33 AM
Hi Frida,
Below are tid-bits borrowed from HP on equipment communication:
Below is open instrument for serial VISA:
Set serial VISA Attributes:
Here is what the quiery command typically looks like in Labview.
Message Edited by JoeLabView on 04-13-2006 08:40 AM
04-13-2006 07:42 AM
Oops..
I forgot to mention... The example(s) posted below (my last post) were for another intrument.. But it captures the basic idea...
😉
04-18-2006 03:06 AM
Hello!
Our discussion forum is awesome. You post a question and pretty much right away you have several things you can try out in order to solve the problem. Please try to increase the timeout value as suggested and also see if you can achieve basic communication with VISA in MAX.
Regards,
Jimmie Adolph
Applications Engineer, National Instruments