Discussion:
Multicard (1-5 cards) HSDIO 6552 Question: Data Delay, Voltage Config,Load Wfm,Script Trigger, Immediate Stop at Nth Error, Fetch Errro Location and Bits
(too old to reply)
engwei
2008-07-17 04:40:06 UTC
Permalink
Hi All,
 
I m newbies in Labview programming, as attached code will show it.
I m now using single 6552 HSDIO card to do some function like: Data Delay, Voltage Config,Load Wfm,Script Trigger, Immediate Stop at Nth Error, Fetch Error Location and Bits. (code attached)
 
I m gona implement it in multicard mode.
 
After refer to the example (TClk Data Gen and Acq), I m start worry about the Load Wfm, Script Trigger, Stop ASAP at Nth Error detected, Fetch Error location and bits.
For some identical part, a simple FOR loop will do.
 
My Question:
1. So, I plan to keep the data delay and voltage config for each card in array. Then they will have different delay or voltage level according to the array. Let say,
array[0] = 10ns, array[1] = 5ns .. by this way, I can config different delay for different card. I can do the same thing to have different voltage level for different card. Am I right ?
 
2. About the wfm files, I m confuse about where the waveform files gona loaded. a "niHSDIO Write Named Waveform" subvi will do ?
 
3. Let say, 1st HSDIO card generation channel (0-14), 2nd HSDIO card generation channel = (5-19),  waveform of 30 channel will loaded properly to these cards ? I need to confirm this because I will need this flexibility in debugging.
 
4. In the code attached, I always check the error samples detected. If error samples more than 0, then it will stop as soon as possible. Can some1 give me some idea on how to implement it in multicard mode ?
 
5. About the script trigger. I put a while loop after "niHSDIO Initiate" vi, so I will always look for user input. If I need it in multicard mode, so I just put it after the "niTClk Initiate" vi ?
 
6. About the fetch error location and bits for multicard mode, I only need to put a  "niHSDIO HWC Fetch Sample Errors (U32)" vi to fetch the error samples ? The error location will automatically incremented at the output ?
 
Sorry for the damn long question. Please help for my doubt above .. Your help will be much appreciated ..Thanks ..
engwei
2008-07-17 05:40:05 UTC
Permalink
forum.vi:
http://forums.ni.com/attachments/ni/70/9195/1/forum.vi
Jaime F
2008-07-17 20:10:06 UTC
Permalink
Hi Engwei,


This is a very interesting situation even though you are a
newbie you are dealing with one of or more advance cards. But no reason to be
scared we are here to help. Form your post seems that you are good to go configuring
your data delay, voltage, load wfm, triggering etc.


As you said for configuration you can use a simple for loop.
For other things like reading and comparing take a look at examples: ?Multi-Device
Dynamic Acquisition (TClk).vi?. For question #1: The NI-HSDIO instrument driver
allows one acquisition task (and one generation task) to run on a
single device. Acquisition voltage levels are configured once per task,
and only one voltage level can be used per task. The same condition is true for
a generation task. However, the voltage level for the generation task can be
different from the voltage level for the acquisition task. If you are
using multiple devices, you can obtain multiple voltage levels by setting each
device to a different voltage level.


Question #2: niHSDIO Write Named Waveform will do, see how
they do it on the example, every time the ?for loop? iterates it writes and
configures a different 6552.  For question
#3, since each, ?for loop? iteration is the configuration of each card, you can
split your waveform and tell niHSDIO Assign Dynamic Channels which channels are
going to be used.


Question #4:  each
card will do their own hardware compare, controlled by their specific resource handler.
 I will suggest tryng to first read the
voltages in the multi card mode and then start doing the ?hardware? compare. Question
#5:  you are right seeing how the ?Multi-Device
Dynamic Acquisition (TClk).vi? example does the reading will be helpful.


Question #6: this is the tricky one, ?niHSDIO
HWC Fetch Sample Errors (U32)" will be inside a ?for loop? or a while
loop, but every time it runs it will only get the information of the resource
handler pass to it. So you will end up with arrays of the outputs.  

