diff options
| author | bors[bot] <26634292+bors[bot]@users.noreply.github.com> | 2023-03-04 21:10:24 +0000 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2023-03-04 21:10:24 +0000 |
| commit | 7c7d6558f6d9c50fbb4d2487c98c9a5be15f2f7b (patch) | |
| tree | 80a47f0dc40059014e9448c4c2eb34c54dff45fe /ui | |
| parent | 1c5db277e4161470136dbd2a11e914ff1d383581 (diff) | |
| parent | 98c5490d94950608d31cd5ad9dd260f2f853735c (diff) | |
Merge #694
694: RTIC 2 r=AfoHT a=korken89
Co-authored-by: Emil Fresk <emil.fresk@gmail.com>
Co-authored-by: Per Lindgren <per.lindgren@ltu.se>
Diffstat (limited to 'ui')
| -rw-r--r-- | ui/exception-invalid.rs | 18 | ||||
| -rw-r--r-- | ui/exception-invalid.stderr | 5 | ||||
| -rw-r--r-- | ui/extern-interrupt-not-enough.rs | 18 | ||||
| -rw-r--r-- | ui/extern-interrupt-not-enough.stderr | 5 | ||||
| -rw-r--r-- | ui/extern-interrupt-used.rs | 18 | ||||
| -rw-r--r-- | ui/extern-interrupt-used.stderr | 5 | ||||
| -rw-r--r-- | ui/task-priority-too-high.rs | 44 | ||||
| -rw-r--r-- | ui/task-priority-too-high.stderr | 7 | ||||
| -rw-r--r-- | ui/unknown-interrupt.rs | 15 | ||||
| -rw-r--r-- | ui/unknown-interrupt.stderr | 5 | ||||
| -rw-r--r-- | ui/v6m-interrupt-not-enough.rs_no | 54 |
11 files changed, 0 insertions, 194 deletions
diff --git a/ui/exception-invalid.rs b/ui/exception-invalid.rs deleted file mode 100644 index 07d3c21..0000000 --- a/ui/exception-invalid.rs +++ /dev/null @@ -1,18 +0,0 @@ -#![no_main] - -#[rtic::app(device = lm3s6965)] -mod app { - #[shared] - struct Shared {} - - #[local] - struct Local {} - - #[init] - fn init(cx: init::Context) -> (Shared, Local, init::Monotonics) { - (Shared {}, Local {}, init::Monotonics()) - } - - #[task(binds = NonMaskableInt)] - fn nmi(_: nmi::Context) {} -} diff --git a/ui/exception-invalid.stderr b/ui/exception-invalid.stderr deleted file mode 100644 index 3212368..0000000 --- a/ui/exception-invalid.stderr +++ /dev/null @@ -1,5 +0,0 @@ -error: only exceptions with configurable priority can be used as hardware tasks - --> $DIR/exception-invalid.rs:17:8 - | -17 | fn nmi(_: nmi::Context) {} - | ^^^ diff --git a/ui/extern-interrupt-not-enough.rs b/ui/extern-interrupt-not-enough.rs deleted file mode 100644 index 1dbe923..0000000 --- a/ui/extern-interrupt-not-enough.rs +++ /dev/null @@ -1,18 +0,0 @@ -#![no_main] - -#[rtic::app(device = lm3s6965)] -mod app { - #[shared] - struct Shared {} - - #[local] - struct Local {} - - #[init] - fn init(cx: init::Context) -> (Shared, Local, init::Monotonics) { - (Shared {}, Local {}, init::Monotonics()) - } - - #[task] - fn a(_: a::Context) {} -} diff --git a/ui/extern-interrupt-not-enough.stderr b/ui/extern-interrupt-not-enough.stderr deleted file mode 100644 index a667c58..0000000 --- a/ui/extern-interrupt-not-enough.stderr +++ /dev/null @@ -1,5 +0,0 @@ -error: not enough interrupts to dispatch all software tasks (need: 1; given: 0) - --> $DIR/extern-interrupt-not-enough.rs:17:8 - | -17 | fn a(_: a::Context) {} - | ^ diff --git a/ui/extern-interrupt-used.rs b/ui/extern-interrupt-used.rs deleted file mode 100644 index 882d5e3..0000000 --- a/ui/extern-interrupt-used.rs +++ /dev/null @@ -1,18 +0,0 @@ -#![no_main] - -#[rtic::app(device = lm3s6965, dispatchers = [UART0])] -mod app { - #[shared] - struct Shared {} - - #[local] - struct Local {} - - #[init] - fn init(cx: init::Context) -> (Shared, Local, init::Monotonics) { - (Shared {}, Local {}, init::Monotonics()) - } - - #[task(binds = UART0)] - fn a(_: a::Context) {} -} diff --git a/ui/extern-interrupt-used.stderr b/ui/extern-interrupt-used.stderr deleted file mode 100644 index 7565739..0000000 --- a/ui/extern-interrupt-used.stderr +++ /dev/null @@ -1,5 +0,0 @@ -error: dispatcher interrupts can't be used as hardware tasks - --> $DIR/extern-interrupt-used.rs:16:20 - | -16 | #[task(binds = UART0)] - | ^^^^^ diff --git a/ui/task-priority-too-high.rs b/ui/task-priority-too-high.rs deleted file mode 100644 index e7e0cce..0000000 --- a/ui/task-priority-too-high.rs +++ /dev/null @@ -1,44 +0,0 @@ -#![no_main] - -#[rtic::app(device = lm3s6965)] -mod app { - #[shared] - struct Shared {} - - #[local] - struct Local {} - - #[init] - fn init(_: init::Context) -> (Shared, Local, init::Monotonics) { - (Shared {}, Local {}, init::Monotonics()) - } - - #[task(binds = GPIOA, priority = 1)] - fn gpioa(_: gpioa::Context) {} - - #[task(binds = GPIOB, priority = 2)] - fn gpiob(_: gpiob::Context) {} - - #[task(binds = GPIOC, priority = 3)] - fn gpioc(_: gpioc::Context) {} - - #[task(binds = GPIOD, priority = 4)] - fn gpiod(_: gpiod::Context) {} - - #[task(binds = GPIOE, priority = 5)] - fn gpioe(_: gpioe::Context) {} - - #[task(binds = UART0, priority = 6)] - fn uart0(_: uart0::Context) {} - - #[task(binds = UART1, priority = 7)] - fn uart1(_: uart1::Context) {} - - // OK, this is the maximum priority supported by the device - #[task(binds = SSI0, priority = 8)] - fn ssi0(_: ssi0::Context) {} - - // this value is too high! - #[task(binds = I2C0, priority = 9)] - fn i2c0(_: i2c0::Context) {} -} diff --git a/ui/task-priority-too-high.stderr b/ui/task-priority-too-high.stderr deleted file mode 100644 index 026124c..0000000 --- a/ui/task-priority-too-high.stderr +++ /dev/null @@ -1,7 +0,0 @@ -error[E0080]: evaluation of constant value failed - --> ui/task-priority-too-high.rs:3:1 - | -3 | #[rtic::app(device = lm3s6965)] - | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the evaluated program panicked at 'Maximum priority used by interrupt vector 'I2C0' is more than supported by hardware', $DIR/ui/task-priority-too-high.rs:3:1 - | - = note: this error originates in the macro `$crate::panic::panic_2021` which comes from the expansion of the macro `::core::panic` (in Nightly builds, run with -Z macro-backtrace for more info) diff --git a/ui/unknown-interrupt.rs b/ui/unknown-interrupt.rs deleted file mode 100644 index f2bc629..0000000 --- a/ui/unknown-interrupt.rs +++ /dev/null @@ -1,15 +0,0 @@ -#![no_main] - -#[rtic::app(device = lm3s6965, dispatchers = [UnknownInterrupt])] -mod app { - #[shared] - struct Shared {} - - #[local] - struct Local {} - - #[init] - fn init(cx: init::Context) -> (Shared, Local, init::Monotonics) { - (Shared {}, Local {}, init::Monotonics()) - } -} diff --git a/ui/unknown-interrupt.stderr b/ui/unknown-interrupt.stderr deleted file mode 100644 index c7d3269..0000000 --- a/ui/unknown-interrupt.stderr +++ /dev/null @@ -1,5 +0,0 @@ -error[E0599]: no variant or associated item named `UnknownInterrupt` found for enum `Interrupt` in the current scope - --> $DIR/unknown-interrupt.rs:3:47 - | -3 | #[rtic::app(device = lm3s6965, dispatchers = [UnknownInterrupt])] - | ^^^^^^^^^^^^^^^^ variant or associated item not found in `Interrupt` diff --git a/ui/v6m-interrupt-not-enough.rs_no b/ui/v6m-interrupt-not-enough.rs_no deleted file mode 100644 index 3fbf3cf..0000000 --- a/ui/v6m-interrupt-not-enough.rs_no +++ /dev/null @@ -1,54 +0,0 @@ -//! v6m-interrupt-not-enough.rs_no (not run atm) -//! -//! Expected behavior: -//! should pass -//! > cargo build --example m0_perf_err --target thumbv7m-none-eabi --release -//! -//! should fail -//! > cargo build --example m0_perf_err --target thumbv6m-none-eabi --release -//! Compiling cortex-m-rtic v1.0.0 (/home/pln/rust/rtic/cortex-m-rtic) -//! error[E0308]: mismatched types -//! --> examples/m0_perf_err.rs:25:1 -//! | -//! 25 | #[rtic::app(device = lm3s6965)] -//! | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ expected an array with a fixed size of 4 elements, found one with 5 elements -//! | -//! = note: this error originates in the attribute macro `rtic::app` (in Nightly builds, run with -Z macro-backtrace for more info) - -#![deny(unsafe_code)] -#![deny(warnings)] -#![no_main] -#![no_std] - -use panic_semihosting as _; - -#[rtic::app(device = lm3s6965)] -mod app { - - use cortex_m_semihosting::debug; - - #[shared] - struct Shared {} - - #[local] - struct Local {} - - #[init] - fn init(_: init::Context) -> (Shared, Local, init::Monotonics) { - (Shared {}, Local {}, init::Monotonics()) - } - - #[inline(never)] - #[idle] - fn idle(_cx: idle::Context) -> ! { - debug::exit(debug::EXIT_SUCCESS); // Exit QEMU simulator - - loop { - cortex_m::asm::nop(); - } - } - - // priority to high for v6m - #[task(binds = GPIOA, priority = 5)] - fn t0(_cx: t0::Context) {} -} |
