Jump to content

[TOPIC: topicViewTemplate]
[GLOBAL: userSmallPhoto]
Photo

QR Scanner
Started by Michael W. Aug 12 2015 01:53 PM

263 replies to this topic
release android ios
[TOPIC CONTROLS]
« Page 11 of 11 9 10 11
[/TOPIC CONTROLS]
[modOptionsDropdown]
[/modOptionsDropdown]
[reputationFilter]
[TOPIC: post.html]
#251

runewinse

[GLOBAL: userInfoPane.html]
runewinse
  • Contributor

  • 412 posts
  • Corona SDK

runewinse, yup, your jeans have hidden messages left by factory workers.

 

I knew it!

 

I can't see any description in the docs about the different type of symbols. Is there a list somewhere that describes what each sumbol string means?



[TOPIC: post.html]
#252

runewinse

[GLOBAL: userInfoPane.html]
runewinse
  • Contributor

  • 412 posts
  • Corona SDK

BTW: In your docs you write this:

 

Android: 'code39', 'code93', 'code128', 'codabar', 'databar', 'databar_exp', 'ean8', 'ean13', 'i25', 'isbn10', 'isbn13', 'partial', 'pdf417', 'qr', 'upca', 'upce'.
 
iOS: 'aztec', 'code39', 'code39mod43', 'code93', 'code128', 'datamatrix', 'ean8', 'ean13', 'interleaved2of5', 'itf14', 'pdf417', 'qr', 'upce', 'interleaved2of5', 'itf14', 'datamatrix'.
 
 
Where 'datamatrix', 'interleaved2of5' and 'itf14' seems to be listed twice for iOS.


[TOPIC: post.html]
#253

runewinse

[GLOBAL: userInfoPane.html]
runewinse
  • Contributor

  • 412 posts
  • Corona SDK

