Skip to content

Commit 2992d23

Browse files
author
AJ Keller
authored
Merge pull request #155 from aj-ptw/master
v2.1.2
2 parents 7e7ccf3 + 0abebcd commit 2992d23

File tree

3 files changed

+12
-3
lines changed

3 files changed

+12
-3
lines changed

changelog.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,10 @@
1+
# 2.1.2
2+
3+
### Enhancements
4+
5+
* Update openbci-utilities to v0.1.2 to patch for sendCounts.
6+
* Disconnect did not disconnect from serial port if the device was not streaming.
7+
18
# 2.1.1
29

310
### Bug Fixes

openBCICyton.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -368,13 +368,15 @@ Cyton.prototype.disconnect = function () {
368368
if (this.isStreaming()) {
369369
if (this.options.verbose) console.log('stop streaming');
370370
return this.streamStop();
371+
} else {
372+
return Promise.resolve();
371373
}
372374
})
373375
.then(() => {
374376
if (!this.isConnected()) {
375377
return Promise.reject(Error('no board connected'));
376378
} else {
377-
return new Promise((resolve, reject) => {
379+
return new Promise((resolve) => {
378380
// serial emitting 'close' will call _disconnected
379381
this.serial.close(() => {
380382
resolve();

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "openbci",
3-
"version": "2.1.1",
3+
"version": "2.1.2",
44
"description": "The official Node.js SDK for the OpenBCI Biosensor Board.",
55
"main": "index.js",
66
"scripts": {
@@ -21,7 +21,7 @@
2121
"gaussian": "^1.0.0",
2222
"lodash": "^4.17.4",
2323
"mathjs": "^3.14.2",
24-
"openbci-utilities": "0.1.0",
24+
"openbci-utilities": "0.1.2",
2525
"performance-now": "^2.1.0",
2626
"safe-buffer": "^5.1.1",
2727
"serialport": "4.0.7",

0 commit comments

Comments
 (0)