Set up time for ni 6501 to control relay

Hi,all
I have made great progresses with your help. Right now I know how to control the relay using NI 6501.
Furthermore,  I try to set up a time period (after 2 hours) and then let NI 6501 switch on the relay.
What kind of example can I refer to?
Another control is when pressure data is low to 1mtorr, then switch on relay.
If there are some similar examples I can refer to, it will be helpful for me programming
Thanks
Solved!
Go to Solution.

Here is an example of how to control your valves:
This example is not ideal.  For example, the Write to Spreadsheet File is called each loop iteration just to write only one value.  This is a waste.  It would be better to collect all your data into an array (use a wire to loop edge with indexing on), and call the Write function once with an entire array of data.  I will leave it up to you to do this.  You could use the practice.  Another thing is that a lot of local variables are used.  Also not ideal.
Also, a state machine architecture would serve this purpose much better.  First state would be similar to the first sequence frame.  Second state would be like the while loop.  And so on...  See if you can implement this code in a state machine.  One advantage would be to control each stage of the code in an orderly manner.  Another advantage would come if you ever had to change the order of execution, or insert code in between states.  Just add a new state and/or change the next state pointer.  Local variables can be replaced by shift registers in a state machine, leading to the code being easier to read.  See if you can do this.
- tbob
Inventor of the WORM Global

