aboutsummaryrefslogtreecommitdiff
path: root/examples/resource.rs
diff options
context:
space:
mode:
Diffstat (limited to 'examples/resource.rs')
-rw-r--r--examples/resource.rs8
1 files changed, 4 insertions, 4 deletions
diff --git a/examples/resource.rs b/examples/resource.rs
index 82689504..661f8c35 100644
--- a/examples/resource.rs
+++ b/examples/resource.rs
@@ -31,16 +31,16 @@ const APP: () = {
}
// `SHARED` can be access from this context
- #[interrupt(resources = [SHARED])]
- fn UART0(c: UART0::Context) {
+ #[task(binds = UART0, resources = [SHARED])]
+ fn uart0(c: uart0::Context) {
*c.resources.SHARED += 1;
hprintln!("UART0: SHARED = {}", c.resources.SHARED).unwrap();
}
// `SHARED` can be access from this context
- #[interrupt(resources = [SHARED])]
- fn UART1(c: UART1::Context) {
+ #[task(binds = UART1, resources = [SHARED])]
+ fn uart1(c: uart1::Context) {
*c.resources.SHARED += 1;
hprintln!("UART1: SHARED = {}", c.resources.SHARED).unwrap();