Skip to content

Commit 1c7588d

Browse files
committed
Logic changed and Readability improved
Changed the way the auto enrollment id selector code works, and changed "okid" to "usedid" so that the code is easier to understand.
1 parent bd1e639 commit 1c7588d

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

FPS_GT511C3/Examples/FPS_Enroll/FPS_Enroll.ino

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -34,11 +34,11 @@ void Enroll()
3434

3535
// find open enroll id
3636
int enrollid = 0;
37-
bool okid = false;
38-
while (okid == false)
37+
bool usedid = true;
38+
while (usedid == true)
3939
{
40-
okid = fps.CheckEnrolled(enrollid);
41-
if (okid==false) enrollid++;
40+
usedid = fps.CheckEnrolled(enrollid);
41+
if (usedid==true) enrollid++;
4242
}
4343
fps.EnrollStart(enrollid);
4444

0 commit comments

Comments
 (0)