Why can't I run this faster?

So let me start off by saying I have very little LabVIEW experience, and this code is the result of me playing around on my own for the last couple months. I haven't had any actual training so my understanding has been gained mostly through trial and error. That said, it's very possible I'm missing some understanding of key features that might easily solve my problem...
Anyway, here's the issue: I've coded a simple on-off, ramp/soak controller to power two small heaters. Right now it works but is very slow. What I mean by slow is that the code inside my loop takes around 1.8 seconds to run. What that means is if I set the sampling time to under 1.8s, the loop doesn't run at consistent increments, as some times it has to wait for two multiples of 1.8 to pass instead of just one. 
Does anyone see any obvious ways to speed this up? With the sampling time so high I get a lot of overshoot and waviness in my temperature response..
Any help would be greatly appreciated!
More details incase they're helpful:
Thermocouple Input DAQ Assistant - Takes in 3 thermocouple values from an NI 9213, acquisition mode set to On Demand
Digital Output DAQ Assistant - Outputs a Digital Line Output to the heaters via an NI 9472, generation mode set to On Demand
DAQ Assistant outside of the loop - Just there to make sure the heaters are turned off once the profile is complete
Attachments:
On-Off Controller.PNG ‏46 KB
On-Off Controller Front Panel.PNG ‏40 KB

I'm wondering if it is the DAQ Express VI that is slowing you down.  Afterall, it has to setup and close the DAQ task each time it is called.  Use the actual DAQmx API to setup the read and writes.  I made some edits.  See if this helps any.
There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
Attachments:
Simple Ramp-Soak On-Off Controller.zip ‏86 KB

