Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

arduino-firmata

Package Overview
Dependencies
Maintainers
1
Versions
13
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

arduino-firmata - npm Package Compare versions

Comparing version 0.0.1 to 0.0.2

4

History.txt

@@ -0,1 +1,5 @@

=== 0.0.2 2014-01-26
* use SerialPort.list() instead of fs.readdir()
=== 0.0.1 2014-01-26

@@ -2,0 +6,0 @@

16

lib/arduino-firmata.js
(function() {
var ArduinoFirmata, SerialPort, debug, events, fs,
var ArduinoFirmata, SerialPort, debug, events,
__hasProp = {}.hasOwnProperty,

@@ -8,4 +8,2 @@ __extends = function(child, parent) { for (var key in parent) { if (__hasProp.call(parent, key)) child[key] = parent[key]; } function ctor() { this.constructor = child; } ctor.prototype = parent.prototype; child.prototype = new ctor(); child.__super__ = parent.prototype; return child; };

fs = require('fs');
SerialPort = require('serialport').SerialPort;

@@ -62,4 +60,4 @@

ArduinoFirmata.list = function(callback) {
return fs.readdir('/dev', function(err, files) {
var devices, f, _i, _len;
return require('serialport').list(function(err, ports) {
var devices, port, _i, _len;
if (err) {

@@ -69,6 +67,6 @@ callback(err);

devices = [];
for (_i = 0, _len = files.length; _i < _len; _i++) {
f = files[_i];
if (f.match(/tty\.?(usb|acm)/i)) {
devices.push("/dev/" + f);
for (_i = 0, _len = ports.length; _i < _len; _i++) {
port = ports[_i];
if (port.comName.match(/usb|acm|com\d+/i)) {
devices.push(port.comName);
}

@@ -75,0 +73,0 @@ }

{
"name": "arduino-firmata",
"private": false,
"version": "0.0.1",
"version": "0.0.2",
"description": "Arduino Firmata implementation for Node.js",

@@ -6,0 +6,0 @@ "main": "lib/arduino-firmata.js",

@@ -9,2 +9,3 @@ arduino-firmata

- https://github.com/shokai/node-arduino-firmata
- https://npmjs.org/package/arduino-firmata

@@ -11,0 +12,0 @@

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

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

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc