LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Analog Output signal stops

Solved!
Go to solution

Greetings,

I'm using a DAQ Assistant to output a 0-5V signal. I added a Triangle Pattern to the input of the DAQ Assistant.
The point is that I do 0-5V and then back to 0V. But the problem is that the DAQ Assistant just stops at 1V.
P.s. I have the DAQ Assistant in a For Loop

Thanks in advance

0 Kudos
Message 1 of 11
(3,553 Views)

Can you share your code?  We would be purely guessing otherwise.


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 11
(3,539 Views)

Greetings Innervision,

 

Can you give an update on where you stand with this problem and whether or not you will be needing additional assistance?

There is a reference example that ships with LabVIEW which shows how to output a triangular signal with a DAQmx device. This one should be a good starting point.

 

The name of this example is 'Voltage - Continuous Output.vi'

 

Kind Regards,

Wouter

National Instruments

 

 

0 Kudos
Message 3 of 11
(3,510 Views)

I'm still having the same issues. Not quite sure how to solve it. Maybe it's a hardware issue with the DAQ Assistant?
I've added an image of the block diagram.

0 Kudos
Message 4 of 11
(3,488 Views)

Hello Innervision,

 

Can you share the VI with us?

Without it it's impossible to see what you have configured inside the DAQ Assistant?

This will allow us to test (and resolve) your issue in an efficient way.

 

Kind Regards,
Thierry C - CLA, CTA - Senior R&D Engineer (Former Support Engineer) - National Instruments
If someone helped you, let them know. Mark as solved and/or give a kudo. 😉
0 Kudos
Message 5 of 11
(3,479 Views)

I've added the program with this post 🙂

0 Kudos
Message 6 of 11
(3,474 Views)

Hello Innervision,

 

Thanks for sharing the code!

This already helps me understand what is going wrong.

 

The only I don't completely see (based on your code and explanation) is what you actually want your code to do.

 

The things I need to know are:

- What do you want to do when you press start? (My guess: start the outputting)

What should happen when you press it a second time? (My guess: Start again with outputting)

- What should happen when you press the stop button? (My Guess: Stop the complete application)

- What is the exact goal of the while loop? (My guess: continuously show the evolution of your measurement signals)

- What should happen when you press the report button? (My guess [based on your code]: Output the last 60 samples that were added)
This seems unusual so this guess can be wrong.

- Do you want your code to keep on running after you press on the report button? (for example: do you want to be able to start a new Voltage Output?)

 

Thanks for your feedback!

 

Kind Regards,
Thierry C - CLA, CTA - Senior R&D Engineer (Former Support Engineer) - National Instruments
If someone helped you, let them know. Mark as solved and/or give a kudo. 😉
Message 7 of 11
(3,442 Views)

Thanks for helping me out!
I want the program to start outputting the triangular signal while also starting the acquisition of data. The start doesn't have to be pressed twice.

The "Stop" button is there in case of emergency, making the voltage 0V.
You are right about the while loop for the evolution of the measurement signal, the program suggested that I'd do this so I did this.
I'm just maybe struggling with the loops, it could be simpler maybe..
The report button ends the data acquisition and also prompts for the logfile to be saved. I think there should be an easier solution, I just want all the acquisitioned data to be saved to a .tdms file when the triangular pattern has finished.

Normally it should only run once, so it should not be able to start again without pressing the "Abort" button.

0 Kudos
Message 8 of 11
(3,431 Views)

Hello Innervision.

 

Just to recapitulate what you're saying:

- "Start" Button is only pressed once and starts the application

- "Stop" button is an emergency stop for the application (for acquisition and generation?) which will also make sure the outputted value is set to 0V.
No saving of data happens in this case?

- "Report" button ends the acquisition (and also the generation?) and saves all the acquired data.

Does it stop also your application?

- What should happen when your triangle has been generated completely?

Should your acquisition also stop or should it keep on running?

 

Do you use the abort button (the big red circle in the Front Panel Toolbar) to stop your application?

This is something you should absolutely try to not do.

It's always better to stop an application with application logic.

 

PS: Sorry for all the bold sentences, but this makes it easier to distinguish my questions towards you.

 

Kind Regards,
Thierry C - CLA, CTA - Senior R&D Engineer (Former Support Engineer) - National Instruments
If someone helped you, let them know. Mark as solved and/or give a kudo. 😉
0 Kudos
Message 9 of 11
(3,414 Views)

I'll just just answer like this 🙂

- "Start" Button is only pressed once and starts the application
Yes

- "Stop" button is an emergency stop for the application (for acquisition and generation?) which will also make sure the outputted value is set to 0V.
No saving of data happens in this case?
Yes

- "Report" button ends the acquisition (and also the generation?) and saves all the acquired data.

Does it stop also your application?

- What should happen when your triangle has been generated completely?

Should your acquisition also stop or should it keep on running?
I used the Report button so I could start the prompt and save the data. But I actually want the data to be automatically saved when the triangle reaches 0V,

Do you use the abort button (the big red circle in the Front Panel Toolbar) to stop your application?

This is something you should absolutely try to not do.

It's always better to stop an application with application logic.
The program should be able to stop with the "Stop" button. Which makes the outputted value 0V. Then when the user wants to use the program again.
The Start and Stop buttons should be in default position, so they can start again.


I have all these ideas but just can't implement them in the program.. 😕

0 Kudos
Message 10 of 11
(3,402 Views)