07-07-2010 10:45 AM
I want to read digital signals from my DAQ and display whether each channel is on/off on the front panel
07-07-2010 10:57 AM
Aeastat,
Again thanks for all the help, i really appreciate you taking the time to go through all of these steps with me. When they are there in the program i don't have any probs with understanding whats going on - it's just getting them into the program i have trouble with! , but these step by step ........steps are really helping me to see how to go about modifying and writing programs etc.
again thanks,
Chris
07-07-2010 12:05 PM
No problem that is what I want. I want you to see how it can be done and be able to understand so you can do it the next time. Also when you have gotten to be a pro at it you come back and pass it on to someone else. That is what this fourm is all about.
07-07-2010 12:10 PM
@CClear87 wrote:
I want to read digital signals from my DAQ and display whether each channel is on/off on the front panel
You will need digital output to read this. So you will have to edit the daqmx create virtual channel vi so it is a digital output.
Do you know the difference for an input and output? If you want the device to tell you a state then it would be an output. If you are trying to set the channel state then it would be an input.
07-07-2010 04:03 PM
Is there a reason that you are using MS word for your reports? I think it would be easier to send everythin to a text file such as .txt or .csv We could do this very easily with the write to spread sheet file.
07-08-2010 07:20 AM
Ahh i didn't realise that about input/output ( a bit confusing - i thought input collected data and output sent signals out).
There is a requirement to use Word, as i am trying to put as much automation into the system as possible. And having someone process the data after it has been collected is a step backwards.
Good news though, there is now only one test_number AI, a global one for the whole test cycle. The programming of the tester has been altered so that it queues the packs, before moving on.
I've had a go at trying to make the digital inputs (or outputs whatever they are) work with the test_number analog channel, in order to display pass/fails on the word report. (See the VI below) My idea is to get the while loop surrounding the digital read to iterate every time the value of the test_number input changes by 100mV. Therefore the digital channel is only read when the test changes.
Then i tried to use a case structure to record on which test the digital channel registered a fail, but i'm not sure if a loop is needed here or how to append the values to an array.
Chris
07-08-2010 07:30 AM
I would use events to tell the digital loop to take data. We would also need to change the digital loop to read only when it gets this signal. I will look at your code and see what I can do to help here.
07-08-2010 07:32 AM
Do you have the digital setup file. I can take a look at that and see what you have going on there.
07-08-2010 07:33 AM
here you go
Thanks
07-08-2010 07:47 AM
Do you need to see all of the digital channels to know if there was a failure or do you just need to know if one failed?