03-26-2025 02:11 AM
Hello everyone,
I am trying to execute analog write function where the input value is time bound. The value changes sequentially with time, tried using flat sequence structure for timing but I am stuck at a point where I don't know how to connect various inputs to daqmx write block. Can anyone help me with the logic.
03-26-2025 02:37 AM
Hi sivac,
@sivac wrote:
tried using flat sequence structure for timing but I am stuck
How should a sequence structure help with timing???
Why don't you show your code?
Why don't you use a loop?
What are your timing requirements?
03-26-2025 03:24 AM
Here is my code, I want to give one input at a time to the block
03-26-2025 03:31 AM - edited 03-26-2025 03:32 AM
Hi sivac,
@sivac wrote:
Here is my code, I want to give one input at a time to the block
This is just an image of (broken) code. There is a difference between "code" and "image of code"…
With those timing requirements I recommend to use a simple state machine - or even simpler a FOR loop auto-indexing an array of output values!
What's the purpose of the DAQmxStop/Clear function when your loop NEVER stops??? (Don't get me wrong: I don't recommend loops running endlessly.)
I recommend to learn THINK DATAFLOW! (There is a chapter on DATAFLOW in the LabVIEW help…)
03-26-2025 04:37 AM
Hey GerdW,
Thanks for your response. I started using Labview recently. I will try to implement state machine for my application. Thankyou