Using IVI-COM IviRfSigGen to generate an ARB signal

1 view (last 30 days)
Hello everyone,
I have what I hope is an easy question that I have just been unable to find the answer to: I want to turn on the ARB output remotely.
I have an Agilent Vector Signal Generator that I have connected (through GPIB) that I am controlling Via an Ivi-com object (specifically, an IviRfSigGen Object).
Now, how can one turn on the ARB output using this object? I can load a file into the ARB memory, and then even choose the file, but for the life of me, I cannot figure out how to turn on the arb output.
This is the simple code I have setup so far. i_data & q_data are already generated.
%rfgen is the logical id held within the Configureation Store
sig_gen = instrument.ivi.IviRFSigGen('rfgen');
%init the device
sig_gen.Initialize('rfgen', true, true, '');
%set frequency - this works
sig_gen.RF.Frequency = 1E9;
sig_gen.RF.Level = 0;
%load file into the VSG
sig_gen.DigitalModulation.Arb.WriteWaveform('arbwave', i_data, q_data, false);
%set the waveform as the selected waveform
sig_gen.DigitalModulation.Arb.SelectedWaveform('arbwave');
%I know up until this point it all works, because I can manually hit the "arb on" button and it works. But that defeats the purpose of doing it remotely.

Answers (4)

dm
dm on 26 Oct 2011
Which VSG from Agilent do you use? If you have the instrument control toolbox in Matlab, controlling the instrument thru a GPIB object is quite easy, however, you'd have to write Matlab scripts for doing the specific things you want (e.g. uploading signals, downloading data, etc). If you have the programming manual of the instrument this is quite straight forward (e.g.);
BoardNumber = 0; % Example GPIB card number
DeviceNumber = 15; % Example GPIB address
arb = gpib('ni',BoardNumber,DeviceNumber);
arb.InputBufferSize = 1000; % Or whatever you need
arb.Timeout = 120; % Can be convenient to set a timeout
fopen(arb); % Open communication
fprintf(arb,'*IDN?'); % Return identification information
fprintf(arb,'blablabla') % Pass whatever you want
data = fscanf(arb); % Read data, use str2num if numeric data desired.

Alex
Alex on 28 Oct 2011
I could use GPIB or a VISA object to control each device, however I have multiple VSG's and VSG manufacterers to contend with. Thus, I would be needing to create my own driver utilizing the device's specific SCPI commands to control a test. This is in FACT what the IVI foundation drivers already do, and so it should be easier to use their information rather than re-write what they have done.
Also, utilizing VISA object limits you to keeping specific devices on certain GPIB addresses - which is just not flexable enough for my work.

Rob Graessle
Rob Graessle on 28 Oct 2011
Try this:
sig_gen.RF.OutputEnabled = true;
  1 Comment
Alex
Alex on 28 Oct 2011
Already did. That turns on the RF output, but does not touch the ARB output.
I specifically went into the VSG after running that command into the ARB screen (Mode -> dual Arb). If I hit the on button, then the signal (AWGN) comes through.
So, I think the sig_gen.RF.OutputEnabled = true; only represents the RF toggle button on the lower right of the VSG

Sign in to comment.


Vinod
Vinod on 19 Dec 2011
You need both lines below
sig_gen.RF.OutputEnabled = true;
sig_gen.IQ.Enabled = true;
  1 Comment
Alex
Alex on 13 Jan 2012
This only turns on the IQ & the RF output. The modulation option also need to be turned on.

Sign in to comment.

Categories

Find more on Instrument Connection and Communication in Help Center and File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!