Hi, I'm needing assistance on how to fix this problem that is showing on my monitor.
it always shows this error:
"too many arguments to function 'long unsigned int millis()'"
this is the code and the error is "red-fonted" in red.
Thank You For Your Help.
//Switch 1 Variables
int state_s1 = 0; // declaring that case 0 is the main state to be in / "stand by"
int state_prev_s1 = 0; // start of main state
int pin_s1 = 2; // stores the pin that we are connected to with our switch
int val_s1 = 0; // stores whether the switch is high or low when we read it
unsigned long t_s1 = 0; // stores large numbers / timer(basically current time)
unsigned long t_0_s1 = 0; // time "0" = the start of time(basically previous time)
int led = 13; // the pin the LED is connected to
case 3: //WAIT (PRESENCE JUDGEMENT)
if (val_s1 = (digitalRead(2)));
t_s1 = millis(5000);
if
(if (val_s1 == HIGH); {state_s1;}
if (t_s1 - t_0_s1 > 5000){state_s1 = 4;})
else
(if (val_s1 == LOW); {state_s1;}
if (t_s1 - t_0_s1 > 5000){state_s1 = 0;})
break;