Hello everyone,
I made a basic video showing how to communicate/control a 33521A or 33522A in Labview without needing a labview driver. Basically it just shows you how to send SCPI commands to the instrument. The method shown in this video can be used on any instrument that uses SCPI, which is the vast majority of box instruments. PXI instruments do not use SCPI.
Feel free to ask any questions. If there are other demos you would like to see feel free to make a request and we'll see what we can do.
http://www.youtube.com/watch?v=W4VZHwpSW1M
I made a basic video showing how to communicate/control a 33521A or 33522A in Labview without needing a labview driver. Basically it just shows you how to send SCPI commands to the instrument. The method shown in this video can be used on any instrument that uses SCPI, which is the vast majority of box instruments. PXI instruments do not use SCPI.
Feel free to ask any questions. If there are other demos you would like to see feel free to make a request and we'll see what we can do.
http://www.youtube.com/watch?v=W4VZHwpSW1M
MMEM:DOWN:FNAM <filename>
MMEM:DOWN:DATA <binary_block>
The example that's given in the help file is as follows:
MMEM:DOWN:FNAM "INT:\Myfile"
MMEM:DOWN:DATA #15Hello
When I use MMEM:UPL? "INT:\Myfile" the return response is #15Hello
First off, what is the "binary_block" suppose to be? Apparently it's not text? However if I use the Upload function on a *.arb file I recieve the text within the file.
What I need to do is send a file such as an *.arb or *.seq file over the 488 (GPIB) bus and have it available in the "INT:\" directory of the 33522A.
How can I do this?
--> In looking at NI Communicator, I don't see an option to read from/write to a file. If you use NI's VISA Interactive Control instead, you can select the checkbox at the top-right to "Show All VISA Operations". Then, if you navigate to the Basic I/O tab, you can select the viWriteFromFile or viReadToFile to send receive your .arb files.
Binary block allows you to send a blob of binary data. It requires that you append a header to whatever data you want to send. So, in the example you gave -
#15Hello
# signifies that you are sending a binary block
1 states that there will be 1 ASCII character in the next field
5 states that there will be 5 bytes of data following
Hello is your data
Lets look at a specific example with the 33521A:
In NI VISA Interactive Control, do a viWrite of
Now do a viReadToFile and save the file somewhere you can remember (I used c:\MYSINC.arb)
If you go look at the contents of the file you just saved, you will notice the IEEE Binary Block header at the beginning of the file, then the file contents. If you remove the IEEE Binary Block header, and save it, you will have a .arb file. If however, you add the command to the beginning of the file, you can send this file back to the instrument using viWriteFromFile (again in NI VISA Interactive Control). Don't forget to first send the name of the file you want to send using viWrite:
Of course you can do all of this using VISA commands in whatever IDE/Language you want; there is no special magic in NI VISA Interactive Control for this use case.
Let us know if there is something thats not clear, or if you have more questions.
PS. I've attached the MYSINC.arb file that can be sent directly to the FGEN, just rename it to MYSINC.arb.
Attachments
Attachments