05-13-2010 02:51 PM
I am using a PCIe-6537 with LabWindows CVI 8.5 and DAQmx 8.9. I have existing code that sends data through Port0_32. This is using an external clock brought in on PFI4. I use DAQmxStartTask and DAQmxStopTask to start and stop the data flow, calling each one once.
I now need to modify the code to send a separate bit of data prior to this still using Port0_32. The data needs to be sent using the internal clock. I have tried to configure my task to use the internal clock, write my data, start the task, stop the task, change the task settings for the existing code to work, start the task again, and then stop the task.
The last (second) DAQmxStopTask call just hangs now. No error codes are presented or anything like that. If I step through the code in CVI, when I step over the DAQmxStopTask call, the program never returns to the debugger and I am forced to terminate the execution.
I did some quick searches and couldn't find any sample code that started and stopped the task, while making modifications between runs.
Any info would be appreciated.
Thanks
Jonathan Rice
Solved! Go to Solution.
05-13-2010
06:10 PM
- last edited on
12-18-2024
10:43 AM
by
Content Cleaner
Hey Jonathan,
This was a known issue in the DAQmx driver version that you are using with the 6537. This issue has been fixed in the NI-DAQmx 9.1 version (and later). You can download and install the latest version of the driver to get around this Stop Task hanging issue.
Regards,
DJ L.
07-30-2010 08:51 PM
We are also having a hang when using the StopTask call. We use PCI 6703 and PCI 6225 cards. We are running using version 9.1.1 of the tools. ... Is there anythin specific that needs to be done when trying to stop a task that we may not know about?
08-02-2010 12:12 PM
Hey Scott,
The issue that Jonathan was seeing was specific to the PCIe/PXIe-6535/36/37's, and the upgrade to the version listed above resolved the issue for these devices. If you are seeing issues at this function, you could try using an older version of the DAQmx driver and see if that also shows the same behavior. Another thing to try with your cards is to run some example programs, that ship with the driver, on your boards, that also use the Stop Task function, and see if the examples also show the same behavior you are seeing with your code. If they don't there might be something going on with your code. If the examples also show the same issue, then please post which example you were able to reproduce the issue with, and someone at NI will try to reproduce the behavior to see what might be going on. The more info you provide about your application and system setup, the better discussion forum users can help out. Let me know if there is any other questions or concerns. Thanks.
Regards,
DJ L.
08-02-2010 12:44 PM
Hi DJ,
That is exactly what we have been doing, we have it isolated (somewhat) to the Analog input function(s) while using a PCI-6225. We have a spare 6225 and are going to
try swapping it out in case there is a hardware failure causing this.(Which we doubt since the Measurement Studio seems to function fine.)
Also, we have a different software system that used the same card for the same purpose, but had used the 8.9 driver set, and does not exhibit this issue, so we are going to downgrade our drivers to those and see what happens (if the hardware swap does not resolve the issue).
Either way, I will post back here with the results.
One of the specific examples we are trying is: C:\Documents and Settings\All Users\Documents\National Instruments\NI-DAQ\Examples\DotNET3.5\Analog In\Measure Voltage\AcqVoltageSamples_IntClk
Basically any one of these Analog Voltage Input examples seems to hang when any of: AbortTask, StopTask or Dispose are called.
We are using Visual Studio 2008 compiler to make the programs.
However, the Measurement Studio (4.6.2) does NOT have a problem terminating after using a Test Panel to acquire a voltage. How is the studio different?
Also, we are investigating using NISpy, but again, we are doing a very basic and simple acquisition... attached is some test code we have been playing with.
Thanks for any help!
-Scott (and team)
08-02-2010 05:17 PM
Update:
1) Changing our hardware to an alternate PCI-6225 card did not solve the issue.
2) We discovered that using On-Demand Mode in the Test Panel worked, Continuous and Finite Mode did NOT work and did the hang thing.
3) Downgrading to 8.9 drivers also did NOT work. Same problem, hang when calling Stop/Abort/Dispose.
-Scott (&team)
08-04-2010 01:33 AM
Update #2:
1) Removing a non-conflicting (at least by Windows hardware manger) card (non-NI video capture card) from the system
allowed the NI Software to work, that is, the Stop/Abort/Dispose API's did not hang any more.
2) Adding the card BACK to the system, but in a DIFFERENT slot, also allowed the NI software to work.
3) Again, there was no conflict indicated, and the IRQ changed for the video capture card, but the memory ranges
did not. One thing of note is that the video memory allocation and the NI-6225 allocations are adjacent.
So... we can move on with our system and try to figure out how to get all of our cards organized and working. But I am
not sure which card(s) are not playing well with each other. Any other users that see this sort of hang should be
aware that even though Windows (XP Pro SP3 in our case) does not show any conflicts... there may still be some
issue(s) somewhere.
I hope this helps clear up any software hangs for people!
-Scott