Tektronix Technical Forums are maintained by community involvement. Feel free to post questions or respond to questions by other members. Should you require a time-sensitive answer, please contact your local Tektronix support center here.

How to Control the RSA306 From LabVIEW

Post Reply
Dave W
Tektronix Applications
Tektronix Applications
Posts: 304
Joined: April 26th, 2010, 12:01 pm
Country: United States

How to Control the RSA306 From LabVIEW

Post by Dave W » August 18th, 2015, 3:24 pm

For anyone who wants to control the RSA306 using a LabVIEW program, good news! The RSA306 works with the native LabVIEW driver for the RSA6100A and 5100A (tkrsa6100). Using this driver you can control the RSA306 and collect data without needing to learn the command set. However, getting LabVIEW to talk to the RSA306 is not as straight forward. This guide will show you what to do.

Setting up the RSA306 to talk to work with LabVIEW is relatively simple. This guide assumes you are working from a clean computer (No T&M software installed yet).
  1. Install SignalVu-PC. This will install Tek VISA as well.
  2. Install LabVIEW along with NI-VISA. (Don't worry, NI-VISA and Tek VISA can be installed at the same time. Just be sure to install NI-VISA second)
  3. Plug in the RSA306 and let Windows install the driver.
  4. Launch SignalVU-PC.
  5. Go to the notification area of the taskbar and find the item Tek VISA Control LAN Server. Right-click it and select Start VXI-11 Server.
LabVIEW is now ready to communicate with SignalVU-PC and the RSA306. Next we’ll want to get the Native LabVIEW driver and make sure we can talk to the RSA306.
  1. Start LabVIEW.
  2. From the LabVIEW start screen go to Help -> Find Instrument Drivers…
  3. Log in with your NI.com account if you aren’t already. If you don’t have one you will need to create one.
  4. In the Manufacturer drop down select Tektronix
  5. In the additional keywords type RSA6120A
    a. You need to search on a specific model number. The driver will not come up in the search results if you only enter the Series number.
  6. Select the tkras6100 Instrument Driver from the result then click Install >
  7. After it downloads and installs it will ask you if you want to start using the driver now. Click yes and a list of examples will show up.
  8. Open the example tkrsa6100 Acquire and Fetch SA Display Example.vi
  9. On the front panel of the VI, in the VISA Resource Name control select or enter TCPIP0::127.0.0.1::inst0::INSTR. This is the local loopback address and tells VISA to try to connect to the VXI-11 server that is running on your PC. (Remember when you Started the VXI-11 Server from the Tek VISA Control LAN Server notification tray icon? You did that right?)
  10. Adjust any additional parameters then click the run button. The VI runs and displays the spectrum.
With that, you should now be communicating with the RSA306 using LabVIEW.

leviegeri
Posts: 1
Joined: December 23rd, 2015, 8:22 pm

Re: How to Control the RSA306 From LabVIEW

Post by leviegeri » December 26th, 2015, 10:12 pm

Hello,

Can the RSA306 be controlled from LABWINDOWS CVI?

Dave W
Tektronix Applications
Tektronix Applications
Posts: 304
Joined: April 26th, 2010, 12:01 pm
Country: United States

Re: How to Control the RSA306 From LabVIEW

Post by Dave W » December 28th, 2015, 10:30 am

Yes, you can control the RSA306 using LabWindows/CVI.

To do so first start with the same 5 steps for setting up the RSA306 and SignalVu-PC as found in the original post. From there you can connect to SignalVU-PC using the VISA library in LabWindows/CVI and then send commands and read back data to/from SignalVU-PC using VISA writes and reads. You will need to use the instrument commands as there is no IVI driver available for the RSA's. The commands to send can be found in the SignalVU-PC programmer's manual which can be downloaded at the following URL.

SignalVU-PC Programmer's Manual: http://www.tek.com/node/1581287


An alternative option would be to try to use the RSA306 API .dll to control the RSA306 directly, bypassing the need for SignalVU-PC. The RSA306 API .dll is a Windows C/C++ DLL so in theory it should work with LabWindows/CVI since LabWindows/CVI is a C based development environment. I have personally never tried using the RSA306 API DLL in LabWindows/CVI so I cannot guide you through how you would bring it into LabWindows/CVI.

You can download the RSA306 API DLL from the following URLs.

RSA306 Application Programming Interface - API for 32-bit Windows, V3.6.0239: http://www.tek.com/model/rsa306-software-3
RSA306 Application Programming Interface - API for 64-Bit Windows, V3.6.0239: http://www.tek.com/model/rsa306-software-4

rcard53762
Posts: 4
Joined: February 7th, 2017, 5:00 am
Country: United States

Re: How to Control the RSA306 From LabVIEW

Post by rcard53762 » February 7th, 2017, 5:06 am

I can run the tek RSA306 from signal view no problems.
I shut down the Signal Vu software and tried the Labview example.
When I try to use the Labview example given I get the following error.

VISA Open in tkrsa6100 Initialize.vi->tkrsa6100 Acquire and Fetch SA Display Example.vi

I used the following address in the Visa resource manager.
TCPIP0::127.0.0.1::inst0::INSTR

Any ideas why I may be getting this error.

Dave W
Tektronix Applications
Tektronix Applications
Posts: 304
Joined: April 26th, 2010, 12:01 pm
Country: United States

Re: How to Control the RSA306 From LabVIEW

Post by Dave W » February 7th, 2017, 2:34 pm

That sounds like VISA is unable to open the resource. Did you start the VXI-11 server in TekVISA LAN Server Control?

Thomas F

Re: How to Control the RSA306 From LabVIEW

Post by Thomas F » February 8th, 2017, 11:16 am

SignalVU must be running to use the SCPI interface.

kumelk
Posts: 1
Joined: April 12th, 2017, 2:45 pm
Country: United States

Re: How to Control the RSA306 From LabVIEW

Post by kumelk » April 12th, 2017, 2:56 pm

The first time I wanted to control RSA306 from LabVIEW, I followed the steps in the first post and was successful in doing so. At that time, I was using LabVIEW 2016 32-bit. Recently, I have installed LabVIEW 2016 64-bit, as I was running into memory problems in the 32-bit version. Now I am unable to communicate with the RSA and getting error code: -1073807 and source: "VISA Open in tkrsa6100 Initialize.vi->tkrsa6100 Acquire and Fetch SA Display Example.vi". I still have the 32 bit version installed, and the same VI works fine on it like before. I have reinstalled NI VISA and the tkrsa6100 instrument driver, but nothing seems to work. Any suggestions will be highly appreciated.

Thomas F

Re: How to Control the RSA306 From LabVIEW

Post by Thomas F » April 12th, 2017, 3:21 pm

The problem you are describing is likely a bit'ness related issue between Labview and TekVISA. The current shipping version of TekVISA is 32-bit only, but we are working on a 64-bit version. We hope to release it in 3-4 months. For now, you'll likely have to continue to use the 32-bit version of Labview.

Post Reply

Return to “RSA Programming”

Who is online

Users browsing this forum: No registered users and 0 guests