Similar Messages

  • Can I set a time for music in iTunes to stop

    I use an iPad to play my music to an Airplay speaker. I sometimes use the playlist on my iPad and if I want to increase my listening pleasure I would use Remote to play from my entire libray on the iMac.
    I've looked but can't seem to find any way of setting a timer for playback. I listen to music at night and rather than have it play the entire night. Dose anyone know of a a utility/app for atimer setting in iTunes?
    I believe Apple sould consider this feature for a future addition to iTunes.
    Thanks,
    HJKeats

    It is not yet a built-in feature, but there are quite a few sleep timers around.
    For example:
    http://en.softonic.com/s/sleep-timer:mac
    I have not tried them, however

  • I like to watch tvcatchup or sky go or I player on my iPad while falling asleep, the problem is that the iPad then stays on all night. I would like to find an app that allows me to set a timer for the iPad to switch itself off automatically.

    I like to watch tvcatchup or sky go or I player on my iPad while falling asleep, the problem is that the iPad then stays on all night. I would like to find an app that allows me to set a timer for the iPad to switch itself off automatically, like the sleeper function on a TV.
    Does such an app exist? Can anyone help me? Thanks

    You can try the Sleep Timer.
    https://itunes.apple.com/sg/app/music-sleep-timer/id320583424?mt=8

  • How do you set the time for this forum??? Not in nerd pleas

    how do you set the time for this forum?

    There were problems with the correct time display for postings, and based on another recent post this doesn't seem to have been fixed. My advice... don't worry about it.

  • Will my mac back up to time machine wile it is on but shut (asleep) and can you set a time for backups???

    will my mac back up to time machine wile it is on but shut (asleep) and can you set a time for backups???

    If your Mac Model supports POWERNAP under Mountain Lion, yes backups and software updates can occur while the mac is taking a power nap (kind of light sleep).

  • Insert multiple images in one slide and setting dsiplay time for each

    Hi,
    I am using Adobe Captivate4.
    I could not able to insert multiple images in one slide and set display time for each image.
    Need help in this regard.

    This is not about background image.
    I have 3 images and want to insert in one slide only. I could able to insert image1 for first time, but could not able to insert image2 and image3.
    I have followed the same steps: Insert Menu>Image.

  • How to set expiry time for cached Subjects of authenticated proxy service.

    How to set expiry time for cached Subjects of authenticated proxy service in message level authentication.
    Because of this, password change does not effect immediatly in proxy invocation.
    I'm using Weblogic 10.3 and OSB3.0

    Hi,
    You can activate Time-Dependent Publishing Service on your XML form and once the Lifetime of Documents is over then the document is not visible to users.
    http://help.sap.com/saphelp_nw2004s/helpdata/en/c1/c87d3cf8ff3934e10000000a11405a/frameset.htm
    It is only invisible but not deleted!
    So to delete all expired XML Forms you should run Scheduler Tasks for Time-Dependent Publishing:
    <b>TimeBasePublishingUnpublish</b>
    http://help.sap.com/saphelp_nw2004s/helpdata/en/3a/bc37b5789dee4eaa8005bff84f14cf/frameset.htm
    You can also create your own Scheduler Task which deletes/archieves all expired XML Forms.
    Greetings,
    Praveen Gudapati
    [Points are welcome for helpful answers]

  • 39L4363D - Unable to set padding time for recording start and end time

    Hello,
    I have a problem with my 39L4363DG tv (Software 7.1.90.34.01.1).
    I'm not able the set padding time for recording start and/or end time as described in the [manual|http://www.toshiba-om.net/LCD/PDF/English/L4363-323950-English.pdf] on page 51. Both menu item "start padding time" and "end padding time" are disabled?
    Can anyone help me and give me an advice on how to solve it?

    Hi
    The padding time can be set for programmed recording.
    There is also an scheduling priority
    If scheduled time slots are next to each other and there is more than one minute between the end time of the first schedule and the start time of the next schedule, programmed recording will be performed correctly.
    When +Start Padding Time+ and +End Padding Time+ are set, the start time and end time will be the time plus the additional minutes.
    If scheduling times overlap, priority will be given to the programmed recording which starts first.
    When the programmed recording that started first ends, recording will switch to the next scheduled programme.
    At this time, depending on how far the scheduling times overlap, the beginning section of the next scheduled programme may not be recorded.

  • Setting Idle Time for a session..

    Hi,
    Can you please help in setting idle time for a session using jsp.
    Thanks,
    Srini.

    How to set the timeoutsecs for a session. We can set this parameter in weblogic.properties file. This is constant for all the users. But I want to give the sessionouttime depending on user. Please help me regarding this.

  • Using set until time for duplicate is extremely slow

    Whenever I do a duplicate using the set until time it takes forever to get started. The executing command: SET until clause takes about 20 minutes, and then when allocating channels it takes about 10 minutes per channel. Both db's are 10.2.0.3, and in archivelog mode. When I do just a plain duplicate database it runs through just fine, no pauses or anything. Can someone please poing me in the right direction or shed some light on this issue for me?
    Thanks!

    Hi,
    Here is what happens when I kick off the duplicate command with the run block:
    RMAN> run {
    2> set until time "to_date('Mar 14 2009 06:00:00','Mon DD YYYY HH24:MI:SS')";
    3> duplicate target database to DEST;
    4> }
    executing command: SET until clause
    using target database control file instead of recovery catalog
    Starting Duplicate Db at 17-MAR-09
    allocated channel: ORA_AUX_DISK_1
    channel ORA_AUX_DISK_1: sid=3985 devtype=DISK
    allocated channel: ORA_AUX_DISK_2
    channel ORA_AUX_DISK_2: sid=3984 devtype=DISK
    allocated channel: ORA_AUX_DISK_3
    channel ORA_AUX_DISK_3: sid=3983 devtype=DISK
    allocated channel: ORA_AUX_DISK_4
    channel ORA_AUX_DISK_4: sid=3982 devtype=DISK
    allocated channel: ORA_AUX_DISK_5
    channel ORA_AUX_DISK_5: sid=3981 devtype=DISK
    It takes anywhere from 15 to 20 minutes to allocate each channel, then it proceeds with the restoring of datafiles from the last backup. After that is done then it switches all the files, then it does this to start the recovery of the archive logs:
    contents of Memory Script:
    set until time "to_date('Mar 14 2009 06:00:00','Mon DD YYYY HH24:MI:SS')";
    recover
    clone database
    delete archivelog
    executing Memory Script
    executing command: SET until clause
    Starting recover at 17-MAR-09
    allocated channel: ORA_AUX_DISK_1
    channel ORA_AUX_DISK_1: sid=3981 devtype=DISK
    allocated channel: ORA_AUX_DISK_2
    channel ORA_AUX_DISK_2: sid=3982 devtype=DISK
    allocated channel: ORA_AUX_DISK_3
    channel ORA_AUX_DISK_3: sid=3983 devtype=DISK
    allocated channel: ORA_AUX_DISK_4
    channel ORA_AUX_DISK_4: sid=3984 devtype=DISK
    allocated channel: ORA_AUX_DISK_5
    channel ORA_AUX_DISK_5: sid=3977 devtype=DISK
    again it takes about 15 to 20 minutes to allocate each channel.

  • Setting default times for events in ical.

    When setting an event in ICal on my Mac (Im using Lion 10.7.5) if I double click to start an event, it places an event on the day I clicked on.  Im in the month view.  When I go into the event to set the time, the default is 10 am to 6 pm and I have to reset it to an hour long event.  I do know that if I type in the time at the end of the event name, eg. Meet Mary 7 pm, the event will have an hour long duration in the calendar.  Is there a way to change the default for my first method of clicking to create a new event by double clicking in the day square for the event?  Thanks.

    Hi BumbleBBB,
    The article below will explain the parameters for adding events to the Calendar:
    iCal 5.x: Add events to a calendar
    Enter a name, date, and time duration for the event, and then press Return. For example, you can enter “Super Bowl Party Feb 6,” “Movie with Rebecca on Friday at 7pm,” “Soccer Game on Saturday from 11am-1pm,” or “Breakfast with Jon,” and then press Return.
    If you don’t enter a time duration for the event, iCal sets the event’s duration to 1 hour.
    If you don’t enter any time information for the event, iCal makes the event an all-day event.
    If you enter “breakfast” or “morning,” iCal sets the event to start at 9 a.m.
    If you enter “lunch “ or “noon,” iCal sets the event to start at 12 p.m.
    If you enter “dinner” or “night,” iCal sets the event to start at 8 p.m.
    I hope this information helps ...
    - Judy

  • Set sleep time for multiple hard drives

    I have 2 internal hard drives on my mac, one SSD boot drive and an HDD for media.
    I would like to have the HDD go to sleep when it is not in use (i.e. when I am not using itunes) which is most of the time.
    I have energy saver set to sleep drives when possible, and I have used CHUB Spindown HD to set the sleep time to 7 minutes. As far as I understand though, sleep time applies to both drives (i.e. if one drive is running then it wont sleep the other). This would explain why my HDD always shows active.
    Is there way to set sleep times separately for separate drives?
    Thanks

    Obviously, spin down doesn't apply to SSD's but for others the key phrase is "when possible." Some (usually external) drives ignore system settings completely & spin up or down according to their own internal logic. Typically, some of them automatically spin down after an internally set interval of inactivity & this is cannot be changed. Less typically, some spin up any time they are accessed, even if no actual read or write is requested, usually as a result of how proprietary energy saver features are implemented.
    This should not apply to drives Apple has supplied as original equipment, or to almost any "raw" internal drive. However, certain operations keep drives spinning or spin them up, thus resetting the spin down timer, & it it isn't always obvious what they are. With your settings, if you leave the Mac alone for while, does internal never spin down? (IOW, can you hear it running without using any command to check on that?)

  • Running FF12.0, how can I set maximum time for History Storage? What's the maximum time?

    Previous versions would allow me to set storage time up to 1 year, I think. Now I can't find the path to set this time. I would like to set it to as much as possible.

    Firefox 4+ versions do not have a time limit for the history.<br />
    Firefox determines automatically how many pages can be kept without affecting the performance.<br />
    You can see the current value via the read-only pref places.history.expiration.transient_max_pages on the about:config page.<br />
    You can reset no longer used browser.history_expire_days* prefs from older Firefox versions, if you still have them, to remove them on the next start.
    See Marco Bonardo's blog about this:
    * http://blog.bonardo.net/2010/01/20/places-got-async-expiration
    *Precise Clear History: https://addons.mozilla.org/firefox/addon/precise-clear-history/
    *Expire history by days: https://addons.mozilla.org/firefox/addon/expire-history-by-days/

  • How to set default time for appointment

    When I had snow leopard, the default time for length of an appointment was one hour.  I upgraded to Lion and now the default time is many hours.  Can't seem to find the area to change the default.  Keith

    Hello User,
    Check this:-
    Sasi Nagireddy: How to Set Default Time Zone for all Users in OBIEE?
    Thanks,
    Sasi Nagireddy..

  • How to set travel time for after a meeting?

    Hi,
    I hope you can help solve this problem...
    Scenario: I have to go to a meeting and come back again.
    Problem: In the Calendar application I can set the travel time for before a meeting but there is seemingly no functionality to set the travel time for after a meeting. Hopefully it hasn't escaped all those fantastic developers that people have to travel back from a meeting as well as travel to it?
    Question: How do I set the travel time in an event for travelling back after a meeting? I would like to avoid the kind of solution where I have to create another separate event just after the meeting event and call it 'travel time'.
    Hope you guys can help...
    Thanks
    Clown Guy

    first make a Locale object as
    public Locale(String language,
    String country)
    Construct a locale from language, country. NOTE: ISO 639 is not a stable standard; some of the language codes it defines (specifically iw, ji, and in) have changed. This constructor accepts both the old codes (iw, ji, and in) and the new codes (he, yi, and id), but all other API on Locale will return only the OLD codes.
    Parameters:
    language - lowercase two-letter ISO-639 code.
    country - uppercase two-letter ISO-3166 code.
    Throws:
    NullPointerException - thrown if either argument is null.
    and then use following method.
    public SimpleDateFormat(String pattern,
    Locale locale)
    Constructs a SimpleDateFormat using the given pattern and the default date format symbols for the given locale. Note: This constructor may not support all locales. For full coverage, use the factory methods in the DateFormat class.
    Parameters:
    pattern - the pattern describing the date and time format
    locale - the locale whose date format symbols should be used

