Quantcast
Channel: Digital I/O topics
Viewing all articles
Browse latest Browse all 2178

NI MAX vs. actual Digital I/O

$
0
0

Hello,

 

while getting familiar with my NI6612 and C# something is really confusing to me. As far as I understand each digital line can only I/O a boolean state while counters are able to create/measure pulsetrains. According to the manual, I am allowed to use a PFI line as an external trigger for my actual pulsetrain created by the counter. Now what does that mean and how do I carry this out?

 

For example: In NI MAX I sucessfully created a task on PFI1-Line where I just tell MAX the desired type (continious, finite pulses, etc.) and frequency and I get an actual pulsetrain out of this PFI1-line which is even physically measureable. However looking inside the c# examples like "WriteDigChan" it asks me for some sort of data array with 8 boolean inputs. I do not understand what this dataArray is actually good for nor understand the errors I get which are stating discrepancies between "Number of Lines in Channel" and "Number of Lines in data" as I actually try to adress only PFI1 and no other line (or channel). Additionally I can say, that the NI MAX testpanel confuses me in the exact same way as the C# example when it asks me about "all high" or "all low". I guess I have a deep lack of understanding regarding how NI MAX actually outputs a pulsetrain (digital waveform) on PFI1 and what it is actually internally doing.

 

Please consider, that I don't want to use and occupy a second counter just to trigger my first counter pulsetrain if avoidable. Thank you in advance.


Viewing all articles
Browse latest Browse all 2178

Trending Articles