15

I'm looking to integrate some sort of barcode scanner into a phonegap application. I just need to find out whether it is possible on all of the major platforms (iOS/Android/Blackberry/WP7)?

EDIT: By barcode scanning, I mean scanning a barcode through the camera.

Thanks!

David Archer
  • 2,008
  • 4
  • 26
  • 31
  • Maybe [this](http://stackoverflow.com/questions/3888396/how-to-scan-barcode-using-phonegap) question helps – v01d Nov 29 '11 at 13:19
  • Thanks, that answers the Android one. I also found an iPhone one, so the big question now is: what about blackberry and WP7? – David Archer Nov 29 '11 at 13:52
  • For WP7 try [this](http://stackoverflow.com/questions/4419707/windows-phone-7-barcode-scan-library-or-capability) – v01d Nov 29 '11 at 13:55
  • Ah, excellent. Not quite Phonegap, but a decent start. Blackberry seems to be more difficult. – David Archer Nov 29 '11 at 14:03
  • It seems that the ZXing library is the way to go, but Blackberry will be a pain. Oh well! – David Archer Nov 29 '11 at 14:04

5 Answers5

34

We have made BarcodeScanner plugins available for:

Android https://github.com/phonegap/phonegap-plugins/tree/master/Android/BarcodeScanner

iOS https://github.com/phonegap/phonegap-plugins/tree/master/iPhone/BarcodeScanner

BlackBerry https://github.com/phonegap/phonegap-plugins/tree/master/BlackBerry/BarcodeScanner

We don't have a plugin for WP7 yet but I'll drop an email to Jesse and maybe he'll get to it as WP7 support is growing fast.

Simon MacDonald
  • 23,253
  • 5
  • 58
  • 74
9

Windows Phone Barcode Scanner Plugin in PhoneGap We have now the phonegap plugin for barcode scanner. You can check it here: https://github.com/phonegap/phonegap-plugins/tree/master/WindowsPhone/BarcodeScanner

mohitum
  • 936
  • 2
  • 12
  • 26
5

Another option would be the Scandit barcode scanner SDK. Scandit comes with a PhoneGap plugin for iOS and Android (WP and Blackberry are not supported at this time), and there is a free community edition. Tutorials and demo apps are available here:

Scandit also decodes blurry images, which is important if an app needs to run on lower-end phones (such as many Android phones) or devices without an autofocus camera (iPad 2, iPod Touch, ...).

(Disclaimer: I'm one of the Scandit developers.)

chris
  • 217
  • 3
  • 1
1

In case this helps anyone: https://github.com/zeroasterisk/PhoneGap-BarcodeScanner-Example-iOS

Specifically:

Installed the plugin (in a handful of paths) but kept the one which worked. Implemented a basic JS scanner code to demonstrate functionality: auto-runs on load, auto-reloads on error, alerts on success/failure/cancel.

NOTE: the comments on the barcodescanner.js and index.js, both mention my customization of the define/require object paths. I could not get the demo/example paths to work, after several permutations.

(this is iOS only atm, but I plan on making an Android example too)

zeroasterisk
  • 2,199
  • 1
  • 23
  • 28
1

The Manatee Works Barcode Scanner SDK PhoneGap plugin can be found here: https://github.com/manateeworks/phonegap-mwbarcodescanner

The plugin supports Android, iOS, and Windows. UPC and EAN are free. Other symbologies can be evaluated for free. Our price is better than Scandit for the same quality (sometimes better). Our company is financially stable and not having to borrow money to survive.

(Disclaimer: I am a member of the Manatee Works team.)