Merge pull request #44 from kfstudio/enttec_config

Resolve serialport config issues, part of issue #24
This commit is contained in:
Frédéric Bolvin 2018-02-19 13:09:03 +01:00 committed by GitHub
commit 038b84510b
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 11 additions and 11 deletions

View file

@ -12,8 +12,8 @@ function DMX4ALL(device_id, options) {
this.dev = new SerialPort(device_id, { this.dev = new SerialPort(device_id, {
'baudRate': 38400, 'baudRate': 38400,
'databits': 8, 'dataBits': 8,
'stopbits': 1, 'stopBits': 1,
'parity': 'none' 'parity': 'none'
}, function(err) { }, function(err) {
if(!err) { if(!err) {

View file

@ -16,18 +16,18 @@ function DMXKingUltraDMXPro(device_id, options) {
this.options = options || {} this.options = options || {}
this.universe = new Buffer(513) this.universe = new Buffer(513)
this.universe.fill(0) this.universe.fill(0)
this.sendDMXReq = DMXKING_ULTRA_DMX_PRO_SEND_DMX_RQ this.sendDMXReq = DMXKING_ULTRA_DMX_PRO_SEND_DMX_RQ
if (this.options.port === "A") { if (this.options.port === "A") {
this.sendDMXReq = DMXKING_ULTRA_DMX_PRO_SEND_DMX_A_RQ this.sendDMXReq = DMXKING_ULTRA_DMX_PRO_SEND_DMX_A_RQ
} else if (this.options.port === "B") { } else if (this.options.port === "B") {
this.sendDMXReq = DMXKING_ULTRA_DMX_PRO_SEND_DMX_B_RQ this.sendDMXReq = DMXKING_ULTRA_DMX_PRO_SEND_DMX_B_RQ
} }
this.dev = new SerialPort(device_id, { this.dev = new SerialPort(device_id, {
'baudRate': 250000, 'baudRate': 250000,
'databits': 8, 'dataBits': 8,
'stopbits': 2, 'stopBits': 2,
'parity': 'none' 'parity': 'none'
}, function(err) { }, function(err) {
if(!err) { if(!err) {

View file

@ -13,8 +13,8 @@ function EnttecOpenUsbDMX(device_id, options) {
this.dev = new SerialPort(device_id, { this.dev = new SerialPort(device_id, {
'baudRate': 250000, 'baudRate': 250000,
'databits': 8, 'dataBits': 8,
'stopbits': 2, 'stopBits': 2,
'parity': 'none' 'parity': 'none'
}, function(err) { }, function(err) {
if(err) { if(err) {

View file

@ -14,11 +14,11 @@ function EnttecUSBDMXPRO(device_id, options) {
options = options || {} options = options || {}
this.universe = new Buffer(513) this.universe = new Buffer(513)
this.universe.fill(0) this.universe.fill(0)
this.dev = new SerialPort(device_id, { this.dev = new SerialPort(device_id, {
'baudRate': 250000, 'baudRate': 250000,
'databits': 8, 'dataBits': 8,
'stopbits': 2, 'stopBits': 2,
'parity': 'none' 'parity': 'none'
}, function(err) { }, function(err) {
if(!err) { if(!err) {