2016-05-17 07:18:58 +02:00
{
"radio" : "Communicate data using radio packets" ,
"radio.onDataReceived" : "Registers code to run when a packet is received over radio." ,
2016-07-26 17:47:45 +02:00
"radio.onDataReceived|block" : "on data received" ,
2016-05-17 07:18:58 +02:00
"radio.receiveNumber" : "Reads the next packet as a number from the radio queue." ,
2016-07-26 17:47:45 +02:00
"radio.receiveNumber|block" : "receive number" ,
2016-05-17 07:18:58 +02:00
"radio.receiveString" : "Reads the next packet as a string and returns it." ,
2016-07-26 17:47:45 +02:00
"radio.receiveString|block" : "receive string" ,
2016-05-17 07:18:58 +02:00
"radio.receivedNumberAt" : "Reads a number at a given index, between ``0`` and ``3``, from the packet received by ``receive number``. Not supported in simulator." ,
2016-07-26 17:47:45 +02:00
"radio.receivedNumberAt|block" : "receive number|at %VALUE" ,
"radio.receivedNumberAt|param|index" : "index of the number to read from 0 to 3. 1 eg" ,
2016-05-17 07:18:58 +02:00
"radio.receivedSignalStrength" : "Gets the received signal strength indicator (RSSI) from the packet received by ``receive number``. Not supported in simulator.\nnamespace=radio" ,
2016-07-26 17:47:45 +02:00
"radio.receivedSignalStrength|block" : "received signal strength" ,
2016-05-17 07:18:58 +02:00
"radio.sendNumber" : "Broadcasts a number over radio to any connected micro:bit in the group." ,
2016-07-26 17:47:45 +02:00
"radio.sendNumber|block" : "send number %value" ,
2016-05-17 07:18:58 +02:00
"radio.sendString" : "Broadcasts a number over radio to any connected micro:bit in the group." ,
2016-07-26 17:47:45 +02:00
"radio.sendString|block" : "send string %msg" ,
2016-05-17 07:18:58 +02:00
"radio.sendValue" : "Broadcasts a name / value pair along with the device serial number\nand running time to any connected BBC micro:bit in the group." ,
2016-07-26 17:47:45 +02:00
"radio.sendValue|block" : "send|value %name|= %value" ,
"radio.sendValue|param|name" : "the field name (max 12 characters), eg: \"data\"" ,
"radio.sendValue|param|value" : "the numberic value" ,
2016-05-17 07:18:58 +02:00
"radio.setGroup" : "Sets the group id for radio communications. A micro:bit can only listen to one group ID at any time.\n@ param id the group id between ``0`` and ``255``, 1 eg" ,
2016-07-26 17:47:45 +02:00
"radio.setGroup|block" : "set group %ID" ,
2016-05-17 07:18:58 +02:00
"radio.setTransmitPower" : "Change the output power level of the transmitter to the given value." ,
2016-07-26 17:47:45 +02:00
"radio.setTransmitPower|block" : "set transmit power %power" ,
"radio.setTransmitPower|param|power" : "a value in the range 0..7, where 0 is the lowest power and 7 is the highest. eg: 7" ,
2016-05-17 07:18:58 +02:00
"radio.setTransmitSerialNumber" : "Set the radio to transmit the serial number in each message." ,
2016-07-26 17:47:45 +02:00
"radio.setTransmitSerialNumber|block" : "set tranmist serial number %transmit" ,
2016-05-17 07:18:58 +02:00
"radio.writeValueToSerial" : "Reads a value sent with `stream value` and writes it\nto the serial stream as JSON" ,
2016-07-26 17:47:45 +02:00
"radio.writeValueToSerial|block" : "write value to serial" ,
"radio|block" : "radio"
2016-05-17 07:18:58 +02:00
}