(1.0.29) bump
This commit is contained in:
6
dist/index.cjs.js
vendored
6
dist/index.cjs.js
vendored
@@ -201,8 +201,8 @@ class Updater {
|
|||||||
// write file length
|
// write file length
|
||||||
return new Promise(async (resolve, reject) => {
|
return new Promise(async (resolve, reject) => {
|
||||||
// set mtu
|
// set mtu
|
||||||
this._packetSize = await this.bleObject.withPromises.requestMtu(this.bleDeviceId, this._packetSize);
|
this.bleObject.requestMtu(this.bleDeviceId, this._packetSize, (mtu) => {
|
||||||
// start notify
|
this._packetSize = mtu;
|
||||||
this.bleObject.startNotification(this.bleDeviceId, this._updaterServiceUUID, this._updaterCommandCharacterisitcUUID, (rawData) => {
|
this.bleObject.startNotification(this.bleDeviceId, this._updaterServiceUUID, this._updaterCommandCharacterisitcUUID, (rawData) => {
|
||||||
let dataView = new Uint8Array(rawData);
|
let dataView = new Uint8Array(rawData);
|
||||||
console.log(dataView);
|
console.log(dataView);
|
||||||
@@ -257,6 +257,8 @@ class Updater {
|
|||||||
view[0] = this._fileSize;
|
view[0] = this._fileSize;
|
||||||
this.bleObject.withPromises.write(this.bleDeviceId, this._updaterServiceUUID, this._updaterCommandCharacterisitcUUID, buffer);
|
this.bleObject.withPromises.write(this.bleDeviceId, this._updaterServiceUUID, this._updaterCommandCharacterisitcUUID, buffer);
|
||||||
});
|
});
|
||||||
|
// start notify
|
||||||
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
6
dist/index.es.js
vendored
6
dist/index.es.js
vendored
@@ -199,8 +199,8 @@ class Updater {
|
|||||||
// write file length
|
// write file length
|
||||||
return new Promise(async (resolve, reject) => {
|
return new Promise(async (resolve, reject) => {
|
||||||
// set mtu
|
// set mtu
|
||||||
this._packetSize = await this.bleObject.withPromises.requestMtu(this.bleDeviceId, this._packetSize);
|
this.bleObject.requestMtu(this.bleDeviceId, this._packetSize, (mtu) => {
|
||||||
// start notify
|
this._packetSize = mtu;
|
||||||
this.bleObject.startNotification(this.bleDeviceId, this._updaterServiceUUID, this._updaterCommandCharacterisitcUUID, (rawData) => {
|
this.bleObject.startNotification(this.bleDeviceId, this._updaterServiceUUID, this._updaterCommandCharacterisitcUUID, (rawData) => {
|
||||||
let dataView = new Uint8Array(rawData);
|
let dataView = new Uint8Array(rawData);
|
||||||
console.log(dataView);
|
console.log(dataView);
|
||||||
@@ -255,6 +255,8 @@ class Updater {
|
|||||||
view[0] = this._fileSize;
|
view[0] = this._fileSize;
|
||||||
this.bleObject.withPromises.write(this.bleDeviceId, this._updaterServiceUUID, this._updaterCommandCharacterisitcUUID, buffer);
|
this.bleObject.withPromises.write(this.bleDeviceId, this._updaterServiceUUID, this._updaterCommandCharacterisitcUUID, buffer);
|
||||||
});
|
});
|
||||||
|
// start notify
|
||||||
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "updaterweblibrary",
|
"name": "updaterweblibrary",
|
||||||
"version": "1.0.28",
|
"version": "1.0.29",
|
||||||
"description": "OTA Updater App frontend library",
|
"description": "OTA Updater App frontend library",
|
||||||
"repository": {
|
"repository": {
|
||||||
"type": "git",
|
"type": "git",
|
||||||
|
|||||||
Reference in New Issue
Block a user