06-16-2010 02:21 PM
Hi,
I wanna use Fluke 45 to measure the current of a resistor when I give voltage to the resistor. I wrote a simple program to realize it but there is an error, see the attached file. The error happens at the read file part which is circled. Could you give me some hints about this? Also, I do not know how many bytes I should give. On the multimeter display, there are 4 digital numbers so in this way I should give 32 bytes? On the manual, I did not find any part related with this bytes problem. Thanks.
06-16-2010 02:41 PM
You are not doing any file I/O operations so the second of 2 possible errors would apply.
First, I would recomend that you use the VISA functions instead of the lower level GPIB. Then, do a bit better job with the dataflow of those first two writes. It looks like you are trying to do them in parallel. If ADC is the measurement command, you may need to do a wait before trying to get the result. Lastly, why are you reinventing the wheel instead of using the existing driver?
As far as the number of bytes to request, just use some arbitrary large number. The read will automatically terminate when the instrument asserts EOI.
06-30-2010 11:13 AM
Hi,
Thanks for your reply. I am reading the Fluke 45 driver these days especially Fluke 45.lvlib: Read Measurement file but I have some questions as follows,
1. I do not know what the COM or LPT1 means in VISA I/O resource name;
2. I am not clear about the communication between the instruments and PC since I can not find any part for address reading in the file.
3. For trigger problem, I do not know how to trigger the equipment if I use ADC. In fact, what I wanna do is to give voltage and measure the current. I keep my voltage constant at a certain value for 2s or any duration and meanwhile test the current.
I attached this read file that I am reading.
06-30-2010 11:27 AM
COM and LPT1 are the serial and printer ports, respectively.
If you did a scan for instruments in MAX and the Fluke was detected, you would see this in the VISA Resource drop down menu. The actual format for a VISA Resource is described in the VISA help but for GPIB, the general syntax would be GPIBx::instr-address:INSTR. So, if you were using a single GPIB card and the address of the instrument was 10, the resource name would be 'GPIB0::10::INSTR'. Since you should be selecting this from the dropdown, there is seldom any need to type the whole thing. You can also assign an alias in MAX and reference that instead (i.e. 'Fluke').
It sounds like what you want is the immediate trigger mode.