08-27-2017 05:03 AM - edited 08-27-2017 05:04 AM
How to generate a trigger after every, say N counts from a counter? I want to use only one counter for this application. when the count reaches N it should generate a trigger and then start from 0 again to count till N and generate a trigger.
08-30-2017 01:55 PM
There are some examples included with DAQmx for doing this (pulse generation with external clock), but one very easy way is to use CreatePulseChannelTicks using your tick source (e.g. a PFI pin), set it to divide down by the number you want to count, and then route CtrXInternalOutput (X=the counter channel) to whatever you want to trigger (or even just an output pin).
See http://zone.ni.com/reference/en-XX/help/370473H-01/mstudiowebhelp/html/2368bbdf/ and set the "lowticks" and "highticks" to sum to the number you want to count to per trigger.