document the binds feature

cc @burrbull
This commit is contained in:
Jorge Aparicio 2019-02-23 22:21:30 +01:00
parent 11f795aaf6
commit e167af01f0

View file

@ -75,3 +75,19 @@ $ cargo nm --example ramfunc --release | grep ' foo::'
``` console ``` console
$ cargo nm --example ramfunc --release | grep ' bar::' $ cargo nm --example ramfunc --release | grep ' bar::'
{{#include ../../../../ci/expected/ramfunc.grep.bar}}``` {{#include ../../../../ci/expected/ramfunc.grep.bar}}```
## `binds`
**NOTE**: Requires RTFM ~0.4.2
You can give hardware tasks more task-like names using the `binds` argument: you
name the function as you wish and specify the name of the interrupt / exception
in the `binds` argument. Types like `Spawn` will be placed in a module named
after the function, not the interrupt / exception. Example below:
``` rust
{{#include ../../../../examples/binds.rs}}
```
``` console
$ cargo run --example binds
{{#include ../../../../ci/expected/binds.run}}```