Maybe you are looking for

  • Problem with recognizing javax.mail.* class ?

    Hi Folks, I am new to JavaMail usage on a standalone java program. I did write a java program to send a mail. The problem is it is not recognizing the javax.mail.* class, though i added on the classpath. I too added mail.jar file in the c:\program fi

  • Ip printing does not work

    When I enter the ip number, 10.5 sees the printer and suggests a driver. Once selected, it becomes available, but nos prints are working. The printer instantly sets itself to "pause" mode. Even when clicking on resume, il falls back to pause in micro

  • Snow Leopard and Adobe Flash Question

    I'm aware that SL downgraded my version of flash to the previous one . I had recently downloaded the current version a few days before I installed SL so I did recognize the downgrade. But I've read that some people are having problems when they went

  • Mail doesn't save sent mail on one of my email accounts.....

    Mail doesn't save sent mail on one of my email accounts. I have several accounts, but on one of them it just doesn't save any mail I send. Is there a hidden setting I've missed somewhere? I did delete the account and then reset it, but it took out al

  • Problem with Java in Parallels Desktop...what do you think?

    Hi folks... 2 days ago,i bought a Macbook pro 13" and i've installed Parallels Desktop for working on(Windows XP service pack3)... i guess the problem is Java.. i use Business Objects XI program....(a tool for reporting....) To works,it's needs java