node-modbus
Advanced tools
Comparing version 2.0.7 to 2.0.8
@@ -35,3 +35,3 @@ | ||
if (!this.timeout) { | ||
this.timeout = 5 * 1000; // 5s | ||
this.timeout = 5000; // ms | ||
} | ||
@@ -47,5 +47,2 @@ | ||
this.log.debug('Trying to flush data.'); | ||
if (this.reqFifo.length === 0) { | ||
@@ -61,8 +58,6 @@ this.log.debug('Nothing in request pipe.'); | ||
currentRequest.defer.reject({ err: 'timeout' }); | ||
this.emit('trashCurrentRequest'); | ||
this.logError('Request timed out.'); | ||
this.setState('error'); | ||
// this.setState('ready'); | ||
@@ -76,3 +71,2 @@ }.bind(this), this.timeout); | ||
}.bind(this); | ||
@@ -88,7 +82,4 @@ | ||
this.log.debug('Cleaning up request fifo.'); | ||
this.reqFifo.forEach(function () { | ||
this.reqFifo.pop(); | ||
}); | ||
this.reqFifo = []; | ||
}.bind(this); | ||
@@ -95,0 +86,0 @@ |
@@ -10,3 +10,3 @@ var stampit = require('stampit'), | ||
var SerialPort = require('serialport').SerialPort, | ||
var SerialPort = require('serialport'), | ||
serialport; | ||
@@ -118,3 +118,2 @@ | ||
serialport.close(); | ||
}; | ||
@@ -121,0 +120,0 @@ |
{ | ||
"name": "node-modbus", | ||
"version": "2.0.7", | ||
"version": "2.0.8", | ||
"description": "Sum of implementations for the Serial/TCP Modbus protocol.", | ||
@@ -5,0 +5,0 @@ "author": "Klaus Landsdorf <klaus.landsdorf@bianco-royal.de>", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
54108
1217