Melody events (#391)

* support for custom playTone

* added music.onEvent, music.setPlayTone

* updated docs

* updated sample
This commit is contained in:
Peli de Halleux
2017-04-25 10:14:34 -07:00
committed by GitHub
parent 53ddd4485d
commit 54ae7a4fda
7 changed files with 178 additions and 13 deletions

View File

@ -2,10 +2,12 @@
Play a musical tone through pin ``P0`` of the @boardname@ for as long as you say.
## Simulator
### ~ hint
This function only works on the @boardname@ and in some browsers.
### ~
```sig
music.playTone(440, 120)
```