Hello!
How can I use 2 different PFI on the same counter with tasks? I have PFI0 and PFI1 in use.
Many thanks!
Hello!
How can I use 2 different PFI on the same counter with tasks? I have PFI0 and PFI1 in use.
Many thanks!
Trying to use edge counters in the NI 9401 module in cDAQ9174 chassis, LabVIEW 2016. Want to read single channel, multiple samples from the module. I get error -200284, which is "Some or all of the samples requested have not yet been acquired." I am able to get single channel, single sample working, so I believe the hardware is functioning. Anybody see what I need to change to get it working?
Dear all,
I used to do a lot of LabView long time ago, and I am a bit rusty...
I am trying to implement 'Buffered Edge Counting' as illustrated in the X-series manual, fig7.3 ( that I attached just in case).
I am a bit lost...
I know that I need to use the internal 100MHz clock base as 'source', and the signal that I want to know when arrives is named the 'sample clock'.
When I go to table 7.8 of the same manual is stated that for 'Buffered Edge Counting', the purpose of source terminal is 'input terminal'...
But none of the examples available on LabView (under "Hardware Input and Output" --> "DAQmx" --> "Counter Measurements") seems to correspond to a 'Buffered Edge Counting'.
I am using a bit old version, LabView 11.0.1, with DAQmx14.5. The hardware is a USB-6343 of the X-Series.
Anybody willing to share a very basic vi screen-shot to illustrate it, together with where the input needs to be connected (hardware I mean)???
Thanks in advance!!!
Confession: The worst of all is that I already did the same thing 15 years ago with a E series and I can not find the code...
Hello,
I have an LM10IC13BBB10F00 (datasheet attached) differental linear magnetic quadrature encoder which I'm using a NI USB 6211 to read the positive channel (A, B) with. It works well even though I do not get the full differential capability the 6211 has to offer. I would like to use the USB 6211 to read the encoder signal from a linear optical encoder, specifically the RGH24H15F30A. Connecting the RGH24 to the 6211 in the same manner, I am not able to read any signal through NIMAX.
Could someone help me troubleshoot this? A bit more info follows.
Thank you for the help.
Best,
Alex
Dear all,
After my basic question (https://forums.ni.com/t5/Counter-Timer/Basic-Buffered-Edge-Counting/m-p/3941541#M14321) was solved (thanks again Kevin), I have another question (this time less basic, I think)
A quick reminder if what I am trying to do:
Timestamp some incoming TTL signals, for this I am counting edges using:
"Input Terminal"=>: /Dev1/100MHz Timebase
"Timing Settings: Sample Clock Source'"=> /Dev1/PFI8 (the signal I want to timestamp, with the 100MHz timebase).
I have added a reset trigger signal at /Dev1/PFI9. (This is well documented and I know how to do it)
So far so good.
However: I need to treat the data that came between two reset trigger signals, but how to get that information?
I am running a loop, with the acquisition set at "continuous" and reading "All available", but how to trigger an action upon the rising edge of the PFI9, which is used as a reset signal?
Any ideas?
Regards
Hi,
I am using a PCIe-6353 DAQ card and try to figure out what the 'allowed' frequencies are. I found some threads about it but I am not sure I understood everything correctly. This article comes pretty close:
https://knowledge.ni.com/KnowledgeArticleDetails?id=kA00Z000000P83OSAS&l=en-US
As far as I understand, the CO can only generate signals at multiples of its internal clock. For the PCIe-6353 that should be 100 MHz (I think; the datasheet has different values for "Sample clock timebase"), 10 ns respectively. So let's say I want to generate a clock at 140 kHz (period 7142.86 ns). With a time base of 10 ns, an integer no, of ticks is therefore not possible. Following the linked article, the device will actually output the closest frequency that can be represented by an integer No. of ticks. In this case 139.86 kHz or 140.056 kHz, depending if one rounds up or down.
My question is:
1) Did I understand it correctly?
2) The article above says one can use the DAQmx timing property node "SampleClk.Rate" to read the actual frequency. WHen I do that with a simulated device, I get exactly 140 kHz, which should not be (see above). Is that because of the simulated device?
3) Isn't it better to calculate the allowed frequency myself and use this as input? This way I know exactly what is actually happening. imagine I have another external device but can only synchronize the start, not the clocks itself. In that case it will make a difference if I set the NI card to 140 kHz (running at 140.056 kHz) and the other device running at exactly 140 kHz. If i would just set it to a value that can actually followed exactly, the synchronization should be better - assuming the other device can actually run at exactly 140 kHz)
Thank you
Hello Everyone,
This is my first experience with the USB 6001 and DAQExpress. After reading some other posts, I realize this device is not well suited for incremental encoder reading. Nonetheless, I believe my application is simple enough that it just might work.
I want to measure wire feed speed using an encoder which is attached to a roller of a known diameter. I don't need direction or position, just speed. I do not have any other inputs/outputs.
Could someone please suggest an approach?
Thanks a lot!
Hi,
I am using a counter NI 9361 with a CRio 9040 and Labview 2017 SP1 f3 - NI RIO 17.6 - NI DAQmx 17.6. I configured the Module in FPGA mode. I based my FPGA code on the example provided with Labview 2017 (NI 9361 Counter Digital Input - FPGA.vi + NI 9361 Edge counting (Host).vi). I slightly modified the configuration of the module in the RT part to run in "Quadrature encoder velocity mode". When I run the VI, the FPGA get stuck in the initialization phase (the first module property node).
I found a fix which enable the code to run : set the NI 9361 in Real-time resources mode, deploy it and run another RT VI which contains DaqMX acquisition of this module (quadrature velocity mode). When I configure the module in FPGA mode and run the RT VI the acquisition worked.
I am not able to run the RT Vi every time that I either restart the CRio or change the FPGA Bitfile.
I can run the VI if I disconnect the CRio or close/reopen the project.
Did anyone had similar behavior ? Is there a configuration required at start up in FPGA Mode ? (I looked all the module properties but I couldn't find anything)
Thank you in advance for your help.
Hello,
I have a PCIe-6353 DAQ board, which has 4 clocks available. I am already using all four of them and am now looking for a way to make one of them available for another task.
This is what I would like to do but I am not sure if that is possible:
- ctr 0: I generate one clock every 10 ms, which is used as trigger signal
- ctr 1 is set up to generate a clock every 10 us. The timing is set up finite output of 1000 samples, retriggerable and triggered by ctr0. This basically equals a constant pulse train
- ctr 2 is doing exactly the same as ctr1 except that a smaller number of clocks is generated.
Since ctr1 already defines the frequency etc, do I really need ctr 2 to do the same just for defining a different number of output clocks? The only thing that changes beytween ctr1 and ctr2 is the DAQmx timing VI settings.
Thanks!
I recently bought PCIe 6738, which was supposed to have 4 counters.
However, from the look at the device pinouts of the card, it seems that there are actually 2 counters that can be used simultaneously.
Essentially, ctr0=ctr2 and ctr1=ctr3. If one cant use the 4 "available" counters at the same time, can one say the board actually has 4 counters?
I don't know if I am missing something but it would be great if could get some clarification.
Thanks.
Can one use the PFI0 and PFI1 counter inputs pins of USB 6001/2/3 for measurement of quadrature encoder pulse inputs?
The quadrature encoder under consideration is having following details :
Type : Incremental encoder, Single turn 2500 ppr. 5V signal.
Interface signals : A, B and Zero.
Thanks & Regards
Hello, I am new to the forum so I am not sure where to post my question, I hope someone can help me.
I am trying to measure a PWM duty cycle using the C functions for DAQmx, but I am having trouble creating a Channel for this purpose. I can successfully read the duty cycle using the MAX task interface.
Does anyone have a code example? I'm guessing there is an issue with the parameters I'm using with DAQmxCreateCIDutyCycleChan, I've been testing with the "counter" and "max/minFreq" parameters, trying several combinations like Dev1/ctr0/PFI1, Dev1/ctr0, Dev1/PFI1 or Dev1/portctr0/line2 for Counter and using Hz or Time for min/maxFreq. Usually I'm getting error codes like 22, 17 or 18.
Thanks in advance.
I have two signals from two devices and I want to delay one of these signals for a time when the other signal is coming? how I can do that? I have tried counter and delay time but it is not working.
I've been trying to raise this on the PXI board (https://forums.ni.com/t5/PXI/Generating-a-variable-clock-pulse-train/td-p/3959809) but realise this may have been the wrong place.
I have a PXI 6683H card, and am trying to generate a variable clock - that is, I want to generate some kind of clock, but then vary the clock frequency without completely killing the clock and starting again. I've tried some hacked up version of Generate Digital Pulses.vi from the example, but that tops out around 40Hz, and I was hoping to vary between 0 and 1MHz or so.
I might be able to specify the different clock rates in advance, if that helps.
I read the manual for PXIE6674T but I still have no clue on getting start with this module.
In my LABview, I cannot see any block for the PXIE6674T, but I do check the configuration on MAX that my PXIE6674 is there.
Can someone give me some example on this module? simply just need it to generate a 20MHz clock.
Right now I am seeing -2.5V ~ 2.5V in the oscilloscope. Is it possible to change the amp and offset of the clock signal? I what 0V~3.3V output 10MHz clock output.
Thanks.
Dear Sir/Madam,
I am conducting a dynamic light scattering (DLS) type experiment. I am using a SPAD type detector and Xseries PCIe 6351 DAQ from National Instrument.
The output of this detector is TTL pulses. So, I basically need to count the edges in some specific time bines. I need a 2D array with time bins as x and number of counts in each time bin as the y axis data, and preferably plot it on time so I can see the live results.
Would you please take look at my code attached to this email and see how can I fix the current issue.
Many thanks,
Maryam Torfeh Esfahani
Hi All
Using the C API for DAQmx 19.1 on a PCI-6601
I am trying to apply a digital filter on the gate input for my X1 counter task.
Linear encoder channel is created using DAQmxCreateCILinEncoderChan
The sample clock source (gate) is set to PFI30 using DAQmxCfgSampClkTiming
Filtering is setup for A and B inputs using:
DAQmxSetCIEncoderAInputDigFltrEnable
DAQmxSetCIEncoderAInputDigFltrMinPulseWidth
DAQmxSetCIEncoderBInputDigFltrEnable
DAQmxSetCIEncoderBInputDigFltrMinPulseWidth
I then want to setup filtering on the gate, but there is not specific method or property for this, for CountEdges there is DAQmxSetCICountEdgesGateDigFltrEnable but this returns error -200452 when I set it to true.
Is it possible to simply setup a filter on the physicl input PFI30 without linking it to a specific channel or task?
Thanks,
Simon
How do I setup digital filtering on the Gate signal (PFI30) for this task/channel?
Hi
Is it possible to poll the value of a counter that has a sample clock configured?
I am still interested in getting the counter value both at the time of the sample clock (normal buffered counter task), but would also like to be able to poll the value at any other time!
Currently this is solved (and working) by sending the same input to two independant counters - one setup with a sample clock and one setup without a sample clock. But that requires strict control of starting both tasks at the same time to avoid an offset between them (implemented using a third counter to generate a trigger signal).
I am using the C api and setting up the counter using DAQmxCreateCILinEncoderChan, and for the buffered counter DAQmxCfgSampClkTiming is also called to define the sample clock source and parameters.
A PCI-6601 card is used.
Hi All,
I have just taken delivery of a couple of 6612 Counter Cards and am having some problems getting them to work from my C code.
Has anybody got an example C code that covers setting up a task, clock, edges, etc then getting a count value out of a specific counter?
I believe that I am calling all the right functions to setup the above, each one returns 0 (no error) but when I try to start the task, I get an error code suggesting that the task is incorrectly configure. I must be missing some important step?
Any code/advice/pearls of wisdom for these cards would be most welcome.
Cheers,
Adrian