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?
This question is related to
javascript
html
qr-code
barcode-scanner
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 !
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.
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
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
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."
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.
Source: Stackoverflow.com