05-08-2008 07:34 AM
05-08-2008 10:06 AM
05-08-2008 10:28 AM
05-09-2008 09:58 AM
05-09-2008 10:04 AM
So the bottom line is that I can't do change detection accurately, because I can't do change detection and digital filtering on the same DIO lines?
Can someone from NI weigh in on this? How can I do change detection without detecting glitches?
05-09-2008 11:29 AM
05-09-2008 11:56 AM
Hi DRT,
Here are couple of options you might consider to avoid detecting glitches:
05-16-2008 09:58 AM
Well, I tried your suggestion about filtering on Port1 or Port2 instead of Port0, but I got an error message indicating that digital filtering is not supported on those ports. I think that NI needs to thoroughly document which features are supported on which boards, down to the little gotchas like which DIO ports support filtering, which supprt change detection, etc.
I ended up falling back on the old standby that I know works, and that's timer-based polling, not a very elegant solution.
05-19-2008 11:05 AM
Hi DRT,
Just to confirm, you have tried to enable digital filtering on Port 1 or Port 2 and you got the same error message as before? Do you have a 37 pin version of the PCI-6221? I noticed that there is a footnote in the manual (page 6, where it discusses the debounce settings for Port 1 and Port 2) that says that “Port 2 is not available on PCI-6221 (37-pin) devices.”
Please let us know if you can’t enable the digital filtering on Port 1 or Port 2. If this is the case, then we will need to get R&D involved to verify this behavior and correct the documentation. You make a valid point that the documentation should be improved.
Here are a couple of other links I can across:
How Can I Remove Glitches or Bounce on My Digital Line?
Enabling the Digital Filters for Counter/Timer Devices in NI-DAQmxHow Do I Remove Glitches or Add a Debounce Filter to My Digital Signal?
05-19-2008 07:38 PM
Hi DRT,
I must apologize, because I came across some information that may help us make
sense of what is occurring.
Digital filtering is only available on the PFI lines for counter tasks
on M-Series. Check out the PFI Filters section in the M-Series user
manual.
I page 8-4 there is the following note: "NI-DAQmx only supports filters on
counter inputs."
This means that for a digital input/output task NI-DAQmx does not support
digital filtering. I completely agree with you that this important
information should be clearly stated in the specifications for the PCI-6221 and
other M-Series devices. Rest assured I will take the appropriate action
to request that it be fixed. Sorry again for any inconvenience this may
have caused you.
I did come across one possible workaround where a "dummy" counter
task is creating using the PFI line of interest as one of the counter inputs
and enabling filtering on it through the counter options of the DAQmx Channel
Property Node as explained in this knowledge base:
Digital Filtering with M Series and CompactDAQ