Discussion:
How to read digital signal on one of the PFI lines?
(too old to reply)
newbi
2008-07-23 13:40:14 UTC
Permalink
Hi,
 
I have recently acquired NI USB6210 DAQ and using LabView Signal Express version 2.5.0 as part of my project for MSc. I need to use one of the digital inputs as a trigger for my analog signal so that i can view both of them simultaneously. I have Cyan microcontroller board and i am using one of the port pins as the digital signal input to the DAQ. The analog signal is current which i have connected to AI1 line. I have tried using PFI0 as the trigger but i am not able to see both the signals simultaneously. I even tried reading digital signal alone but in both the cases i get error about the Acquisition mode that i cannot use continuous sampling.
 
This is the first time i am using NI instrument and LabView. I read the forum for simialr problems but could not get much clue. Do i need to write any program for this?
 
any help appreciated. thanks in advance
 
 
-newbi
Tom O
2008-07-28 10:40:07 UTC
Permalink
Hi Newbi,I've investigated your hardware and software and have found the root cause of your issue: your hardware does not support timed DIO. Additionally, you can't trigger your digital task. Finally, under SignalExpress, you can't trigger a counter that could be used to sync the two operations together.Using your current hardwareUsing SignalExpress and the 6210, the closest you can get to what you want (as far as I understand) is:- An on-demand software-timed digital input with no triggering
- An hardware-timed analogue input with triggering on PFI0
This would give you the digital data and the analogue data. The latter would be triggered as required. However, the two lines would not necessarily start at the same time and they would not acquire samples at the same time either. If this is suitable for you, I'd recommend you try this.Upgrading for more featuresIf you need both tasks to be triggered, or for each task to acquire data at the exact same time, you need to re-think your hardware and software. The ideal setup in this case would be to use LabVIEW and a more sophisticated M-series DAQ device such as the 6251. In this case, you could:- Set up an continuous, buffered analogue input task with no triggering using a counter internal output
- Set up a continuous, buffered digital input task with no triggering using a counter internal output
- Set up a counter task to output a pulse train. This pulse train would then be used to acquire samples at exactly the same time on your DI and AI tasks.
- Trigger the pulse train on PFI0 - your digital line. This will start the pulse train, which in turn will start your AI and DI tasks. Without a pulse train, the AI and DI do nothing.
In this situation, you can have both your inputs completely synchronised and started on the same trigger.If you'd like any more information on either of these methods, please let me know!Cheers,Message Edited by Tom O on 07-28-2008 05:30 AM
Loading...