11-13-2014 07:56 AM
Good evening everyone!
Our group is uing NI 9227 to get current from our circuit. But from the two indicators in front panel, as both of our two switches open, one can display current while another just shows 0.00....
But when I run circuit 2 independently in a new VI, it can display current normally...
Could anyone tell me why and how can I solve this problem??
Thanks so lot!!!
11-13-2014 08:21 AM
You could start by showing us your code. Impossibly to troubleshoot otherwise.
11-13-2014 08:25 AM
Here is our VI.
Sorry it's so massy....
11-14-2014 01:27 AM
does anyone can help???
thank you all!!!
11-14-2014 12:07 PM
@AmeHyesung wrote:
does anyone can help???
thank you all!!!
The VI you posted is quite messy and plenty of places for improvement but I am not convinced that this is the source of the problem. Why are you setting up your DAQ Assistance to be continuous sampling at 100 samples at 100Hz, but then you convert from the DDT to a single sample? If you really want a single sample then take a single sample. I'd also suggest not using the DAQ assistant because it can hide issues like this by using DDT. Still this should prevent you from seeing the right data.
It looks like you have current going into AI0 and AI3 of your device, are you sure this wiring is correct?
With a DMM can you confirm the correct readings going into the DAQ card?
Also you mention running a separate VI and having it work. I don't know how this is possible because one program will lock the current measuring device and not allow that resource to be used anywhere else. You should be generating errors. Which a simple error handler should show you. You should probably add that after the while loop stops.
Unofficial Forum Rules and Guidelines
Get going with G! - LabVIEW Wiki.
16 Part Blog on Automotive CAN bus. - Hooovahh - LabVIEW Overlord