updated docs
This commit is contained in:
@ -1,23 +0,0 @@
|
||||
# microbit Reference
|
||||
|
||||
```namespaces
|
||||
basic.showNumber(0);
|
||||
input.onButtonPressed(Button.A, () => {
|
||||
|
||||
});
|
||||
led.plot(0, 0);
|
||||
music.playTone(0, 0);
|
||||
game.addScore(1);
|
||||
images.createImage(`
|
||||
. . . . .
|
||||
. . . . .
|
||||
. . # . .
|
||||
. . . . .
|
||||
. . . . .
|
||||
`);
|
||||
pins.digitalReadPin(DigitalPin.P0);
|
||||
serial.writeValue(x, 0);
|
||||
control.inBackground(() => {
|
||||
|
||||
});
|
||||
```
|
@ -8,8 +8,14 @@ pins.digitalWritePin(DigitalPin.P0, 0);
|
||||
pins.analogReadPin(AnalogPin.P0);
|
||||
pins.analogWritePin(AnalogPin.P0, 1023);
|
||||
pins.analogSetPeriod(AnalogPin.P0, 20000);
|
||||
pins.onPulsed(DigitalPin.P0, PulseValue.High, () => {
|
||||
|
||||
});
|
||||
pins.pulseDuration();
|
||||
pins.servoWritePin(AnalogPin.P0, 180);
|
||||
pins.servoSetPulse(AnalogPin.P0, 1500);
|
||||
pins.i2cReadNumber(0, NumberFormat.Int8LE);
|
||||
pins.i2cWriteNumber(0, 0, NumberFormat.Int8LE);
|
||||
pins.map(0, 0, 1023, 0, 4);
|
||||
pins.analogPitch(0, 0);
|
||||
pins.analogSetPitchPin(AnalogPin.P0);
|
||||
|
@ -4,13 +4,17 @@ Communicate data using radio packets
|
||||
|
||||
```cards
|
||||
radio.sendNumber(0);
|
||||
radio.sendNumbers(0, 0, 0, 0);
|
||||
radio.sendValue("data", 0);
|
||||
radio.sendString("");
|
||||
radio.onDataReceived(() => {
|
||||
|
||||
});
|
||||
radio.receiveNumber();
|
||||
radio.receivedNumberAt(0);
|
||||
radio.receiveString();
|
||||
radio.receivedSignalStrength();
|
||||
radio.setGroup(0);
|
||||
radio.setTransmitPower(0);
|
||||
radio.writeValueToSerial();
|
||||
radio.setTransmitSerialNumber(◊);
|
||||
```
|
||||
|
Reference in New Issue
Block a user