11-16-2021 02:47 PM
I'm attempting to get a single pulse burst signal of 5V, with a width of 1ms on an Agilent 33220A function generator. The LabVIEW PC is connected to the instrument through a USB cable. The problem is when we send the commands through LabVIEW, we get a different signal output than when we press the buttons on the face. We have confirmed that the configurations are the same when the signal is sent.
We've noticed that the output is closer to what we want when the output is turned off at the beginning of the script and then turned back on just before the FG trigger is sent. However, we only get the correct signal when the oscilloscope trigger is at particular values, i.e., 3.50 V and 3.56 V. I've attached the vi. Will someone take a look at it to see if there are any places I can tweak to try to fix the problem?
Solved! Go to Solution.
11-17-2021 03:36 PM
This has been solved by putting a time delay both before and after the trigger.
11-17-2021 03:42 PM
@jringo6dx wrote:
This has been solved by putting a time delay both before and after the trigger.
Sounds like a workaround for not completely understanding how your instruments work.
12-01-2021 08:25 AM - edited 12-01-2021 08:29 AM
@billko wrote:
Sounds like a workaround for not completely understanding how your instruments work.
You're absolutely correct. I'd appreciate it if you know the instrumental reason I needed to implement this workaround and could share it with me. I need to understand the instrument better to write an additional, more complicated script here very soon. The fact that it is in LabVIEW is irrelevant, because I need to understand the way it communicates using VISA, as the code will get translated to a different platform other than LabVIEW when it's all done.
I have a sneaking suspicion that it has to do with timing; the instrument takes a certain amount of time to execute a command given to it, and my LabVIEW code is sending new commands before the previous one was completed. I could not find any alternate explanations, although googling random "function generator + {keywords relating to time delay fixes labview VISA commands}" for about two hours and scanning the user manual is not what I'd call deep research.