Similar Messages

  • WHy Can't I Run This?

    import java.util.Random;
    import java.io.*;
    public class RollDie
    public static void main(String args[])
    Random randomNumbers = new Random(); //random number generator
    int frequency[] = new int[ 7 ];//array of frequency counters
    //roll die 36000 times; use die value as frequency index
    for ( int roll = 1; roll <= 6000; roll++ )
    ++frequency[ 1 + randomNumbers.nextInt( 6 ) ];
    System.out.printf( "%s%10s\n", "Face", "Frequency" );
    //output each array element's value
    for ( int face = 1; face < frequency.length; face++ )
    System.out.printf( "%4d%10d\n", face, frequency[ face ] );
    }//end main
    }//end calss RollDie

    javac -version gives me an error:
    C:\Documents and Settings\libni>javac -version
    javac: invalid flag: -version
    Usage: javac <options> <source files>
    where possible options include:
    -g Generate all debugging info
    -g:none Generate no debugging info
    -g:{lines,vars,source} Generate only some debugging info
    -nowarn Generate no warnings
    -verbose Output messages about what the compiler is doing
    -deprecation Output source locations where deprecated APIs are used
    -classpath <path> Specify where to find user class files
    -sourcepath <path> Specify where to find input source files
    -bootclasspath <path> Override location of bootstrap class files
    -extdirs <dirs> Override location of installed extensions
    -d <directory> Specify where to place generated class files
    -encoding <encoding> Specify character encoding used by source files
    -source <release> Provide source compatibility with specified release
    -target <release> Generate class files for specific VM version
    -help Print a synopsis of standard options
    The IDEs I'm using are BlueJ and Forte for Jave 4. I get the same erros on both.

  • Why?  Why can't I run iMovie and have it

    Why? Why can't I run iMovie and have it ask me whether I want to load an existing project or new one? I don't see a setting for this in Preferences.
    thanks

    I haven't gone to the trouble of actually testing to see which uses more CPU power, but Firefox has been faster than Safari on every Mac I've ever owned.
    To see CPU usage by process, open the terminal (in Utilities) and enter 'top' at the command line. You might have to expand the window as processes don't appear in any logical order.
    It could also be hardware-related: I have late 2009 mini with similar specs and it pinwheels easily.

  • Why can't I run my Java program with just the JRE, the JDK is required?

    I've recently written 3 programs in Java using the Netbeans IDE with JDK 1.6 as the default Java platform. The compile-time libraries include the Swing Application Framework. I use BuildDesk from ProductiveMe to package the each program into a Windows installer.
    When I install the programs on a new computer without a JRE or JDK being present, and attempt to run them I get an error (as expected) stating that there is no JVM. The messages says that I need to install JDK 1.3 or higher. I downloaded the latest JRE onto the new computer and attempted to run the programs and I get the same error message. My question is, why can't I run these programs with just the JRE installed? Why do I need the JDK? When I install the JDK, the programs run fine. The typical user may not have the JDK on their system, but they likely have the JRE if they've run Java programs before.
    Is the answer as simple as there must be library functions being used by the programs that belong to the JDK, but not the JRE? I'd rather a user not have to install the JDK verses the JRE because they may also have to update some Windows environment variables.
    Thank you for any help on this issue.

    915088 wrote:
    Thanks for your replies. I further investigated BuildDesk and found an option which allows a JVM check but that check needs the JDK. I stopped the JVM check and rebuilt using BuildDesk and it now only requires the JRE to run the programs. The reason why I use BuildDesk is to package more than just the jar file for the user. BuildDesk allows me to create a installation folder structure as well as include any other files in the build. I could just as well zipped all this together for the user but decided against that method.I don't think anyone will question your usage of an installer tool; that is entirely up to you. But what is questionable is that you have problems with that installer tool and then go look for help in a Java programming forum. The next time, go look for help at the source. If there is no way to acquire help (support, a forum, a mailinglist, anything) then that is a very good reason to not use the product in question.

  • Why can't i run itunes on my windows 8?, why can't i run itunes on my windows 8?

    why can't i run itunes on my windows 8 laptop..?

    Hi sincerelystef,
    If you are having issues installing iTunes on your Windows machine, you may find the following article helpful:
    Apple Support: Trouble installing iTunes or QuickTime for Windows
    http://support.apple.com/kb/HT1926
    Regards,
    - Brenden

  • I am unable to apply my downloaded update. When I try to apply it and restart firefox, it still says 'apply downloaded update now...'. Why can't I apply this update and what do I do about it?

    I am unable to apply my downloaded update. When I try to apply it and restart firefox, it still says 'apply downloaded update now...'. Why can't I apply this update and what do I do about it?

    Checked out that link and everything seems to be in order on this machine at this time.
    I only have CC installed on this one machine, not even my secondary machine like is permitted. it seems odd that I'm asked to re-accept the Licence Agreement as often as I am. If I had to guess, it's almost every week, if not multiple times some weeks, that all the software will decide I should have to view the licence agreement.
    Edit: I've never had any noticeable "errors" activating or anything like that. I just get asked to do it quite frequently.
    This activation screen isn't too annoying (it involves clicking one single button), but like I stated earlier, if I'm trying to launch the software by double-clicking on a PSD, AI, PPROJ, AEP, etc... that file will fail to open.
    I feel like that's probably not really a bug, but it is frustrating, since I did launch the application with the intent to edit that specific file I tried to open.
    Again, something that you guys may consider working on.
    Another annoyance is that: agreeing to the licence agreement is a per-application task, so if I see that Licence Agreement dialogue window by opening Photoshop (for example), I know that every other piece of software I have in the suite (Illustrator, Premiere, After Effects, Audition) will be showing me that screen on it's next launch. Probably deliberate for legal purposes that I can't just agree once for the whole suite, but heck, it would save me a lot of minor headaches if it was a unified agreement.

  • I want to change my primary email address, and use one already associated with my account why can I not do this ?, I want to change my primary email address, and use one already associated with my account why can I not do this ?

    I want to change my primary email address, and use one already associated with my account why can I not do this ?, I want to change my primary email address, and use one already associated with my account why can I not do this ?  I don't want to create another one if I really don't need to
    Any ideas ?

    I'm afraid that once an address has been associated with an Apple ID you can't re-use it in any way. You will have to create another address (such as a free on from GMail or Yahoo for example).

  • As of late i have been unable to run fwd email u tube videos my mac tells me i need adobe flash got it still neg = and now my bakn statement is in pdf and mac tells me i need adobe reader got still neg why can't i run these things on safari?

    As of late I am unable to run forwarded videos ie utube ect on safari- my MAC tells me I need adobe flash- got it still neg - now my bank statement is in PDF format and my MACtells me I need adobe reader - got it still neg  WHY CAN'T I RUN THESE THINGS ON SAFARI???

    Hi...
    For videos. Uninstall the current Flash plugin then reinstall new >  Troubleshoot Flash Player | Mac OS
    Quit then relaunch Safari. From the Safari menu bar click Safari > Empty Cache
    Try a video.
    All online bank statments are in PDF format.
    Go to  /Library/Internet Plug-Ins
    Move the Adobe PDF Browser plugin  (or just PDF Browser plugin) to the Trash.
    Now try a bank statement.

  • Why can't I run the new upgrade? All I get is that I am not connected to the internet, even though I am connected???

    Why can't I run the new upgrade? All I get is that I am not connected to the internet, even though I am connected???

    If you haven't, try updating through iTunes while connected to your syncing PC.

  • Whenever I modify a photo in Iphoto it puts it in a "modified" subfolder. Why can't I move this modified file (I changed name) back to the Iphoto main file so I can see it when I open my photos?

    Whenever I modify a photo in Iphoto it puts it in a "modified" subfolder. Why can't I move this modified file (I changed and saved file name) back to the Iphoto main file so I can see it when I open my photos?

    A good general step for strange issues is to renew the iPhoto preference file - quit iPhoto and go to "your user name" ==> library ==> preferences ==> com.apple.iPhoto.plist and trash it - launch iPhoto which creates a fresh new default preference file and reset any personal preferences you have changed and if you have moved the iPhoto library repoint to it. This may help
    This does not affect your photos or any database information (keywords, faces, places, ratings, etc) in any way - they are stored in the iPhoto library - the iPhoto preference file simply controls how iPhoto works - which is why renewing it is a good first step.
    If that does not cure it backup up your iPhoto library and rebuild it - depress the option and command keys and launch iphoto and use the options there - exact option depends on teh version you have
    And always remember - NEVER make any changes of any sort to the structure or content of the iPhoto library - nothing - no deletions - no name changes - nothing
    LN 

  • Why can't I run quicktime videos on ipad2?

    why can't I run quicktime videos on ipad2?

    Eric-
    QuickTime is capable of playing more video formats than the iPad.  The iPad can play M4V, MP4 and some MOV format videos.  It can not play formats like WMV and FLV.
    One thing you can do is to convert the video formats on your computer. 
    A free program that can do it is HandBrake, which is available for both PC and Macintosh at <Download>.
    Fred

  • Why can't I run powerpc applications?

    why can't i run powerpc applications?

    Thank you Thomas!
    fishellnb wrote:
    do you know of any workarounds... ?
    Installing Snow Leopard (with Rosetta) into Parallels 7 in Lion:
                             [click on images to enlarge]
    And on Mountain Lion:
    Full Snow Leopard installation instructions here:
    http://forums.macrumors.com/showthread.php?t=1365439

  • HT1528 Why can't I bookmark this page like I can with support.discussions pages?

    Why can't I bookmark this page like I can with support.discussions pages?

    Hi UI Guy,
    I can't provide the technical reason, however, I'm farilry certain it is a function of Forum structure itself.
    Don't know if you are interested in suggestions to meet your need to "bookmark pages within the Apple Support system so you can refer back to them easily", but I use them regularly, and do this one of two ways (I use both):
    If it is strictly an Apple Support page that I retrieved from Apple, I bookmark it with clear easy to find names, and put them in my Apple Support Folder in my bookmarks (I use Firefox). That way, when I need to provide a link to someone I'm replying to, I can quickly find the item I want them to be able to link to.
    I also bookmark discussions that have links in them that I may want to use, and tag them so I can find them later.
    I have to say, however, that for Apple Support Pages, the best solution for me has been to have my Apple Folder with my personally named bookmarks in Firefox. Easy to find, easy to cut and paste into a discussion on a separate window, easy to reference when I need to know something.
    Again, don't know if you even wanted to know any of that, but thought I'd share!
    Cheers,
    GB

  • A Playlist idiot. Why can't I get this to work?

    In iTunes I have music Playlists set to shuffle (blue double arrow button) and audio books Playlist set no shuffle. I have been unable to get my iPod to follow these settings. A suggested work around is to use the iPod Settings to set the shuffle function to "songs" when playing music and then switching to “off’ for audio books. There has to be a better way. How do I set the Playlists on my iPod to function the same as it does on iTunes?

    LeftyLucy,
    Using your process are you able to set your iPod to shuffle then listen to the audio book without it shuffling the chapters? I have tried your suggestion with the iPod setting set to shuffle and the chapters shuffled. This is the issue from my original post. I want to listen to music with the shuffle function and listen to audio books (no shuffle) without having to change the settings every time I switch.
    Keep in mind that is not a purchased audio nor a imported book.
    Using a tip from the following post:
    Tom Graves, "A Playlist idiot. Why can't I get this to work?" #11, 05:26pm Sep 28, 2005 CDT
    I have attempted to make the audio book file into an authenticate file but that did not help.

  • Why Can't Creative do thi

    Why can't Creative do this with the headphone jack problem?
    http://www.sony.co.uk/PageView.do?si...=en_GB_Support

    Do we need another thread on this? It could be that Sony's problem is a very serious fault like a fire hazard with the battery or something.

Maybe you are looking for