From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

The Daily CLAD

Community Browser
cancel
Showing results for 
Search instead for 
Did you mean: 

Re: CLAD2017 - DAQmx - Samples per Channel or Number of Samples per Channel

SercoSteveB
Active Participant

Consider the VIs shown below that are functionally identical accept for the values of the constants 'samples per channel' and 'number of samples per channel'.  Which of the following show the contents of VI1 Data Array Size and VI2 Data Array Size following execution of the VIs.

 

DAQmx Samples Per Channel #1.png

 

DAQmx Samples Per Channel #2.png

 

a)

DAQmx Samples Per Channel Answers #1.png

 

b)

DAQmx Samples Per Channel Answers #2.png

 

c)

DAQmx Samples Per Channel Answers #3.png

 

d)

DAQmx Samples Per Channel Answers #4.png

 

 

 

Comments
GladysToMeetYou
Member

A

PakAsia
Member

A.

In VI1 DAQ only wants two samples and in VI2 there are only two samples available.

timmy
Tsjabrantes
Member

Hello guys!

 

VI_1VI_1VI_2VI_2

So, letter A is the right answer. Smiley Wink

Tarciso Junior
+55 (11) 996-282-103
Skype: Tarciso.junior2
Email: Tsjabrantes@gmail.com
http://br.linkedin.com/pub/tarciso-junior/23/a83/463
crossrulz
Knight of NI

A

 

First clue is that there are two channels.  Therefore the size of the first dimension will be 2 for both.  A is the only one that works with that requirement.


GCentral
There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
Ellie90
Member

a

A_rid
Member

A

nik35324
Member

A

Matt-A.
Member

A

qubirt
Member

A

CataM
NI Employee (retired)

a)

SercoSteveB
Active Participant

Answer: A.  Nice one all.

 

 

Miguel_Reckon
Member

Ninguna de las anteriores! Debido a que no hay ningun ciclo que permita al READ DAQmx adquirir la muestras nuevamente

 

Captura.PNG

Al_Niz
Member

@ Miguel_Reckon Translation: "None of the above! Because there is no loop that allows the READ DAQmx to acquire the data again"

 

No loop is needed to get a 2x2 array because we read 2 channels simultaneously (ai0 and ai1).


image.PNG

arraySize= (number of channels) x (number of samples).

Oleksiy7979
Member

Can somebody explain why we have 2 sample points to read, not 4 from the second VI?

crossrulz
Knight of NI

The DAQmx Timing is setting up the task to be Finite Samples and the number of samples is 2.  So after 2 samples are read, the task will stop.


GCentral
There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
istan0227
Member

A