47

I have inventory maintenance website up and running. currently the back end users are manually typing the item id on the system and using to search and do their work. I would like to automate the typing to scanning qr codes. We are trying to implement users to use their mobile phone camera to act as a scanner.

Thus the user set focus on the text-box and uses his mobile phone to scan the code and the value has to be automatically placed on the text box.

The apps in the market do not transfer data into a pc or web form directly. We are trying to implement an open source web scanner rather then buying an expensive product or app. Can you suggest one or must we create our own app? If so, where can I start from?

BenMorel
  • 34,448
  • 50
  • 182
  • 322
M.A
  • 1,073
  • 2
  • 15
  • 21

6 Answers6

16

Check out https://github.com/serratus/quaggaJS

"QuaggaJS is a barcode-scanner entirely written in JavaScript supporting real- time localization and decoding of various types of barcodes such as EAN, CODE 128, CODE 39, EAN 8, UPC-A, UPC-C, I2of5, 2of5, CODE 93 and CODABAR. The library is also capable of using getUserMedia to get direct access to the user's camera stream. Although the code relies on heavy image-processing even recent smartphones are capable of locating and decoding barcodes in real-time."

Bill Christo
  • 1,223
  • 9
  • 8
13

There's a JS QrCode scanner, that works on mobile sites with a camera:

https://github.com/LazarSoft/jsqrcode

I have worked with it for one of my project and it works pretty good !

edi9999
  • 19,701
  • 13
  • 88
  • 127
7

Scandit is a startup whose goal is to replace bulky, expensive laser barcode scanners with cheap mobile phones.

There are SDKs for Android, iOS, Windows, C API/Linux, React Native, Cordova/PhoneGap, Xamarin.

There is also Scandit Barcode Scanner SDK for the Web which the WebAssembly version of the SDK. It runs in modern browsers, also on phones.

There's a client library that also provides a barcode picker component. It can be used like this:

<div id="barcode-picker" style="max-width: 1280px; max-height: 80%;"></div>

<script src="https://unpkg.com/scandit-sdk"></script>
<script>
    console.log('Loading...');
    ScanditSDK.configure("xxx", {
engineLocation: "https://unpkg.com/scandit-sdk/build/"
    }).then(() => {
      console.log('Loaded');
      ScanditSDK.BarcodePicker.create(document.getElementById('barcode-picker'), {
        playSoundOnScan: true,
        vibrateOnScan: true
      }).then(function(barcodePicker) {
        console.log("Ready");
        barcodePicker.applyScanSettings(new ScanditSDK.ScanSettings({
          enabledSymbologies: ["ean8", "ean13", "upca", "upce", "code128", "code39", "code93", "itf", "qr"],
          codeDuplicateFilter: 1000
        }));
        barcodePicker.onScan(function(barcodes) {
          console.log(barcodes);
        });
      });
    });
</script>

Disclaimer: I work for Scandit

mak
  • 13,267
  • 5
  • 41
  • 47
  • I am using same code with my owns license key, it turns my mobile camera on, on barcode scan it also gives sound, but no scan result output, where barcode result goes? and how I can access that result in my input form text field? can you briefly explain it? – Faiz Fareed Jul 17 '18 at 13:57
  • @FaizFareed, the barcode result is available in the `onScan` callback method, in my code it simply prints it to the console. Here is a sample which saves the barcode in an input form text field: https://github.com/Scandit/barcodescanner-sdk-for-web-samples/blob/master/scan-into-input/index.html – mak Aug 21 '18 at 10:06
  • 7
    And "Pricing" page shows only "Contact us for quote" buttons. Very informative... – Styx Dec 19 '18 at 13:37
  • 4
    Great software but very expensive. US$2450 per year for 1-50 devices - their least expensive plan apparently – Peter Koopman Aug 01 '19 at 20:58
  • High cost subscription or per scan costing model? No thanks - give us a one off cost, businesses do not like high value subscriptions. – Mark G Jun 04 '20 at 09:46
  • @mak - Is this SDKs code available in Javascript or Jquery? So that i can use it in my ASP.Net MVC application – Krishnraj Rana Dec 14 '20 at 17:21
  • great solution, but expensive – Fernando Meneses Gomes Jun 04 '21 at 19:40
3

You can use the Android app Barcode Scanner Terminal (DISCLAIMER! I'm the developer). It can scan the barcode and send it to the PC and in your case enter it on the web form. More details here.

TheStoryCoder
  • 3,403
  • 6
  • 34
  • 64
-1

Check this out: http://qrdroid.com/web-masters.php

You can create a link in your web form, something like:

http://qrdroid.com/scan?q=http://www.your-site.com/your-form.php?code={CODE}

When somebody clicks that link, an app to scan the code will be opened. After the user scans the code, http://www.your-site.com/your-form.php?code={CODE} will be automatically called. You can then make your-form.php read the parameter code to prepopulate the field.

Jorge Cevallos
  • 3,667
  • 3
  • 25
  • 37
-2

We have an app in Google Play and the App Store that will scan barcodes into a web site. The app is called Scan to Web. http://berrywing.com/scantoweb.html

You can even embed a link or button to start the scanner yourself within your web page.

<a href="bwstw://startscanner">Link to start scanner</a>

The developer documentation website for the app covers how to use the app and use JavaScript for processing the barcode scan. http://berrywing.com/scantoweb/#htmlscanbutton

Berry Wing
  • 113
  • 1
  • 5