Good evening,
I'm looking in a main loop to test several values at the same time:
the value of a fingerprint sensor (finger()...), a keypad (alarm, pave_num()) and a force sensor (scale.getGram() which tests in grams an effort)
If the fingerprint sensor and keypad are ok I activate the cylinder opening (no problem)
But as soon as I add while(scale.getGram() >= 15 (kg)) my fingerprint sensor slowed down and I have trouble entering the password on the keypad....
Therefore I would like to execute these two conditions at the same time.
void loop()
{
fingerprintID = getFingerprintIDez();
alarm = pave_num()
if (finger.fingerID == 1 and alarm == 0)
{
Serial.println("MALLETTE UNLOCK");
cylender_S();
delay(1000);
cylender_R();
}
while (scale.getGram() >= 15)
{
pump();
}
}
Thank you in advance;)