LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Callback stops for no reason.

Hi!

I have a big problem with NI-DAQ that I need help with.

I'm using the Config_DAQ_Event_Message(...); to notify my application when a certain number of scans has been sampled. I have a PCI-6024E DAQ board and I split the 200000 kS over 5 channels giving them 40000 kS each. My Callback function is set to be notified every 40 scans, which is about every 1 ms.

This works very good until all of a sudden the callback is no longer called. This happens when I for example start another application like IE. First I thought that windows ignored some messages because "it had better things to do" but I would be surpriced if windows was allowed to ignore messages like that... so, my second idea is that this is a bug in the NI-DAQ driver? But
shouldnt the driver then display some error-message?

Any ideas are welcome, thanks in advance.

/Thomas
0 Kudos
Message 1 of 3
(2,994 Views)
Thomas,

You are making two mistakes here, in my opinion. First, you are asking WAY too much of Windows. When I used windows for my data acquisition systems, I had a very specific manner of installing and configuring the systems. I used Windows 95 (didn't realize NT was better at the time) with NOTHING installed except solitaire to ease my boredom. No network, no IE, no office, nothing. I stripped windows to the bare bones, and had some success.

Windows is not a good choice for your configuration. To ask Windows to run your program, and do anything else is asking for problems.

So, how do you solve the problem? Simple. Port to another operating system AND/OR reduce the system demand. Trying to ask for 1ms response through that system is asking
WAY too much. I don't know how you are even getting ONE sample set. I would suggest that you verify that you ARE getting all of your samples. Try using a Pulse Generator and generating a set number of pulses equal to a few sample sets. Configure your system for the same number of samples, and run it. If it hangs, that's because you didn't receive all of your samples. My suggestion is to increase the number of scans to something that will give you about 1 second, maybe more, of scans.

-Mike
0 Kudos
Message 2 of 3
(2,994 Views)
Hello,

Well, if you can't demand more determinism than 1 second, Wondows wouldn't be of much use for anything.

My problem is not really the latency, my problem is that the callback is cancelled, nomatter if I have a 1 or 100 ms buffer.

/Thomas
0 Kudos
Message 3 of 3
(2,994 Views)