Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Different Serials #23

Open
amoopoori opened this issue Nov 6, 2023 · 1 comment
Open

Different Serials #23

amoopoori opened this issue Nov 6, 2023 · 1 comment

Comments

@amoopoori
Copy link

Hello, I read an RFID card using this library and received the value 1007534008355, which in hexadecimal is EA 95B4 E823. However, when I read the same card with the Arduino library, it provides the following value: 95 B4 E8 23. How can I convert these values to each other?

@Spritetm
Copy link

For anyone else reading this: it's likely a bug in the library in rc522_sn_to_u64; the original code tries to parse 5 bytes out of a 4-byte serial number. From what I can tell,
for(int i = 4; i >= 0; i--) {
should be changed to
for(int i = 3; i >= 0; i--) {

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants