LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

logging from digital output

I'm having trouble logging or recording the information that's being produced by the digital output I have in a for loop. I tried implementing the logging from DAQmx into the loop and I was getting an error about the number of channels not matching the number of lines. I don't know if this is what I need to use or not because I'm wondering if the log does save the output, will it rewrite the file everytime the loop runs? That wouldn't be helpful. What I need is that the information for the several channels that we have will display the digital waveform of the output. I'm attaching the code we currently have and the one I tried implementing with the log, which got an error.

Download All
0 Kudos
Message 1 of 4
(2,171 Views)

In your "log" screen shot,  I see 3 lines being defined but an array size of 2 going into the write.  This will cause your error.

 

You should use Configure Logging before you even start the task.  Plus, I'm not sure it will work with digital outputs.


GCentral
There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
0 Kudos
Message 2 of 4
(2,159 Views)

If you select open or create under operation it should open or create a file (if it does not exist) and will append to that file. For the number of channles not matching can you turn on highlight execution and see where the error is generated from? if its from the DAQmx Create digital channel then try to flatten an array of physicals using DAQmx flatten string channle and pluging in a string into lines. might be getting that error because you are not addressing the entire port but rather components of it.

0 Kudos
Message 3 of 4
(2,153 Views)

thank you,

 

what I am trying to achieve is getting a file or graph that I can save and that will give me the digital waveform of the output.

0 Kudos
Message 4 of 4
(2,149 Views)