When do you expect the acquire the pulses? One simple solution would be to just increase the timeout value or set it to -1, i.e. infinite.
If you have some sort of triggering pulse which precede the acquisition you could wait for that before you enter the read vi part of your code.
Having similar problem,
Did you manage to resolve the issue?
I have attached the the solution given by NI for error code 200474, if its any use. The problem I have just found with this Vi is that if one channel has no signal it forces the other channel to grind to a halt. This problem has existed for me on the cards being used in this project PXI-6289 and PXI-6236, also other DAQ cards used in a different project earlier in the year.
It seems to be a serious flaw in the application of the NI DAQ cards to general purpose data logging where counter signals might not be connected by the end user or they are very low frequency and the whole system hangs.
Can't look at the code now because I don't have LV near my network PC. However there is a fairly simple workaround for this kind of situation. Basically, make the timeout work *for* you rather than against you.
Calling DAQmx Read with a long timeout (or a -1 for an infinite timeout!) implies that you really want the next measurement even if you have to wait a long time for it. You could instead choose to call DAQmx Read with a pretty short timeout and then detect whether the timeout occurred. (You'd probably have to catch the error out cluster, verify that the error is the timeout you half-expected, and then erase the error). When the timeout occurs, you'll know your freq is getting down there fairly close to 0. In many apps, you could probably set a timeout of, say, 0.25 seconds. Then you can get real measurements down to about 4 Hz, and any freq less than that can just be assigned as 0 freq.
Thanks for the Vi, I had just got back to this problem and found your solution so time saved. Implemented it on 4 counter channels and it works a dream.
With regard to my earlier posts on this subject they were/are current as the post was at the end of 2007.
This example has been a great help to me already but I'd like to take it a step further. Is there a way to log (to a TDMS measurement file) the frequency data that is measured? I'm sure there is a way, I just don't know what that way is. I tried using the express VI Write to Measurement File but when I import the TDMS file into Excel, I get a new worksheet (tab) for every single data point - not exactly what I had intended. I hope to save the frequency value at evenly spaced time intervals.
Thanks you in advance!