09-11-2017 10:59 AM
Hello,
I am relatively new to coding and data acquisition system, but I would like to automate the switches for the Agilent 34903A to the point where, two switches will work together being turned on and off. For example, switch 1-2 will be in a cycle with time. So, if switch 1 is turned on (100hrs), switch 2 will be closed and when switch 2 is turned on (50 hrs), switch 1 is closed. This will be on a on-going cycle.
I have downloaded the driver for non-NI instruments and from my understanding, the codes for the actuator is built for turning switches on without automation.
With that being said, I was wondering if anyone can suggest how I can edit that code, or is it better to make a code from scratch?
Best Regards,
Saad Azam
09-12-2017
03:19 PM
- last edited on
01-08-2025
10:16 AM
by
Content Cleaner
I downloaded the drivers for the Agilent 34970 from here:
I then located the example I think you are referring to in example finder as 'Agilent 34970 Switch.vi'
This code appears to be doing what you wish. If a Boolean in the Boolean matrix on the front panel is 'on', the channel is added to the closed channel list. From this code, you can modify the program to perform the functionality you require. You will want to make this program run continuously (i.e. put it in a while loop) and then add some comparison statements somewhere so you switch channel A off if Channel B is on and vice versa. If you are new to LabVIEW and programming in general, this may pose a few challenges for you. Some helpful resources for you:
I would definitely recommend modify the existing example provided by Agilent as opposed to doing this from scratch with NI-VISA, the examples are there for a reason. If you need any more help, you may get a nice forum poster to help you modify the code or you can power through it yourself and post questions along the way.