Discussion:
Digital Input (Harware Timed Single Point)
(too old to reply)
turkey
2006-09-18 18:40:18 UTC
Permalink
I am using PCI6527 digital I/O card to get inputs from optic sensors and control other devices. I have designed the software below that senses if anything passes in fornt of sensors. That works very well but when I hit the stop button to stop the task and loop, it takes no action before timeout occurs on Daqmx Read.vi. I want to interrupt this task while it is waiting for any signal and doesn't finished its job yet. If there isn't any software solution for this problem, I should use one output line of the card to trigger it programmatically.
<img src="Loading Image...">
Thanks lot..
Laura F.
2006-09-19 21:40:09 UTC
Permalink
Hello turkey,
Once the DAQmx Read VI is called, it has to return the number of samples that are requested, and if they are not received a timeout error will occur as you have noticed.&nbsp; Since it seems that changes are not occurring after the stop button has been pressed, you will always see this error.&nbsp; As you mentioned, you can use another digital line to create a change so that the timeout error does not occur.&nbsp; In addition, you could use a shorter timeout value than the default 10 seconds (if this will work with your application) so the loop stops faster and then programmatically clear this particular error.
Let us know if you have additional questions.
Regards,Laura&nbsp;&nbsp;&nbsp;
turkey
2006-09-20 10:40:11 UTC
Permalink
It is important to me if there is someone thinks like me. As you said probable solutions are to shorten timeout duration or trigger it using one of output ports. I prefer to use second solution first of all. Because this is part of a vision project and cycle times of loops&nbsp;are&nbsp;very important.
Thank you very much...

Continue reading on narkive:
Search results for 'Digital Input (Harware Timed Single Point)' (Questions and Answers)
6
replies
briefly about Os?
started 2006-11-29 01:29:52 UTC
computer networking
Loading...