Update the the connect code for 'inchworm' (#1545)

This commit is contained in:
Galen Nickel 2018-10-26 21:00:58 -07:00 committed by Peli de Halleux
parent 5855b1f384
commit 53e447c33c

View File

@ -11,7 +11,7 @@ Remote control your inchworm with another @boardname@
You will need one more @boardname@ for this part. By using the radio, we can control the inchworm with another @boardname@. Download the code below to the @boardname@ on the inchworm and then again onto a "controller" @boardname@. Whenever button **A** is pressed, the inchworm moves once.
```blocks
radio.onReceivedNumber(({ receivedNumber }) => {
radio.onReceivedNumber(function (receivedNumber: number) {
pins.servoWritePin(AnalogPin.P0, 0)
basic.pause(500)
pins.servoWritePin(AnalogPin.P0, 180)