BLE UART Buffer methods (#1353)
* adding simulator * attempt at handling size * correct ref counting * defense is on * handle read < 0
This commit is contained in:
12
libs/bluetooth/shims.d.ts
vendored
12
libs/bluetooth/shims.d.ts
vendored
@ -63,6 +63,18 @@ declare namespace bluetooth {
|
||||
//% parts="bluetooth" advanced=true shim=bluetooth::startUartService
|
||||
function startUartService(): void;
|
||||
|
||||
/**
|
||||
* Sends a buffer of data via Bluetooth UART
|
||||
*/
|
||||
//% shim=bluetooth::uartWriteBuffer
|
||||
function uartWriteBuffer(buffer: Buffer): void;
|
||||
|
||||
/**
|
||||
* Reads buffered UART data into a buffer
|
||||
*/
|
||||
//% shim=bluetooth::uartReadBuffer
|
||||
function uartReadBuffer(): Buffer;
|
||||
|
||||
/**
|
||||
* Registers an event to be fired when one of the delimiter is matched.
|
||||
* @param delimiters the characters to match received characters against.
|
||||
|
Reference in New Issue
Block a user