Forum Software Ferduino code Shortcut on main screen to manual timer

Shortcut on main screen to manual timer  [SOLVED]


Post Number:#1 Post Wed Jul 23, 2014 2:45 am
Posts: 92
Topics: 10
Solve rating: 0
Joined: Sat May 17, 2014 9:03 am
Topics: 10
Age: 43
Gender: None specified
National Flag:
France
Hi Fernando !! :-h

Can you help me for create touch shortcut on main screen (timer print) to make manual on or off timer 1.
Because the touch process is too difficult for me.
This feature allows you to manually feed the fish, which is a real pleasure to see them eat.

Thanks you in advance.

Sueur Aurelien

Post Number:#2 Post Wed Jul 23, 2014 10:11 am
Posts: 1699
Topics: 38
Images: 301
Solve rating: 233
Joined: Mon Mar 03, 2014 5:59 pm
Topics: 38
Age: 39
Location: São Paulo
Gender: Male
National Flag:
Brazil

Hi!

You want skip to this menu?

Image


Best regards.
Post your doubts on forum because it can help another user too. Just PM me for support if it's absolutely necessary.

Post Number:#3 Post Thu Jul 24, 2014 4:00 pm
Posts: 92
Topics: 10
Solve rating: 0
Joined: Sat May 17, 2014 9:03 am
Topics: 10
Age: 43
Gender: None specified
National Flag:
France
Hi!

I want when I touch the area with the red outline, it disables the function timer 1 10 min.

Image


Image


after for my skimmer I should conbiner function timer 2 with timer1:
When timer 1 if off -> timer 2 is off
When timer 1 go on -> timer 2 go on After 60 second.

thank you for your help

Post Number:#4 Post Thu Jul 24, 2014 4:32 pm
Posts: 1699
Topics: 38
Images: 301
Solve rating: 233
Joined: Mon Mar 03, 2014 5:59 pm
Topics: 38
Age: 39
Location: São Paulo
Gender: Male
National Flag:
Brazil

Hi!

You can make it using a method very simple.

Add in ferduino tab:

unsigned long interval_feed_millis = 0;
int interval_feed = 10; // in minutes
boolean feed_mode = false;


Add on loop:

if(feed_mode == true)
{
  if((millis() - interval_feed_millis) > (interval_feed*60000))
  {
    feed_mode = false;
    ler_timers_EEPROM();
  }
}


in ProcessyMyTouch find:

    case 0:                       //Tela de inico
      dispScreen=30;
      clearScreen();
      solicitar_senha();
      break;


Replace with:

    case 0:                       //Tela de inico
      if(((x > 0)  &&  (x < 399)  &&  (y > 0)  &&  (y < 138)) || ((x > 128) && (x < 399) && (y >= 138) && (y < 239)))
      {
        dispScreen=30;
        clearScreen();
        solicitar_senha();
        break;
      }
      else
      {
        feed_mode = true;
        interval_feed_millis = millis();
        temporizador_1_ativado = 0;
        temporizador_2_ativado = 0;
      }


Best regards.
Post your doubts on forum because it can help another user too. Just PM me for support if it's absolutely necessary.

Post Number:#5 Post Thu Jul 24, 2014 4:52 pm
Posts: 92
Topics: 10
Solve rating: 0
Joined: Sat May 17, 2014 9:03 am
Topics: 10
Age: 43
Gender: None specified
National Flag:
France
Fernando you are very impressive ^:)^
thank you very much, i test it.

Post Number:#6 Post Thu Jul 24, 2014 5:17 pm
Posts: 1699
Topics: 38
Images: 301
Solve rating: 233
Joined: Mon Mar 03, 2014 5:59 pm
Topics: 38
Age: 39
Location: São Paulo
Gender: Male
National Flag:
Brazil

Glad to hear!
Post your doubts on forum because it can help another user too. Just PM me for support if it's absolutely necessary.




Return to Ferduino code





Who is online

Users viewing this topic: No registered users and 1 guest

cron