help with for loop
i running code receive rfid data, not whole code, when run code gives me output (below code).
where finds code writes there(if code placed 1st in array displays there).
how can receive "authorize" "not authorize" when finds whether in array or not
boolean asd;
for(int l=0;l<5;l++)
{
for(int o=0;o<5;o++)
{
if(tagin
where finds code writes there(if code placed 1st in array displays there).
how can receive "authorize" "not authorize" when finds whether in array or not
boolean asd;
for(int l=0;l<5;l++)
{
for(int o=0;o<5;o++)
{
if(tagin
- ==data[l]
- )
{
asd=true;
}
else
{
asd=false;
}
}
switch(asd)
{
case true:
{
for(int k=0;k<5;k++)
serial.print(tagin[k]);
serial.println("\nauthorize");
break;
}
case false:
{
serial.print("\nnot authorize\n");
break;
}
}
}
not authorize
14522294116101
authorize
not authorize
not authorize
not authorize
hi, welcome forum.
please click "modify" on first post , add [code] ... [/code] tags around code.
please click "modify" on first post , add [code] ... [/code] tags around code.
Arduino Forum > Using Arduino > Programming Questions > help with for loop
arduino
Comments
Post a Comment