feedmode delay

Do you have a question on how to do something.
Ask in here.

Posts: 214
Joined: Sat Oct 10, 2015 9:17 pm
PostPosted: Thu Jun 07, 2018 4:27 pm
update..fixxed
delay return only after feed mode
Code: Select all
//C First X sec after feeding mode disable return
    static time_t FMTimer=0;
    if (ReefAngel.DisplayedMenu == FEEDING_MODE) FMTimer=now();
    if (now()-FMTimer >= 0 && now()-FMTimer < 300))//300 is secs
    {ReefAngel.Relay.Off(RETURN);}else{ReefAngel.Relay.On(RETURN);}
//C First X sec after feeding mode disable return
Last edited by troylong45 on Sat Jun 09, 2018 12:54 pm, edited 1 time in total.
Image
User avatar
Posts: 2738
Joined: Fri Mar 18, 2011 6:20 pm
Location: Illinois
PostPosted: Sat Jun 09, 2018 11:45 am
Have you looked at the DelayedOn() function in the libraries? That would be my suggestion on where to start. (I have not read/looked through your code you posted yet. I just wanted to give you a reference place to start first.)

Posts: 214
Joined: Sat Oct 10, 2015 9:17 pm
PostPosted: Sat Jun 09, 2018 12:50 pm
i just found a fix i thought i deleated this post oups
Image

Return to How do I code ...

Who is online

Users browsing this forum: No registered users and 2 guests