2016-04-03 02:47:49 +02:00
|
|
|
// Auto-generated. Do not edit.
|
|
|
|
|
|
|
|
|
2016-06-21 20:17:34 +02:00
|
|
|
/**
|
|
|
|
* Control a phone with the BBC micro:bit via Bluetooth.
|
|
|
|
*/
|
2019-12-02 05:58:26 +01:00
|
|
|
//% color=#008272 weight=80 icon="\uf10b"
|
2016-04-03 02:47:49 +02:00
|
|
|
declare namespace devices {
|
|
|
|
|
2016-03-10 23:01:04 +01:00
|
|
|
/**
|
|
|
|
* Returns the last signal strength reported by the paired device.
|
|
|
|
*/
|
2016-04-03 02:47:49 +02:00
|
|
|
//% help=devices/signal-strength weight=24
|
|
|
|
//% blockId=devices_signal_strength block="signal strength" blockGap=14 icon="\uf012" blockGap=14 shim=devices::signalStrength
|
2019-12-02 05:58:26 +01:00
|
|
|
function signalStrength(): int32;
|
2016-03-10 23:01:04 +01:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Registers code to run when the device notifies about a change of signal strength.
|
2016-06-14 15:30:07 +02:00
|
|
|
* @param body Code run when the signal strength changes.
|
2016-03-10 23:01:04 +01:00
|
|
|
*/
|
2016-04-03 03:09:31 +02:00
|
|
|
//% weight=23 help=devices/on-signal-strength-changed
|
2016-04-03 02:47:49 +02:00
|
|
|
//% blockId=devices_signal_strength_changed_event block="on signal strength changed" icon="\uf012" shim=devices::onSignalStrengthChanged
|
|
|
|
function onSignalStrengthChanged(body: () => void): void;
|
2016-03-10 23:01:04 +01:00
|
|
|
}
|
|
|
|
|
2016-04-03 02:47:49 +02:00
|
|
|
// Auto-generated. Do not edit. Really.
|