02-27-2008 09:39 PM
02-28-2008 03:01 PM
JHu,
Can you clarify a few things about your application/setup?
What do you mean by "next operation"? Are you fetching another record or performing some software logic?
What other devices do you have in your PXI chassis?
02-28-2008 04:30 PM
Hi, Ryan.
Thanks for your reply. My experiment system is for measuring the spectroscopic data, and a wavelength-tunable laser is used here. This tunable laser wavelength is controlled by a stepper motor, so that the lasing wavelength can be changed step by step under the control of the program. I need to measure the total optical signal at each lasing wavelength. In my experiment, after receiving a laser pulse which is used as the external trigger for digitizer, the program will perform some software logic, and then drive the stepper motor to change the wavelength of the tunable laser. The stepper motor is connected to the computer with a NI USB-6008 DAQ pad, not through the PXI chassis. So I wish to know when these external triggers happen in my program, and then the program can drive the stepper motor to next step.
03-03-2008 10:04 AM
JHu,
It sounds like you are using the trigger to activate the stepper motor and then acquire the data for that specific wavelength, and then this process continues. Is that correct?
If so then you could use the State-Machine architecture to accomplish this. Your first state would be to fetch the data using your 5114. After the fetching is complete you would move to your second state, which would activate the stepper motor (using the 6008) and prepare the turntable laser for the next fetch. This process would then continue for each wavelength you want to measure.
03-04-2008 03:30 PM
03-05-2008 10:48 AM - edited 03-05-2008 10:52 AM
Hi
Every record is related to a trigger, so something you can try is changing the reference position to 0%, this means that if your record length is 1000 samples you will get the 1000 samples after the trigger was received. As a consequence of this setup every record is going to be held between two triggers.
I hope it helps
03-05-2008 03:02 PM
Hi, Jaime.
Thank you for your reply. I tried changing the reference position to 0%, but I still don’t get it. As you said, if my record length is 1000 samples I will get the 1000 samples after the trigger was received. And for example, if my sample rate is 5M S/s, then every record would be the signals on the time interval from 0s to 0.0002s (1000 divided by 5M). But the time between two triggers I sent to the digitizer is about 100 micro sec. So this record is not the signals between two triggers. I am not sure if my understanding is correct. I just wish that when every time the VI is called, it can return a record which contains the signals on the time interval exactly between two triggers, and then I could directly calculate the definite integral of the signal on this time interval. Can I perform this with NI SCOPE Express? Thank you for your help.
03-06-2008 01:24 PM
Hi,
Reading the value of the trigger is not an option for scopes; triggers are intended for synchronization so they can only tell the card when to read or to latch data but you cannot read in LabVIEW when they happen.
So you have to option: either you make the number of sample big enough to read 100 us of data or you read continuously in both channels, CH0 is your signal and your trigger instead of going to the TRIG input it will go to CH1. Then you can use post processing on both of the signals to do the integral between two risings edges of your signal in CH2.
I hope it helps