I have project with arduino IDE program that used C language ... I’m using Arduino Uno and RFID RC522 to read a card .. this project work when I scan the card on reader ... So, I want to add another card that can be read a card and accepted my second card[4]={0x56,0x56,0x56,0x56} that i want to add
You could put the valid IDs in a 2 dimensional array and test each of them against the ID scanned in or if there are going to be only 2 valid cards you could at a pinch add a second array holding the second ID and repeat the code for reading the first one and check a second one. Putting the code to do the checking in a function would allow you to do this without repeating the code.
I have project with arduino IDE program that used C language ... I’m using Arduino Uno and RFID RC522 to read a card .. this project work when I scan the card on reader ... So, I want to add another card that can be read a card and accepted my second card[4]={0x56,0x56,0x56,0x56} that i want to add and compare to read it
Hello,
I 'm using the code below to read my card... it works well.
But now I want to add another card ... I added and compare it but it's not working
My second card is {0x56,0x56,0x56,0x56}
Post the code where you tried to add a second card. Describe what the code ACTUALLY does. Describe how that differs from what you expect. Then, we can explain why your expectations are wrong, and how to fix them (or the code).