You can either shorten the symbol list (I don't know which ones cause false detections) or you can add a filter regexp that filters out any values shorter than say 5 characters.

 

If you check 30 secs out in the video (https://youtu.be/4PIdhArQKJc?t=30), you'll see that the scanner reports a 17 digit number so it's not that easy.

 

I have also tried to limit the symbol list to 'qr', 'aztec', 'datamatrix', 'pdf417' and still get these hidden messages from my jeans...

 

Well, I guess it's not much to be done with this. Not such a big deal either.



[TOPIC: post.html]
#254

Lerg

[GLOBAL: userInfoPane.html]
Lerg
  • Contributor

  • 471 posts
  • Corona Staff

Thanks for reporting!

Probably datamatrix causes jeans detections.

Just google the names of the symbols and you can see how they look like and where used.



[TOPIC: post.html]
#255

alfred361

[GLOBAL: userInfoPane.html]
alfred361
  • Observer

  • 4 posts
  • Corona SDK

With the new version I still have the same problem as before.

I need VERY simple app, that shows camera vide all the time, scans the QR and shows result on the screen.

Here's my main.lua code:

display.setStatusBar(display.HiddenStatusBar)

local qrscanner = require('plugin.qrscanner')

local function onResult( event )
  if ( event.isError ) then
		native.showAlert('QR Code Scanner', "Network error: "..event.response, {'OK'})
  else
		native.showAlert('QR Code Scanner', event.response, {'OK'})
  end
end

local function listener(event)
	local path = "http://mydomain.com/check.php?id="..event.message
	network.request(path, "GET", onResult)
end

qrscanner.show{listener = listener} 

Every time it scans QR it shows me black screen. Let me decide what to do (close or leave it) inside my listener, please. Don't close it or give me an option to leave it opened after the scan.



[TOPIC: post.html]
#256

alfred361

[GLOBAL: userInfoPane.html]
alfred361
  • Observer

  • 4 posts
  • Corona SDK

I have two devices: Samsung Galaxy K Zoom and Meizu MX5.

I'm trying your sample app and both gives me the same result:

1. press "Scan QR"

2. pick the QR code, getting green overlay

3. scanner slides right back to main buttons screen without any message

but the listener should call native.showAlert function and show me the result!

What's wrong here?



[TOPIC: post.html]
#257

Lerg

[GLOBAL: userInfoPane.html]
Lerg
  • Contributor

  • 471 posts
  • Corona Staff

Your listener performs network request, it could be network timeout if nothing happens. Or you might be missing the internet permission.

Now I think I understand what you want. You want to quickly go back to the scanner view. There is a room for improvement in such scenario.

 

However you should be able to call  qrscanner.show{listener = listener} in your onResult function. You only have to forward declare the listener or put into a table so that it would be accessible from within the onResult function.



[TOPIC: post.html]
#258

runewinse

[GLOBAL: userInfoPane.html]
runewinse
  • Contributor

  • 412 posts
  • Corona SDK

Thanks for reporting!

Probably datamatrix causes jeans detections.

Just google the names of the symbols and you can see how they look like and where used.

 

Turns out I get false positives for everything from keyboards to my own jottings on paper, but they seem to have gone away when leaving out 'datamatrix' and 'aztec' from the list.

 

The barcode scanning, however is still riddled with false positives:

 

https://youtu.be/WVoOp9w5ASM

 
Is it, with the current implementation, possible to check which symbol type that gives the false positive? Any undocumented event member mayhaps?
 
Or is the problem in my case that the mask is outside of the dotted scanning area? I'm not completely sure how these two areas interact.


[TOPIC: post.html]
#259

runewinse

[GLOBAL: userInfoPane.html]
runewinse
  • Contributor

  • 412 posts
  • Corona SDK

I'm starting to wonder if it is something wring on my end. There are no ends to these false positives. I've attached a supersimple test app which I use to get the false positives in the video below:

 

https://youtu.be/9asr76TJvKw

 

( Seems that the beech desk I've got on my office is very popular :-) )

 

Can you see anything wrong in my code that should result in these false positives?

 

 

 

 

 

 

Attached Files



[TOPIC: post.html]
#260

manolo

[GLOBAL: userInfoPane.html]
manolo
  • Observer

  • 11 posts
  • Enterprise

4 of our live apps use this plugin and the button that uses this plugin just crashes because of the .show function change (Used to take 2 args, now only 1). and they all went unnoticed both by us and the Apple review team. We now have a "crash the app instantly" button. Could these changes happen less often? 

 

Well, at least i'm now subscribed to this topic in case it happens again.



[TOPIC: post.html]
#261

basiliogerman

[GLOBAL: userInfoPane.html]
basiliogerman
  • Enthusiast

  • 76 posts
  • Corona SDK

4 of our live apps use this plugin and the button that uses this plugin just crashes because of the .show function change (Used to take 2 args, now only 1). and they all went unnoticed both by us and the Apple review team. We now have a "crash the app instantly" button. Could these changes happen less often? 

 

Well, at least i'm now subscribed to this topic in case it happens again.

Same problem here.



[TOPIC: post.html]
#262

Lerg

[GLOBAL: userInfoPane.html]
Lerg
  • Contributor

  • 471 posts
  • Corona Staff

Is it, with the current implementation, possible to check which symbol type that gives the false positive? Any undocumented event member mayhaps?

 

 

I'll look if it's possible.

manolo, basiliogerman, I wish there was a mechanism to notify all plugin owners. Making it crash on show() at least makes the problem apparent, if I left optional 2 arguments, you would get errors in the listener processing, which would be much less apparent and hard to debug.

API change was necessary to update the code base and lay ground for any future updates, which should be non-breaking from this point. Sorry for the inconvenience.



[TOPIC: post.html]
#263

max.srdk

[GLOBAL: userInfoPane.html]
max.srdk
  • Enthusiast

  • 36 posts
  • Corona SDK

Still, that would be so great to get the offline qr code generator one sunny day.



[TOPIC: post.html]
#264

Lerg

[GLOBAL: userInfoPane.html]
Lerg
  • Contributor

  • 471 posts
  • Corona Staff

max.srdk, there is one https://forums.coronalabs.com/topic/65821-qrgenerator-for-corona/

Or this library http://speedata.github.io/luaqrcode/
Tweak it to make it run in Corona and you are set.




[topic_controls]
« Page 11 of 11 9 10 11
 
[/topic_controls]



Also tagged with one or more of these keywords: release, android, ios