I hope it helps
engwei
2008-07-18 03:40:06 UTC
Permalink
Hi Jaime F, Thanks so much for your reply.Q1: Cleared, thanks.Q2,3:About loading waveform to HSDIO memory, if I have a single digital pattern file with 30 channels (30 columns), I will have to split the waveform files to 2 digital pattern files. And there is no other way to load the multicards memory from a single waveform (i.e. 30 channels of waveform files loaded to memory of HSDIO cards according to assigned channels.). So, I must split the waveform files. Am I right ?Q4:So, let say,First HSDIO = Channels 0-19Second HSDIO = CHannels 0-19 (20-39)If error samples detected on 2nd HSDIO with error location=300, error channels=5, I will have to build a vi to automatically recognize error channel =5 on second HSDIO actually means error channel = 24 (19+5) in multicards mode. Is it true ?Q5: I will try it.Q6: So, I will need to build a vi to recognize the error samples, as mentioned in Q4..Really thanks for the helps from this forum. :)  ..
engwei
2008-07-18 04:10:06 UTC
Permalink
Skip the previous reply. Sorry for inconvenient.Hi Jaime F,Thanks so much for your reply.Q1: Cleared, thanks.Q2,3:About
loading waveform to HSDIO memory, if I have a single digital pattern
file with 30 channels (30 columns), I will have to split the waveform
files to 2 digital pattern files. And there is no other way to load the
multicards memory from a single waveform (i.e. 30 channels of waveform
files loaded to memory of HSDIO cards according to assigned channels.).
So, I must split the waveform files according to number of HSDIO card
involved. Am I right ?Ok, if I m right. Let say the hardware script (for single card):script MyScriptGenerate wfm0end scriptSince the waveform files will need to split to 2 different files for 2 HSDIO cards, I will have 2 waveform files, let say, wfm0_card1 (channels 0-19)wfm0_card2 (channel 20-29)then, I will have to load different script to both card by a for loop, i.e.for card1script MyScript
Generate wfm0_card1
end scriptand for card2script MyScript

Generate wfm0_card2

end scriptAm I right ?Q3.1: Channels 0-29 will generate samples at the same time right (by TClk subvi inserted)?Q4:So, let say,First HSDIO = Channels 0-19Second HSDIO = CHannels 0-19 (20-39)If
error samples detected on 2nd HSDIO with error location=300, error
channels=5, I will have to build a vi to automatically recognize error
channel =5 on second HSDIO actually means error channel = 24 (19+5) in
multicards mode. Is it true ?Q5: I will try it.Q6: So, I will need to build a vi to recognize the error samples, as mentioned in Q4..Really thanks for the helps from this forum. :)  ..Message Edited by engwei on 07-17-2008 10:53 PMMessage Edited by engwei on 07-17-2008 10:56 PM
Jaime F
2008-07-18 17:40:10 UTC
Permalink
Hi Engwie,


Q2, 3: yes you have to split it and this is due to the architecture
of the driver, each write waveform will do it for the session handler passed
and the session handler passed is referenced to a card. Q4, you are right, that
analysis will be done on software, I would suggest building everything into an
array and using the index as the channel number. For the script trigger you are
also right, although some testing won?t be harmful since I have not try this
approach personally, let me know if it works.  Q3.1, yes, samples are going to be generated
at the same time.


I very interested in the application you are building, do
you mind explaining a little bit more the big picture, what type of testing are
you doing? What is the ultimate goal? If you don?t mind cleaning your code and
attaching it I might have the chance to try it, I don?t promise anything but it
won?t harm having the code on the forum.


I wish you the best
engwei
2008-07-21 04:10:06 UTC
Permalink
Hi Jaime F,
 
Thanks again for your reply. Implement a multicard digital test would be my ultimate goal. It will generate and acquisitite digital pattern. I m still working on the code.
Any further suggestion pls just let me know. Thanks.
 
-----
engwei

Loading...