Skip to content

Instantly share code, notes, and snippets.

View mrameen's full-sized avatar

Mr Ameen mrameen

View GitHub Profile
@don
don / index.js
Created January 16, 2018 02:08
Break up large ArrayBuffer before writing to BLE characteristic
// Mock BLE so you can run example from nodejs
const ble = {
write: function(device_id, service, characteristic, buffer, success, failure) {
// log to console instead of writing
console.log('>>', new Uint8Array(buffer));
// always call success callback
success();
}
}