Merge pull request #20 from mjdietzx/patch-1

Make gattServer a global variable to fix https://github.com/thegecko/…
This commit is contained in:
Rob Moran
2016-03-22 18:31:26 +00:00

4
dist/dfu.js vendored
View File

@@ -43,6 +43,8 @@
}
}(this, function(Promise, bluetooth, crc16) {
"use strict";
var server; // Make server a global variable (initialized in connect(). This fixes a bug in BlueZ that causes transfers to stall.
var LITTLE_ENDIAN = true;
@@ -209,7 +211,7 @@
function connect(device) {
return new Promise(function(resolve, reject) {
var server = null;
//var server = null;
var service = null;
var controlChar = null;
var packetChar = null;