Socket
Socket
Sign inDemoInstall

node-usb-barcode-scanner

Package Overview
Dependencies
15
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    node-usb-barcode-scanner

Package to help work with USB HID based barcode scanners in nodejs


Version published
Weekly downloads
1
decreased by-80%
Maintainers
1
Created
Weekly downloads
 

Readme

Source

node-usb-barcode-scanner

Package to help work with USB HID based barcode scanners in nodejs

Usage

var usbScanner = require('../usbscanner').usbScanner;
var getDevices = require('../usbscanner').getDevices;

//get array of attached HID devices
var connectedHidDevices = getDevices()

//print devices
console.log(connectedHidDevices)

//initialize new usbScanner - takes optional parmeters vendorId and hidMap - check source for details
var scanner = new usbScanner();

//scanner emits a data event once a barcode has been read and parsed
scanner.on("data", function(code){
	console.log("recieved code : " + code);
});

  • Thanks @hanshuebner for node-hid

Keywords

FAQs

Last updated on 21 Sep 2015

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc