Results 1 to 6 of 6

Thread: Whats the best way to Realize a Countdown?

  1. #1
    Constant Bitrate
    Join Date
    Jan 2007
    Posts
    126

    Whats the best way to Realize a Countdown?

    I am trying to implement a countdown screen that i can set a certain time with and then when the countdown expires trigger an event. I know RRextended has a timer function however i was not quite sure how i would create fields and then convert to seconds (methodically not mathematically lol)

    also is there a way i can trigger an alarm at a time that i set on a screen?


    Reason i am doing is so i can set the car start itself in the hot/cold morning at a certain time using fuzionbrain. (unfortunately its out of wifi range otherwise i wouldn't be asking this.

    thx for any info and help
    phil

  2. #2
    Maximum Bitrate bratnetwork's Avatar
    Join Date
    Oct 2007
    Location
    Haledon, NJ
    Posts
    503
    this is a cool idea, but wouldn't this require leaving the PC on all the time then?

  3. #3
    Constant Bitrate
    Join Date
    Jan 2007
    Posts
    126
    good observation. yes my pc is running all the time. I have a second isolatoted battery in the back of the car that. Its a yellowtop (deep cycle battery). Fusionbrain also monitors battery voltage and starts an engine cycle and connects second battery when the battery voltage gets critically low...





    the code if you are curios:

    /, AUTO CYCLE

    "DIG1TOG", "DIGITALOUT1;TOGGLE'

    "IGNITIONCHECKOFF", "BYIND;DIGITALOUT1STATUS;DIG1TOG<<NA"
    "IGNITIONCHECKON", "BYIND;DIGITALOUT1STATUS;NA<<DIG1TOG"
    "IGNITIONCHECKONSTART", "BYIND;DIGITALOUT1STATUS;NA<<DIGITALOUT0SWITCH ;1"

    "GETLOGRUNS","IniKeyToVar;$RRPATH$enginerun.ini;Se ct 1;EngineRuns;RUNS"
    "SAVELOGRUNS","VarToIniKey;$RRPATH$enginerun.ini;S ect 1;EngineRuns;$RUNS$"

    /, Check 1 (do not engage if cycle is already running)
    "RRFUSION_ALERT0","BYVAR;ISCYCLERUNNING;PRECHECK1< <NA"

    /, Check 2 (do not engage if ignition is on)
    "PRECHECK1","BYIND;DIGITALOUT1STATUS;STARTSEQUENCE <<NA"

    "STARTSEQUENCE","SETVAR;ISCYCLERUNNING;1||GETLOGRU NS||LOAD;crit_battery.skin||GblTmr_Add;Tmrignition ;60;Timer_Ignition;oneshot"

    "Timer_Ignition","GblTmr_Del;Tmrignition||IGNITION CHECKOFF||DELAYEXEC;2;IGNITIONCHECKONSTART||GblTmr _Add;Tmrshutdown;900;Timer_Shutdown;oneshot||EVAL; RUNS;$RUNS$+1||SAVELOGRUNS||DELAYEXEC;7;AUXBATCON"


    "Timer_Shutdown","GblTmr_Del;Tmrshutdown||IGNITION CHECKON||ADDTOFILE;$RRPATH$enginerun.ini;TIME||ADD TOFILE;$RRPATH$enginerun.ini;DATE||SETVAR;ISCYCLER UNNING;0||MAIN||DELAYEXEC;20;AUXBATDIS"


    /,END AUTO CYCLE

  4. #4
    RoadRunner Mastermind
    Auto Apps:loading...
    guino's Avatar
    Join Date
    Nov 2004
    Location
    Toronto, Canada
    Posts
    9,818
    There's a timeexec plugin which allows you to execute commands based on ini setting.

    If you are talkinga about executing a command after a number of seconds, you can use the TMR definition. If you need something re-occuring or events in between you may consider "delayexec" or the timer funcions from RRExtended.
    Ride Runner RR's Myspace

    "Being happy is not about having what you want, it's about wanting what you have."
    "The best things in life are always free - but that doesn't mean money can't buy you good things."

  5. #5
    Constant Bitrate
    Join Date
    Jan 2007
    Posts
    126
    Quote Originally Posted by guino View Post
    There's a timeexec plugin which allows you to execute commands based on ini setting.

    If you are talkinga about executing a command after a number of seconds, you can use the TMR definition. If you need something re-occuring or events in between you may consider "delayexec" or the timer funcions from RRExtended.
    yeah i was going to use the RRextended functions however the problem i have is more of how to create a field that has a programmable time in there... lets say 2 fields one with hour one with minutes... so i would need to somehow take the two variables in there convert and add them...thats the part im not familiar with ..

  6. #6
    RoadRunner Mastermind
    Auto Apps:loading...
    guino's Avatar
    Join Date
    Nov 2004
    Location
    Toronto, Canada
    Posts
    9,818
    probably easier to use a variable and just have the user enter the setting directly using the OSK/NUMOSK -- i.e. click a button to edit the hour, then click another to edit the minutes, or just have one button to edit the whole thing (hour+minutes). This can be done with a label code "=$MYTIME$" and using a button with the code "OSKTOVAR;MYTIME", then you can use the variable MYTIME wherever else you want it -- You can do the same thing individually for the hour/minutes. To add the variables (numerically) you can use EVAL and to add them on a command you can just put them directly in the command/label like "=$MYHOUR$:$MYMINUTES$" (to display the content of HOUR:MINUTES like 02:14).
    Ride Runner RR's Myspace

    "Being happy is not about having what you want, it's about wanting what you have."
    "The best things in life are always free - but that doesn't mean money can't buy you good things."

Similar Threads

  1. Replies: 8
    Last Post: 10-19-2006, 07:32 PM
  2. Didn't Realize til now 'DUH'!
    By chuckster in forum Road Runner
    Replies: 1
    Last Post: 10-26-2005, 07:51 PM
  3. Countdown to NOPI and car PC goes up in smoke
    By gizmomkr in forum General Hardware Discussion
    Replies: 5
    Last Post: 09-18-2003, 09:12 PM
  4. Countdown....
    By vickumar in forum Off Topic
    Replies: 9
    Last Post: 06-04-2002, 09:35 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •