mirror of
https://github.com/thegecko/web-bluetooth-dfu.git
synced 2025-12-13 04:28:13 +08:00
Use the CRC we generate for the image in the init packet.
This commit is contained in:
3
dist/dfu.js
vendored
3
dist/dfu.js
vendored
@@ -162,10 +162,11 @@
|
||||
return view;
|
||||
}
|
||||
|
||||
function provision(device, arrayBuffer, imageType) {
|
||||
function provision(device, arrayBuffer, imageType, crc) {
|
||||
return new Promise(function(resolve, reject) {
|
||||
var versionChar = null;
|
||||
imageType = imageType || ImageType.Application;
|
||||
initPacket.crc = crc;
|
||||
|
||||
connect(device)
|
||||
.then(function(chars) {
|
||||
|
||||
Reference in New Issue
Block a user