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

Add support for QR Model 2 #28

Closed
TheLastProject opened this issue Oct 24, 2020 · 4 comments
Closed

Add support for QR Model 2 #28

TheLastProject opened this issue Oct 24, 2020 · 4 comments
Labels

Comments

@TheLastProject
Copy link
Member

Issue by numericOverflow
Friday Jun 15, 2018 at 23:45 GMT
Originally opened as brarcher/loyalty-card-locker#253


I have a couple cards that use model 2 QR codes, but it looks like the app only generates model 1 codes. They typically work, but some scanners a flakey and really seem to want that model 2 image.

Supposedly model 2 has better support for curved surfaces and distorted images, along with more data capacity (but we likely don't care about huge data payload).

http://www.qrcode.com/en/codes/model12.html

@TheLastProject
Copy link
Member Author

Comment by brarcher
Saturday Jun 16, 2018 at 19:16 GMT


The barcode support for this app comes from the zxing-android-embedded project, which in turn pulls from the zxing project. If the upstream zxing project were to add support and zxing-android-embedded were to pick it up, I'd gladly add support. Currently this app uses the latest release of zxing-android-embedded.

I encourage you to verify with the zxing test app here that it indeed does not support QR code v2. If it does not, kindly add a request to that project. If it does actually have support, let me know and I can help see if it is the zxing-android-embedded project which is missing support.

@TheLastProject
Copy link
Member Author

Comment by numericOverflow
Sunday Jun 17, 2018 at 17:01 GMT


@brarcher - I did try scanning these mode 1 & 2 QR codes with the xzing app, and they read just fine.

It looks like zxing library does support QR model 2 by passing a Map hints with "QR_VERSION":

@TheLastProject
Copy link
Member Author

Comment by brarcher
Sunday Jun 17, 2018 at 19:01 GMT


Oh, that sounds promising then. Thanks for looking into that.

So, what you are looking for is the app displaying QR model 2 codes. I think this is doable. I'll need to see how best to support it, as there currently is no plumbing in the app for hints.

Questions:

  1. Do you know if QR model 2 is backwards compatible with QR model 1? That is, should a scanner for model 1 be able to read many or most model 2 codes?
  2. How should the app allow one to enter a QR model 2 code? I should be able to generate both model 1 and model 2 codes to pick from when manually entering the code, but I'm curious if that is the expected way to add a model 2 card. I think when a code is scanned with the camera it would only say it is a QR code, but not mention it is a model 1 or 2.

@github-actions
Copy link
Contributor

This issue is missing necessary information and cannot be worked on in its current state. It has therefore been closed to keep the issue tracker clean. If you have more information, feel free to reopen it.

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

No branches or pull requests

1 participant