06-19-2018 08:30 PM
Hi GerdW,
Thank you very much for your reply!
When it comes to the data driver, each time will need to write digital data to the 4 pixels of the row opened by the cyclic scan1, is there any example for this kind of situation? I find the example -- "digital continuous output.vi" in the labview, will this example help?
Thanks a lot!
Jason
06-20-2018 12:57 AM
06-20-2018 01:50 AM
Hi GerdW,
Thanks! The examples are very helpful!
1. My DAQ device is PCI6221. Now I hope to write 4 serial digital output of 4 bit data each (For example, if I want to send data to the 1st row, I should send data first and then scan1 opens the 1st row), is it possible? Could you tell me how to deal with it?
2. The timing sources can be divided into 2 parts: one for scan1 and data and the other for scan2 for measurement. If I use the state machine, how can I make these two timing happen?
Thanks a lot! I am very grateful!
Best,
Jason
06-20-2018 02:01 AM
Hi leo,
My DAQ device is PCI6221
Your device allows hardware-clocked DIO on port 0, the other pins only allow software-timing.
if I want to send data to the 1st row, I should send data first and then scan1 opens the 1st row), is it possible?
Sure.
First send your data on your digital pin dedicated to "data", then set the "open" value on "scan1" pin…
2. The timing sources can be divided into 2 parts: one for scan1 and data and the other for scan2 for measurement. If I use the state machine, how can I make these two timing happen?
What kind of "timing sources" are we talking about?
Which timing resolution? Which accuracy? Which clock rates?
(You really need to learn to ask "good" questions, see here or there…)
06-20-2018 02:22 AM
Hi GerdW,
Thanks for your advice!
1. As you can see in my post 2,
a. scan2 and measurement are used to scan the row I want (I mean I hope to create a button and whenever I click it I will get the results from measurement part through LabVIEW);
b. scan1 should run in a cyclic way;
c. 4 bit digital data should write in the same timing control as scan1;
d. Data should be changeable according to demands.
2. As PCI6221 got no onboard timing engine, I am trying to use counters as the timing control. For now, I got no demands on how fast or slow the scan1 should run, I hope to design the prototype of controlling and testing first.
Thanks again~
Best,
Jason
06-20-2018 02:32 AM - edited 06-20-2018 02:33 AM
Hi leo,
1a: use a state machine - or maybe a QMH driven by an event structure handling your buttons.
1b: use a loop or hardware timing
1c: do you want to output your 4 bits using 4 DO lines or just one analog output?
1d: that's the case most of the times…
2: The PCI6221 has an "onboard timing engine" as it allows hardware-timed AI and DIO!
Your image is quite nice, but it does not explain your "timing" issues…
06-20-2018 02:50 AM
Hi GerdW,
You are really helpful and I learn a lot from you.
1. The attached picture is the timing analysis I want to create through the controlling and testing system. But I am still confused about how to program the whole picture as a system.
Could you please show me how you would program in LabVIEW to make the scanning and controlling system?
2. For 1c, I want to output 4 bits using 4 DO lines.
Best,
Jason
06-20-2018 03:24 AM
Hi leo,
The attached picture is the timing analysis I want to create
That's what I was asking for!
I have to admit I'm not an expert in those DAQmx counter abilities and routing of signals, there are other forum members more proficient in - maybe they will add their thoughts on your problem.
Please also provide information about
- the desired clock rate
- do you want to output the clock signal too?
(I would tackle this problem using a cRIO and implementing all that timing requirements in the FPGA…)
06-20-2018 03:45 AM
Hi GerdW,
Thanks!
1. For now, I am not very sure about the clock rate, but the max rate of PCI6221 is 250 kS/s should be enough. We can assume one first.
2. No, I don't need the output of clock signal.
It's great you would spare some time for it! I look forward to your code very much, but I only got PCI6221, I don't know whether it's enough for the whole function. Do you know any examples or posts more or less the same as mine?
Best,
Jason
06-21-2018 12:50 AM
Dear NI family,
I am new with LabVIEW.
Could you please guide me on how to output 4 bit of serial digital data through 4 DOs into the DAQ and outside hardware?
Are there any examples? How to code for this demand? How can I control the speed of output?
Thanks a lot!
Best,
Jason