Continuous averaging for a certain amount of time

Hi
In my program I have to use a start button to continuously average a value for a certain amount of time(lets say 3s) and keep and show the average the value. The state of the start button should return to off mode after that 3 sec so if the user hit the start button again it reset the array and calculate the average again.
Would you please help me with this program. I have attached pic of what I ahev done
With this vi I can take data after hitting start for 3 sec but I have these problems:
1- I don't know how to calculate average value when finish getting data after 3 sec
2- I would like the start button back to off mode after 3 sec so if I click on the start button again it reset the array and calculate the average again.
Would u plz help me with this vi?
Attachments:
1q.jpg ‏169 KB

Use mean function to average an array. And wire your time has elapsed boolean to a case structure and reinitialise your boolean control to default in the true case.
Create invoke node as below, just in case you dont know.
Beginner? Try LabVIEW Basics
Sharing bits of code? Try Snippets or LAVA Code Capture Tool
Have you tried Quick Drop?, Visit QD Community.

Similar Messages

  • Video content freezes for a certain amount of time on Lion

    After upgrading to Lion, I have noticed that video content freezes (though the voice is heard, but the picture is frozen for some seconds) for a certain amount of
    time when its starts playing (eg youtube videos) on Lion.
    I have observed this on my friends macbook pro also.
    I have a macbook (mid 2010 model)

    Stats Before playing a video
    Stats while playing a video in youtube

  • Do i have to charge my replacement macbook pro batter for a certain amount of time before using the computer?

    do i have to charge my replacement macbook pro batter for a certain amount of time before using the computer?

    First, if you have a Late 2008 or older MacBook Pro, you should calibrate the battery, as the battery for these MacBooks don't come precalibrated > http://support.apple.com/kb/HT1490?viewlocale=en_US&locale=en_US
    Then, the battery should come charged, so use it until the battery percentage is low, and then, charge it. You can use your Mac while your battery is being charged, and your MacBook will stop charging the battery when your battery is full, so you can unplug it at any moment

  • Is there any way to set Firefox to remember history for a certain amount of time rather than all or nothing?

    In previous versions, there was a choice to remember browsing history for a certain number of days, but in the current version the only choices seem to be to remember history or not remember history, with no way to customize in between. I don't want to have to clear my history and cache manually all the time, but I don't want it cleared every time I close my browser, either. Has the customization feature been removed entirely or am I missing something? And if it's been removed entirely, could it please be brought back? It's helpful for people who want their older browsing history to be deleted without deleting the entire history.

    *Expire history by days: https://addons.mozilla.org/en-US/firefox/addon/expire-history-by-days/

  • How to play movie clips for a certain amount of time only

    Hello everyone, I think I have a relatively basic question here but I can't figure it out. I have a movie clip loaded using action script 3 at the start of my animation, I want ito to end at the 120th frame. But I can't use the stop(); command because it will also stop the rest of my animations from the 121st frame onwards. So my problem is, how can I stop the movie clip without stopping the rest of my animations?
    Thank you in advance!

    I don't think I have codes that load the swf, but I've sent you the code that I would like to stop. Thanks!

  • Perform each task for certain amount of time

    Hey,
    The program I'm trying to create is a very linear one and involves performing three different processes after one another, each for a set amount of time.
    I originally tried using case statements and timers to do this, but everything got very messy very quickly. I then looked at sequence structures however have read some bad things about them.
    Could anyone point me in the best direction to achive this?
    Thanks,
    Sam.

    Sam_R, Yamaeda is right. Sometimes things are so simple that you do not need a state machine. But sometimes you end up adding features to your simple little program and it ends up growing out of control. Trust me
    There are a million examples of state machines out there. This makes a million and one. It does not address the part of your question about performing an action for a certain amount of time. I wanted to keep it as simple as possible while also demonstrating programmatically determining the next state and error handling.
    I don't mean to sound condescending with this basic example. But I know there was a time when it seemed like advanced stuff to me. Hopefully someone will find this useful.
    =====================
    LabVIEW 2012
    Attachments:
    State Machine.vi ‏12 KB

  • Youtube videos freeze after a certain amount of time, but audio continues.

    As it says in the title, most Youtube videos freeze after a certain amount of time for me, but the audio continues.
    Happens on Firefox, IE and Chrome

    This happens mostly because of obsolate drivers.
    http://forums.adobe.com/thread/945765?tstart=0

  • How do I get the page to refresh after a certain amount of time so it jumps back to beginning of one page site? Its for an exhibition

    Hi,
    I am in an exhibition space where I need to display my Muse website offline and locally on the desktop. I am looking for a way for the website to refresh after a certain amount of time so it can go back to the beginning of the page. Can someone help? Please!

    You can try the steps mentioned here :
    http://stackoverflow.com/questions/2787679/how-to-reload-page-every-5-second
    http://stackoverflow.com/questions/17886578/refresh-part-of-page-div
    http://crunchify.com/how-to-refresh-div-content-without-reloading-page-using-jquery-and-aj ax/
    Thanks,
    Sanjit

  • How to generate a continuous sine wave for a given amount of time

    I am trying to output a continuous sine wave for a speaker, but I am having difficulty making it continuous rather than looping the signal for a given amount of time, which causes discontinuities. There is a VI in the Labview examples titles Continous Generation, but it produces a square wave. Is there a way to adapt this VI such that the amplitude and frequency can be used as inputs to create a sine wave?

    I found a VI that ships with labview(7.0)called continuous sound output. the output of this is a sine wave or you can change it to whatever you want.
    Sorry cannot help more
    Joe
    Joe.
    "NOTHING IS EVER EASY"

  • Continuing a loop for a set amount of time

    Hi,
    I'm am trying to alter a previously written program have run into a problem.
    The program is set up so that when the input exceeds a set level an output voltage to a buzzer is created; the buzzer continues as long as there is an input.  What I need it to do is to continue this output for a set amount of time.
    I've been searching the forum and found this straight forward solution from adamsjr.
    "The easiest way to do this is to use a two Tick Count functions. The first
    one is outside of a While loop, the second one is inside of the While loop.
    Wire the first one through a tunnel into the While loop, add on the appropriate
    ms (5*1000), wire the sum to one input of a compare function. Wire the
    other input of the compare function to the second Tick Count function. Exit
    the loop when the compare shows the second Tick count value is greater than
    the summed value."
    I've got placed the output subVI into a while loop and followed the above directions and this doesn't seem to work. I'm wondering if I would also have to include the input subVI into the loop or is there another possible solution
    Thanks ahead of time,
    Kristen

    Hi Kristen,
    You have the compare function implemented incorrectly.  You need to make sure that the first terminal of the "Greater than or equal" function connected to the output of the sum, and the second terminal to the tick count in the while loop.  The first terminal corresponds to x parameter and the second terminal is for the y parameter.  So if x is greater than or equal to y, then the loop will need to exit.
    You can see how long a subVI is taking if you put a flat sequence structure within your subVI around the entire subVI code.  The first frame would only have a tick count going into an indicator, the middle frame your normal code, and then the final frame would contain another tick count wired into another indicator.  Then you can subtract the second indicator value from the first and get hold long it took to execute the middle (core) of your code for that subVI.
    I highly suggest using the highlight execution and probes and other debugging techniques such as breakpoints to diagnose where the data is being held up.

  • Click event on a label doesn't work after a certain amount of time?

    I'm having a weird kinda a problem with my label.....I had given a click event on the label but the problem here is that...it won't take any event after a certain amount of time....i mean..it takes the event if you click on it when it is loaded but after sometime it won't take any event...
    And there's one more thing which is that...i've some images too on the page but the images doesn't show up until and unless my mouse gains focus on the page...i.e I've to move my mouse over the page once then only i'm able to see the image...
    Any help on how to solve this problem.....

    The problem is that...the project size is too big and i really don't know where to upload the project.....
    Any help and still thanks for the reply...
    Waiting...

  • How do I insert a pdf file (image) into a project as a picture-in-picture clip that will run for a specified amount of time?

    I want to insert a pdf created from a ppt slide into a FCP X project that will run as a PIP for a specified amount of time. I was successful in bringing the image into the project as a clip but the default for the image is one second. When I try to change duration of the clip, I am able to enter a new time length but the actual clip doesn't change.

    You select the PDF image in the timeline. You use Control-D and enter the new duration. What happens?

  • For Photoshop CC download do I have to pay the £8odd a month forever or for a set amount of time?

    I want to know whether there's a set price to the deal or will I be paying £8odd forever?
    I'd rather buy the full application, then and there, if that is the case. Save Money.
    Is there a set price? Or are you paying it if off monthly for a set amount of time?
    Can't find answers anywhere.
    Thanks In Advance!
    J

    You pay for your Cloud membership as long as you want to use the software.
    When you stop paying the software stops working. You never own the software. There is no set time when you finally pay it off - because it's a subscription model, not a rent-to-own model.
    If you want a pay once, own forever deal then you may be better off getting the superseded CS6
    Creative Suite 6

  • How to execute a frame of a flat sequence structure for a specified amount of time?

    Hello,
    I have a timed loop measuring a resistance value every 2 seconds. I would like to have this timed loop execute for a specified amount of time (e.g. 5 minutes). The timed loop itself is placed within a flat sequence structure so I am concerned that the measurement will be taken once and the next frame will begin to execute, without waiting 2 seconds for a successive reading (and not looping for, say, 5 minutes).
    In other words, is it possible to have a frame of a flat sequence structure execute for a specified amount of time before moving onto the next frame?
    Thanks for your assistance!
    JFK_Aero
    Solved!
    Go to Solution.

    All code in one sequence frame must complete before the next frame can execute.  So as long as your timed loop is setup correctly, the next frame cannot run until your 5 minutes is up (N = 5 minutes/2 seconds/measurement = 150 measurements).
    There are only two ways to tell somebody thanks: Kudos and Marked Solutions
    Unofficial Forum Rules and Guidelines

  • How do i set my ipod touch to automatically turn off after a certain amount of time?

    how do i set my ipod touch to automatically turn off after a certain amount of time?

    Please check "My Music Timer" app.
    "My Music Timer" can stop iPod touch or spotify playing music.
    https://itunes.apple.com/app/id787182095
    Thanks

Maybe you are looking for

  • Single Sign On and Command line

    Hi! We have application without any logon form which executed from command line by BAT file: app.exe Username Password par1 par2 ... where par1, par2... is parameters of application So question is: can Oracle Single Sign On set user credentials to th

  • Using external hard drives for Time Machine backups

    I would like to let everyone know about an important issue regarding what type of media to use, or better said not to use for Time Machine backups. I tried to use a RAID 0 array disks ( FIY: RAID is a storage technology that combines multiple disk dr

  • Can i install a Seagate momentus XT hybrid hard drive in my 2011 27' iMac?

    As title. Heard a lot about the temp sensor that might cause this an issue? If its a problem, would it work if i installed it as a 2nd drive? Thanks

  • Trying to reinstall Lightroom 5 on a new computer

    Purchased Lightroom 5 in 2013. Now trying to install on a new laptop and it says my serial number is invalid contact support. As per above (opps) From the creative cloud all I can download is a 30 day trail.

  • Back button not there

    I don't have a back button to return to the previous page I was on. How do I get one on there?