Skip to content

Commit

Permalink
remove some logging and tidy code
Browse files Browse the repository at this point in the history
  • Loading branch information
daniep01 committed Aug 17, 2022
1 parent be6497a commit a355763
Showing 1 changed file with 5 additions and 6 deletions.
11 changes: 5 additions & 6 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@ instance.prototype.deviceInformation = function (key, data) {
}

if (key == 'STREAM STATE') {
console.log('stream state = ' + data)
// console.log('stream state = ' + data)

if (data['Status'] !== undefined) {
self.streaming = data['Status']
Expand Down Expand Up @@ -168,7 +168,7 @@ instance.prototype.init = function () {
self.timer = undefined
self.init_tcp()

self.update_variables() // export variables
self.update_variables()
self.init_presets()
}

Expand Down Expand Up @@ -217,7 +217,7 @@ instance.prototype.init_tcp = function () {

// separate buffered stream into lines with responses
self.socket.on('data', function (chunk) {
console.log('data received')
// console.log('data received')
var i = 0,
line = '',
offset = 0
Expand All @@ -228,7 +228,7 @@ instance.prototype.init_tcp = function () {
offset = i + 1
if (line.toString() != 'ACK') {
self.socket.emit('receiveline', line.toString())
console.log(line.toString())
// console.log(line.toString())
}
}

Expand All @@ -238,7 +238,7 @@ instance.prototype.init_tcp = function () {
self.socket.on('receiveline', function (line) {
if (self.command === null && line.match(/:/)) {
self.command = line
console.log('command: ' + line)
// console.log('command: ' + line)
} else if (self.command !== null && line.length > 0) {
self.stash.push(line.trim())
} else if (line.length === 0 && self.command !== null) {
Expand Down Expand Up @@ -399,7 +399,6 @@ instance.prototype.init_presets = function () {
var self = this
var presets = []

// Signal present
presets.push({
category: 'Streaming',
label: 'Start Stream',
Expand Down

0 comments on commit a355763

Please sign in to comment.