06-27-2018 01:49 AM
Dear NI family,
I am trying to output 4bit(0000~1111) digital data through 4 lines through DAQ by labview.
But I am curious how does the digital data send out through DAQ, serial or parallel?
For example, if the 4 lines' digital data are 1011 1001 1010 1111, they will be send out in the same time. How will they go? Do they go like serial type (1-0-1-1 1-0-0-1 1-0-1-0 1-1-1-1) or parallel type (just together)?
The type should be serial since only one line for the output 1011, right? If I set the timing control to be 800ms, then 1-0-1-1 each 1 or 0 will take 200ms, right?
Thanks!
Best,
Richard
Solved! Go to Solution.
06-25-2018 10:30 PM
Dear ALL,
Hi there!
I am new with Labview 2016. I am using DAQ PCI6221. I hope to write 4 bit (0000~1111) digital data with 4 lines to a 4*4 matrix of pixel circuit with resistors (like active matrix) row by row. Each line should send serial data and then transfer to analog voltage.
Questions:
1. Could you please show me how to achieve the functions? Is there any snippet or example?
2. How to control the timing?
Thanks very much!
Best,
Jason
06-27-2018 04:19 AM
@leo321 wrote:
If I set the timing control to be 800ms, then 1-0-1-1 each 1 or 0 will take 200ms, right?
No. The four lines will go to their respective states at the same time, wait 800ms, then go to the next state.
06-27-2018 04:26 AM
Thanks for your reply!
So the digits will send to the DAQ and outside circuits in a parallel type, right?
May I ask how to change the 4 lines of digits in a serial way to the real world?
Thanks again!
Best,
Jason
06-27-2018 06:05 AM
The simple way would be to increase your array size so that you only change 1 of the lines each timing cycle. This would make your array 4x larger.
06-27-2018 09:50 AM - edited 06-27-2018 09:50 AM
06-27-2018 09:52 AM
I don't have a clear understanding of what you need. What do you mean by "each line should send serial data and then transfer to analog voltage"? I also don't know what's meant by a "4x4 matrix of pixel circuit with resistors", it's not my field.
Can you please explain in more detail what you need the board to do in terms of signals and timing? Key questions:
- how many distinct digital signals are there? (Same as the # of physical wires used to carry them, give or take a common reference.)
- what are the timing needs for the digital states on any one signal?
- what are the timing relationship needs from one signal to another?
- what exactly do you mean by "serial data"?
- what exactly do you mean by "transfer to analog voltage"?
An M-series 6221 will have capabilities for precision-timed digital signals, but it's a little indirect. A good search term to use to find examples is "correlated DIO".
-Kevin P
07-05-2018 02:51 AM
Dear Kevin_Price,
Sorry for the delay getting back to you!
Like 2T1C Active Matrix, I got a 4*4 matrix of pixel circuits.I got PCI-6221 and a breadboard with chips such as S/R, DAC etc. I want to use LabVIEW to generate 4-bit digital data (0000~1111) to DAC to get analog voltage for the pixel circuit. As you know, each row of the matrix has 4 pixels, so I need to send out 4-bit digital data through 4 lines in serial (each line for one pixel in a row) to 4 shift registers (serial transform into parallel). Then the parallel digital data will go to the DACs for transforming to analog voltage.
For your questions:
1. Digital data will be sent out row by row and each one of them is from the range of (0000~1111). So 4 *4-bit digital data through dacs.
2. Like active matrix, scan driver to select a row periodically and data will be sent to the row selected.
3.Timing should be changeable according to demand
4. serial data: for example, we want to send out 1101 to first DAC, the data will be sent by 1 line as 1-1-0-1
5.Mentioned above.
Thanks very much!
Best,
Jason
07-05-2018 03:27 AM
Hi crossrulz,
Thanks for your reply!
No. For example, I want to generate 4*4-bit digital data (it means 1111,1110,1101,1100) but there are 4 lines in total, so each line for a 4-bit data, 1111 will send out by 1 line.
I set labview to generate 4 different digital data through 4 lines. So they will be sent in serial way, right? If wait is set as 800ms, 1-1-1-1 each digit will take 200ms,right?
Thanks again!
Best,
Jason
07-05-2018 03:55 AM
Hi leo,
in the mean time you could have tested all that with your DAQ device and some LEDs! Did you?
So you have one DAQmx task, which includes 4 digital output channels: when you write "n channels n samples" then those 4 channels will show the same element index in the array at the same time.
All 4 channels output the first sample, then your DAQmxTiming is applied, then all 4 channels output the 2nd bit, and so on…