void turnFeeder(void)
{
lcd.setCursor(0,0);
lcd.print("turnFeeder");
static byte pinState = HIGH;
if (millis() - feedTime < 3000UL) // 30 seconds
{
if (pinState = HIGH)
{
digitalWrite(motorPin, pinState);
pinState = LOW;
}
}
else
{
digitalWrite(motorPin, pinState);
pinState = HIGH;
feedPet = false;
}
}
what happened when the time hit the specified target was the date is read "turnFeeder" and the place where the seconds are read "time"