ricmoo / QRCode

QR code generation library in C, optimized for low-power devices, such as Arduino.
Other
638 stars 202 forks source link

Cannot scan qrcodes for version 2 and 3 with android qrdroid reader #25

Closed brennino closed 3 years ago

brennino commented 3 years ago

Hello, I want to report that I'm having issues with qr codes version 2 and 3. I tried to scan qr code generated with this versions and qr droid for android is not able to detect them. I tried to generate qrcodes version 4 and 5 and I can scan them without any issue. This sound strange, maybe a qr droid issue but I want to report the problem anyway to better investigate and check if other people noticed the same thing. Thanks for this software, Regards

ricmoo commented 3 years ago

Can you include the data you are putting in the QR code? Could it be too much data for the QR code version and ECC type?

brennino commented 3 years ago

Hello, thanks for your fast reply. I'm trying to solve this issue on my own for days without any result and now that I have decided to open here an issue I found what's wrong; my fault sorry. But maybe this can help other people. As "Alphanumeric" characters in the table, it seems is intended this kind of characters:

When other signs exists inside the string (for example an equal and question mark characters in my case), you have to check the byte size in the column showed in documentation. In my case I give a string length that is ok for alphanumeric section, too long for byte section but contains characters that are not "alphanumeric" resulting in a wrong qrcode generation.

Really appreciate your work and hope that this can help other people that are trying to generate some beautiful qr codes like me.

Best Regards,

Marco

UPDATE: I checked again your docs, it's clearly stated! Next time I read it 5 times more :) sorry.

ricmoo commented 3 years ago

No worries. It happens. :)