Instrument Control (GPIB, Serial, VISA, IVI)

cancel
Showing results for 
Search instead for 
Did you mean: 

multiple gpib commands

hello,
i just subscribed to this forum and this is my first post.  dont know for sure how this thing works.

my problem is that i want to send a command to measure the readings of 2 instruments at the same time. and then i want to get back the corresponding values of that specific time.

im programming using C and here is a piece of my code that is relevant. :

int status, len;
char i[80];     
char v[80];

initialize (21,0);


    send(11, "read?", &status);                     //11 and 12 are the gpib address of my voltmeter and ammeter
    send(22, "read", &status);                       
    enter(v, 20, &len, 11, &status);                 
    enter(i, 20, &len, 22, &status);

will this command return me the values of both the voltmeter and ammeter of the same point of time.

if someone can help me and if my question is unclear.....please reply. i will get back in detials.


Thanks,
Adnan
0 Kudos
Message 1 of 5
(3,612 Views)
Depending on how accurate your timing should be they happen almost at the same time.
If you want them exactly to be timed you could arm those devices and send a GET (group execute trigger) to both addresses.
Then depending of the measuring speed of both devices you have won a few ms of  timing.
greetings from the Netherlands
0 Kudos
Message 2 of 5
(3,588 Views)
ok...the thing is im doing an experiment with a solar cell. i wrote a code that is going to illuminate a certain point on the cell and then at that time i need to send a command to both the voltmeter and ammeter to give me its reading. i tried using Transmit and the GET command but the meters show an error.  maybe i have done something wrong.

can u please write down the line of code that i can use for sending and receiving the values to both the voltmeter and ammeter.
0 Kudos
Message 3 of 5
(3,582 Views)

I use LabVIEW, so I only wire up routines, no lines of code hooray, and much faster

sorry

 

greetings from the Netherlands
0 Kudos
Message 4 of 5
(3,571 Views)
I use LabVIEW too but if you want help, you need to mention the make and models of instruments and the actual commands you are sending. The generic 'read?' will almost certainly not work.
0 Kudos
Message 5 of 5
(3,568 Views)