04-17-2011 03:25 AM
I have a PXI 6551 based HSDIO interface. I am using it to perform scan control. The basic idea I was trying to implement using labview VIs was the following:
Suppose 10 bits have to be scanned.
Step 1) Using port0 of DO, produce a 101010... 10 (sequence of 20) pattern to mimic a scanclock. A 1MHz internal clock leads to 0.5MHz scanclock. This is done using a 'generation express VI'
Step 2) The scanout signal coming out from the chip, has to be sampled at the falling edge of the scanclock.
I use the 'acquisition express VI'. I wire the D0 scanclock signal to the strobe input of DI.
Step 3) For successful read of scanouts, what we need is acquisition VI to be running and waiting for generation VI for the scanclock pulses and then stop. I am stuck here as I have both acquisition and generation express VIs in a single VI and I can't perform acquisition VI to wait for generation.
I tried using sequence structure to ensure 'acquisition VI' step before 'generation VI' but the former just times out and stops before moving to generation VI.
Regards,
Pulkit
04-17-2011 03:31 AM
I did go through this thread using signal express but it seems it is the same problem there unless I go into the DAQmx approach in which I guess I have to build my labview interface program from scratch.
04-18-2011 01:37 PM
It seems like you have a pretty typical application, and so I would reccomend starting from one of the example VIs that ships with LabVIEW. To find the examples, select Help»Find Examples. I would reccomend looking under Hardware Input and Output»Modular Instruments»NI-HSDIO»Dynamic Acquisition and Generation for a start. The "Dynamic Generation and Acquisition-Demo.vi" might be a good place to start.
If you have any more questions, feel free to post your code, as it may be easier to understand what you are trying to do with the visual help.
Regards,
Elizabeth K.
National Instruments | Applications Engineer | www.ni.com/support
04-19-2011 12:38 PM
Thanks this looks very helpful.
04-19-2011 03:58 PM
Hi,
I tried to modify the demo code that you poiinted out. We need the following:
Generate a 48 clock period scanoutclk. Scanoutclk is generated at channel 1 using a 101010.. data pattern. The falling edge of this clock samples the scanout data coming from channel 6. For example, if the on-board clk is 1Mhz. The channel 1 produces 48 clocks at 0.5MHz. The scanout data has to be sampled then at 0.5MHz.However, there is still problem in syncing. I tried two approaches:
1) Generation uses on-board clk and Acquisition uses strobe clock. The strobe clock is connected to the generation output port.
2) Generation uses on-board clk and Acquisition uses on-board clock at half frequency.Strobe should not matter.
I have posted the errors for the two cases in the attach.
I am also posting my code
Thanks for helping me out
Regards
Pulkit
04-25-2011 04:22 PM
From what I understand, you are generating a 0.5 MHz clock on that data line from channel 1. You want to sample the data coming from your UUT with this clock.
The 6551 needs to sample on a free-running clock. (The 653x series can do gated sampling and sample like you want them to). In order to take the 48 samples that you want to take, you may consider using a pause trigger to only take the samples that you wish.
You could also consider over sampling both the Ch0 output, and your input from your UUT and then compare the value of the channel from the UUT when the Ch0 goes from high to low.
If you want to provide a detailed description of your test setup, it may help us decide what the best option for you would be.
Regards,
Elizabeth K.
National Instruments | Applications Engineer | www.ni.com/support