Contact an Expert

Thread: Remote program Hit the key of front panel. X-Series Analyzer


Permlink Replies: 6 - Pages: 1 - Last Post: May 17, 2010 2:07 AM Last Post By: bega
bega

Posts: 11
Registered: 12/17/09
Remote program Hit the key of front panel. X-Series Analyzer
Posted: Dec 17, 2009 11:33 PM
Click to report abuse...   Click to reply to this thread Reply
Hello.
My program (C#, locate on the remote PC or on the N9010) must call Action as if the user hit front palel's any key (hardkey, softkey).
How can I do it for X-Series Signal Analyzer?

It may be like existent "Virtual Panel" but plus additions. Analogue for Spectrum Analyzer 8593: SCPI command "KEYEXEC 1;" call the softkey N1.

Regards, Pavel Bega.
tabbott


Posts: 1,483
Registered: 07/24/09
Re: Remote program Hit the key of front panel. X-Series Anal
Posted: May 4, 2010 4:00 PM   in response to: bega in response to: bega
Click to report abuse...   Click to reply to this thread Reply
Hello -

All of the functionality of the X series analyzer can be programmed through SCPI commands. Therefore, it is not necessary to emulate button presses remotely. The remote interface allows the setting of measurements independently from each other. For example you can setup your channel power measurement and your ACP measurement and then can remotely tell the analyzer to go make the channel power measurement and then go make the ACP measurement without having to setup the second measurement after the first one has been made. This makes it possible to more quickly make repeated measurements.

Regards -
bega

Posts: 11
Registered: 12/17/09
Re: Remote program Hit the key of front panel. X-Series Anal
Posted: May 11, 2010 11:28 PM   in response to: bega in response to: bega
Click to report abuse...   Click to reply to this thread Reply
Hello.
Sorry, you solution don't solve the my task.

I develop the my program (adapter) on N9020A and remote button control of analyzer through adapter.

Regards.
Pavel Bega.
Kleb

Posts: 20
Registered: 07/18/07
Re: Remote program Hit the key of front panel. X-Series Anal
Posted: May 12, 2010 9:36 AM   in response to: bega in response to: bega
Click to report abuse...   Click to reply to this thread Reply
Hi Pavel,

Do you want to press buttons on the X-Series Analyzer using C# or do you want your C# program to know when a user presses a certain button on the analyzer?
bega

Posts: 11
Registered: 12/17/09
Re: Remote program Hit the key of front panel. X-Series Anal
Posted: May 13, 2010 12:38 AM   in response to: bega in response to: bega
Click to report abuse...   Click to reply to this thread Reply
Hello.

My remote program (C#) must press the button on the X-Analyzer.
The task was solved.
On remote computer I have the socket-client (C#). On Analizer I have the socket-server (C#). Remote program send KeyNumber to the Analyzer. The program in the Analyzer receive KeyNumber and invoke the keyboard message (Win API) to the Analizer Agilent.SA.xSA.exe program window.
As you see it is a long way. It will be cool if a remote program will have possibility to press key through SCPI command.

Regards,
Pavel Bega.
Kleb

Posts: 20
Registered: 07/18/07
Re: Remote program Hit the key of front panel. X-Series Anal
Posted: May 13, 2010 9:27 AM   in response to: bega in response to: bega
Click to report abuse...   Click to reply to this thread Reply
Do you mean pressing the front panel buttons such as FREQ or MARKER? Or do you mean pressing other keyboard buttons such as A-Z or 0-9. I am not aware of a SCPI command that can send other keyboard keys to the analyzer remotely.

If the former, almost all functions that you can perform using the front-panel keys have corresponding SCPI commands that can be sent to the analyzer remotely to perform the same functions.

For example, to set center frequency to 50MHz, you could use the SCPI command:
:SENSe:FREQuency:CENTer 50 MHz

This is from the help text that you can get by pressing the green Help key on the front panel.

To send SCPI commands, you can use the Agilent IO libraries VISA driver. Here is some example code. There are also many other examples of how to use VISA that come with Agilent IO libraries.

using Ivi.Visa.Interop;
...
string InstrumentHostname = "A-N9020a-00000";
string connectionString = "TCPIP0::" + InstrumentHostname + "::inst0::INSTR";
FormattedIO488Class _instrIO = new FormattedIO488Class();
try
{
ResourceManager grm = new ResourceManager();
_instrIO.IO = (IMessage)grm.Open(connectionString, AccessMode.SHARED_LOCK, 2000, "");
}
catch (SystemException ex)
{
Console.WriteLine("Open failed on " + InstrumentHostname + " " + ex.Source + " " + ex.Message);
_instrIO.IO = null;
}

bega

Posts: 11
Registered: 12/17/09
Re: Remote program Hit the key of front panel. X-Series Anal
Posted: May 17, 2010 2:07 AM   in response to: bega in response to: bega
Click to report abuse...   Click to reply to this thread Reply
Good day.

I was developed many applications in SCPI. It is a good way for automatic measurement.
But in the case:
< "If the former, almost all functions that you can perform
< using the front-panel keys have corresponding SCPI commands
< that can be sent to the analyzer remotely to perform the same functions."

I must write a huge user dialogue tree for all ~2500 commnds (it is right my task)! It is a big work.

There is another method. There is only 40 buttons on front panel. All the more the user is familiar with buttons.
Agilent was solved analogue problem in the Virtual Front Panel (for N9020A - Agilent.SA.VFP.exe).
I shoose this way and develope adapter because of:
- the Virtual Front Panel have poor user inerface;
- the Virtual Front Panel program (also as main program Agilent.SA.xSA.exe) has not the open program interface;
The SCPI command "Press the button N..." will be lighten my work.

Regards.

Point your RSS reader here for a feed of the latest messages in all forums