Start and reset a timer in PICED Logic

Discussion in 'C-Touch/HomeGate/SchedulePlus/PICED Software' started by mjjafari, Nov 21, 2022.

  1. mjjafari

    mjjafari

    Joined:
    Jul 28, 2021
    Messages:
    22
    Likes Received:
    0
    Hi there, can you please let me know how can I do the following in PICED
    • how to define and start a timer for example after a group address turns on
    • Take action when timer reaches a pre defined value
    • Reset the above timer
     
    mjjafari, Nov 21, 2022
    #1
    1. Advertisements

  2. mjjafari

    Ashley

    Joined:
    Dec 1, 2005
    Messages:
    1,423
    Likes Received:
    160
    Location:
    Adelaide, Australia
    It's all in the Logic help manual with examples. What's the problem?
     
    Ashley, Nov 21, 2022
    #2
    1. Advertisements

  3. mjjafari

    mjjafari

    Joined:
    Jul 28, 2021
    Messages:
    22
    Likes Received:
    0
    I did look trough the manual but didn’t find it. There is no problem just don’t know how to start and reset a timer
     
    mjjafari, Nov 21, 2022
    #3
  4. mjjafari

    Wonkey

    Joined:
    Aug 3, 2004
    Messages:
    303
    Likes Received:
    26
    Location:
    Adelaide
    In the logic engine there is a wizard that will basically create the code for you.
    Click on the wand and answer the questions.
    With regard to resetting the timer if you are only using it this way then when the expiry function happens the time is reset and when the action happens again then it will start at 0.
    There are other timers available in the logic which do require resetting, with regard to the help make sure you click on logic. and then search timers.
    A finished timer module for turning off a group address using the wizard would look something like this.
    { turn off the spa after 1 hour of use}

    once (GetLightingState("eDLT Pump") = ON) then
    begin
    Delay("1:00:00");
    SetLightingState("eDLT Pump", OFF);
    end;
     
    Wonkey, Nov 22, 2022
    #4
  5. mjjafari

    Ashley

    Joined:
    Dec 1, 2005
    Messages:
    1,423
    Likes Received:
    160
    Location:
    Adelaide, Australia
    Look harder: Logic Engine Functions/Timer Function has TimerRunning, TimerSet, TimerStart, TimerStop, TimerTime, all with examples.

    Perhaps you should describe what you are trying to do. In my experience there are always better options than a timer. I have written thousands of lines of logic and never needed a timer.
     
    Ashley, Nov 23, 2022
    #5
    1. Advertisements

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.