aboutsummaryrefslogtreecommitdiff
path: root/examples/not-send.rs
diff options
context:
space:
mode:
authorGravatar Danilo Bargen <mail@dbrgn.ch> 2020-06-26 23:46:09 +0200
committerGravatar Danilo Bargen <mail@dbrgn.ch> 2020-06-26 23:53:11 +0200
commit8e636f0d1286cf905518022d42adf9624bed44df (patch)
tree403f42f246a9a0f4550af2f955912e4c49c92b57 /examples/not-send.rs
parent8a4f9c6b8ae91bebeea0791680f89375a78bffc6 (diff)
downloadrtic-8e636f0d1286cf905518022d42adf9624bed44df.tar.gz
rtic-8e636f0d1286cf905518022d42adf9624bed44df.tar.zst
rtic-8e636f0d1286cf905518022d42adf9624bed44df.zip
Examples: Clarify extern section
Some beginners are confused about the "extern" section, so I added an explanation comment to all examples. Furthermore, using the UARTx interrupts when UART is actually being used in the same example may be confusing, so I changed them all to SSI0/QEI0.
Diffstat (limited to 'examples/not-send.rs')
-rw-r--r--examples/not-send.rs7
1 files changed, 5 insertions, 2 deletions
diff --git a/examples/not-send.rs b/examples/not-send.rs
index fc2196c2..16a874dc 100644
--- a/examples/not-send.rs
+++ b/examples/not-send.rs
@@ -53,8 +53,11 @@ const APP: () = {
debug::exit(debug::EXIT_SUCCESS);
}
+ // RTIC requires that unused interrupts are declared in an extern block when
+ // using software tasks; these free interrupts will be used to dispatch the
+ // software tasks.
extern "C" {
- fn UART0();
- fn UART1();
+ fn SSI0();
+ fn QEI0();
}
};