Author Topic: Instrument Remote Control Scripting  (Read 1367 times)

0 Members and 1 Guest are viewing this topic.

Offline luudeeTopic starter

  • Frequent Contributor
  • **
  • Posts: 294
  • Country: th
Instrument Remote Control Scripting
« on: May 16, 2023, 08:46:25 am »

Hi Guys,


in an effort to be more sophisticated with all the equipment
I have been collecting over the years, I decided to get in to
the programming of it all. Specifically, remote controlling of
the equipment.

So, I was wondering, is there a global depository for such scripts ?
I am sure we all could share them, if allowed by our employers.

May be we can have a File Area @ EEVBlog, where such files can
be deposited. But I think it needs to be moderated, to make sure
submissions are owned by the people submitting them and it is a
relevant script ... How do I get Dave's attention?


So far I have written two very simple scripts. Most of them are
SCPI, but some (ITECH) uses a serial Frame format. I use a Serial
to Ethernet bridge for that equipment (HF5111B).

1. Battery Emulator
This script should work with most R&S PSUs. I have tested on
a NGP804 and NGU401. It takes a starting voltage, a end voltage
and battery capacity in ah. The output voltage is linearly
decreased from starting voltage to end voltage until all
(virtual) energy has been depleted and the battery is shut
down.

2. A Pulse generator for my DC Load, ITECH IT8513C+
This basically takes 3 current/time settings and plays them back
when a trigger is issued. The idea was to have a 'pre' and 'post'
settings, as well as a main setting, that's the actual pulse I
am interested in, the pre and post are just to start and stop in
a known state.

Both of these scripts are written in python, but do not have
a GUI, only CLI at this point. Maybe someone would like to write
a gui ?


Cheers,
luudee
 

Offline coromonadalix

  • Super Contributor
  • ***
  • Posts: 7958
  • Country: ca
Re: Instrument Remote Control Scripting
« Reply #1 on: May 16, 2023, 10:26:55 am »
If your files aren't big, you post them here in your thread ... they will be kept

and maybe if people see your scripts they can or could  create some gui,  maybe

And you have some software here  testcontroller   who can possibly do the job, the author is here and answers your questions .. just need to create the needed file(s) and structure to control your instruments

https://www.eevblog.com/forum/testgear/program-that-can-log-from-many-multimeters/
« Last Edit: May 16, 2023, 10:32:08 am by coromonadalix »
 
The following users thanked this post: luudee

Offline luudeeTopic starter

  • Frequent Contributor
  • **
  • Posts: 294
  • Country: th
Re: Instrument Remote Control Scripting
« Reply #2 on: May 17, 2023, 04:52:27 am »

Thank you for your feedback coromonadalix !

I was hoping for a central depository for the scripts. If you search Git hub
you can see that there are dozens of scripts there as well, but it's all over
the place ...  I thought it would be neat to have a central place, organized.

Yes, I have seen testcontroller and have attempted to create stubs for what
I want to do. But even with the authors' help, I could not get it to do what I
want (which is NOT logging).

Cheers,
luudee

 

Offline luudeeTopic starter

  • Frequent Contributor
  • **
  • Posts: 294
  • Country: th
Re: Instrument Remote Control Scripting
« Reply #3 on: May 29, 2023, 07:04:12 am »


Hi Guys,


here are my versions of the sweep tool for the NGu-401 SMU and Battery simulator
that will work with NGP-804 and NGU-401.


Cheers,
luudee

PS:  Strange, I can upload "tar" file, but not compressed tar file, e.g. tgz ot tar.gz
 

Offline dobsonr741

  • Frequent Contributor
  • **
  • Posts: 825
  • Country: us
Re: Instrument Remote Control Scripting
« Reply #4 on: May 29, 2023, 03:14:49 pm »
When I see SCPI and python I recommend useing Jupyter notebooks. Immediate gratification in visualizing and you can easily put up buttons, if ever needed.

You do all of it the browser, can dicument the measurement results very well, along with the code in one file.
 

Offline luudeeTopic starter

  • Frequent Contributor
  • **
  • Posts: 294
  • Country: th
Re: Instrument Remote Control Scripting
« Reply #5 on: May 29, 2023, 03:31:39 pm »
When I see SCPI and python I recommend useing Jupyter notebooks. Immediate gratification in visualizing and you can easily put up buttons, if ever needed.

You do all of it the browser, can dicument the measurement results very well, along with the code in one file.



Hi dobsonr741 !

yes, you have suggested it in another thread I have started. I did actually did  look at Jupyter,
and the complexity of "getting started" appeared to be much higher than what I was willing
to invest! ;-)

I am a hardware engineer by trade (have been designing custom chips for 30 years). I am
forced to use Eclipse as part of the Xilinx tools (which we use for prototyping), but did not
want to deal with that when I don't get paid, lol

I have evaluated about a dozen development environments, about half of those I evaluated
in greater depth, by installing the IDE and giving it a try.

For ME, python, and QT5 was the easiest way to get a good-looking GUI going in the shortest
amount of time. For the actual interface with the instrument, any language would have worked,
I am still using perl for my day-to-day scripting, lol. May be I will finally adopt Python. It seems
it is better in handling some aspects and worth with others ...

Please do try the tools. The plots it can generate are actually quite nice and pretty, you can
zoom in and get readings from enlarged selected areas, etc, etc ...

BTW, it took me less than a day to design a first (decent) GUI !

Best Regards,
luudee






 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf