aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2020-10-23Merge #399bors[bot]
399: Now all locks are symmetric r=AfoHT a=korken89 Co-authored-by: Emil Fresk <emil.fresk@gmail.com>
2020-10-23Now all locks are symmetricEmil Fresk
Test fixes Fix test Fix comment
2020-10-22Merge #398bors[bot]
398: Add the cfgs on a task to the module for that task r=korken89 a=AfoHT Applying a `#[cfg(never)]` on a task: before: ``` #[allow(non_snake_case)] #[doc = "Software task"] pub mod foo2 { #[doc(inline)] pub use super::foo2Resources as Resources; #[doc = r" Execution context"] pub struct Context<'a> { #[doc = r" Resources this task has access to"] pub resources: Resources<'a>, } impl<'a> Context<'a> { #[inline(always)] pub unsafe fn new(priority: &'a rtic::export::Priority) -> Self { Context { resources: Resources::new(priority), } } } <...> ``` After: ``` #[allow(non_snake_case)] #[cfg(never)] #[doc = "Software task"] pub mod foo2 { #[doc(inline)] pub use super::foo2Resources as Resources; #[doc = r" Execution context"] pub struct Context<'a> { #[doc = r" Resources this task has access to"] pub resources: Resources<'a>, } impl<'a> Context<'a> { #[inline(always)] pub unsafe fn new(priority: &'a rtic::export::Priority) -> Self { Context { resources: Resources::new(priority), } } } <...> ``` Co-authored-by: Henrik Tjäder <henrik@tjaders.com>
2020-10-22Add the cfgs on a task to the module for that taskHenrik Tjäder
2020-10-22Merge #396bors[bot]
396: Fix namespaces r=AfoHT a=korken89 Co-authored-by: Emil Fresk <emil.fresk@gmail.com>
2020-10-22Fix UI testsEmil Fresk
Fix
2020-10-21Hide lock type better to not collide with user typesEmil Fresk
2020-10-21Namespace cleanupEmil Fresk
2020-10-21Updated examplesEmil Fresk
More work
2020-10-15Merge #397bors[bot]
397: Use latest GHA mdBook action r=korken89 a=AfoHT Co-authored-by: Henrik Tjäder <henrik@tjaders.com>
2020-10-15Use latest GHA mdBook actionHenrik Tjäder
2020-10-15Merge #393bors[bot]
393: Implement all clippy suggestions r=korken89 a=AfoHT Co-authored-by: Henrik Tjäder <henrik@tjaders.com>
2020-10-15Implement all clippy suggestionsHenrik Tjäder
2020-10-15Merge #390bors[bot]
390: Spawn and schedule from anywhere r=AfoHT a=korken89 This PR moves RTIC to the spawn and schedule from anywhere syntax. Notable changes: * We do no longer support non-`Send` types. * Some extra code is generated as any task may spawn/schedule any task. However Rust/LLVM does a great job optimizing away non used instantiations (no real code-size difference observed). * Worst case priority inversion has increased, but it is now predictable. Upsides: * With this we should be able to support async/await. * RTIC tasks can now be callbacks (spawned and scheduled). * RTIC tasks can be stored. Needs the following PR to land first: https://github.com/rtic-rs/rtic-syntax/pull/34 The following now works: ```rust #[rtic::app(device = lm3s6965, monotonic = rtic::cyccnt::CYCCNT)] mod app { #[init] fn init(mut cx: init::Context) -> init::LateResources { // Init stuff... // New spawn syntax foo::spawn().unwrap(); // New schedule syntax bar::schedule(now + 4_000_000.cycles()).unwrap(); init::LateResources {} } #[task] fn foo(_: foo::Context) {} #[task] fn bar(_: bar::Context) {} extern "C" { fn SSI0(); } } ``` Co-authored-by: Per Lindgren <per.lindgren@ltu.se> Co-authored-by: Emil Fresk <emil.fresk@gmail.com>
2020-10-15Merge branch 'master' into spawn_experimentEmil Fresk
2020-10-15Use master branch on syntaxEmil Fresk
2020-10-15Fix comments in examplesEmil Fresk
2020-10-15Merge #395bors[bot]
395: Made relation between priority and number explicit r=korken89 a=diondokter When quickly reading through the priorities chapter, I couldn't find in which order the priorities were, so I assumed it was the same as in the hardware. In the cortex-m hardware, interrupts with the **lower** priority number will preempt the other interrupts. RTIC does the reverse, so I think it's good to be more explicit about it. Co-authored-by: Dion Dokter <diondokter@gmail.com>
2020-10-15Merge #371bors[bot]
371: task_local and lock_free r=korken89 a=AfoHT Getting this going to test with GHA For further discussion see https://github.com/rtic-rs/rfcs/issues/30 Co-authored-by: Per <Per Lindgren> Co-authored-by: Henrik Tjäder <henrik@tjaders.com>
2020-10-15Updated syntax crateEmil Fresk
2020-10-15Create Enum containing all tasksHenrik Tjäder
2020-10-15Changed branch for rtic-syntaxHenrik Tjäder
2020-10-15Updated examples and rtic-nameHenrik Tjäder
2020-10-15Add example with features on all resources combined with lock_free and ↵Henrik Tjäder
task_local
2020-10-15Print module name and priorityHenrik Tjäder
2020-10-15task_local and lock_free analysis (take 1)Per
2020-10-15Merge branch 'master' into spawn_experimentEmil Fresk
2020-10-15Made relation between priority and number explicitDion Dokter
When quickly reading through the priorities chapter, I couldn't find in which order the priorities were, so I assumed it was the same as in the hardware. In the cortex-m hardware, interrupts with the **lower** priority number will preempt the other interrupts. RTIC does the reverse, so I think it's good to be more explicit about it.
2020-10-15Merge #394bors[bot]
394: Detect if the rt flag is defined in the PAC/HAL r=AfoHT a=korken89 This stops RTIC applications from compiling if one has forgotten to set the `rt` flag in the PAC/HAL. The error: ``` error[E0433]: failed to resolve: could not find `interrupt` in `you_must_enable_the_rt_feature_for_the_pac_in_your_cargo_toml` --> src/main.rs:8:1 | 8 | #[rtic::app(device = stm32l4xx_hal::pac)] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ could not find `interrupt` in `you_must_enable_the_rt_feature_for_the_pac_in_your_cargo_toml` | = note: this error originates in an attribute macro (in Nightly builds, run with -Z macro-backtrace for more info) ``` Co-authored-by: Emil Fresk <emil.fresk@gmail.com>
2020-10-15Detect if the rt flag is defined in the PAC/HALEmil Fresk
Better error message Improved error string Update UI tests
2020-10-13Merge #392bors[bot]
392: device path must be absolute; clarify r=AfoHT a=dcarosone feel free to nitpick path terminology Co-authored-by: Daniel Carosone <Daniel.Carosone@gmail.com>
2020-10-13device path must be absolute; clarifyDaniel Carosone
2020-10-12Merge #388bors[bot]
388: Now core contains the same `Peripherals` type based on monotonic r=AfoHT a=korken89 Co-authored-by: Emil Fresk <emil.fresk@gmail.com>
2020-10-12UI fixEmil Fresk
2020-10-11Fixing examples and tests, modules now import user imports correctlyEmil Fresk
Fmt Correct syntax crate UI test fix Fix build script Cleanup More cleanup
2020-10-11Now with spawn/schedule from anywhereEmil Fresk
2020-10-08Merge branch 'master' into spawn_experimentEmil Fresk
2020-10-08Added critical sectionsEmil Fresk
2020-10-07Now core contains the same `Peripherals` type based on monotonicEmil Fresk
2020-10-07Merge #384bors[bot]
384: Fix MD-lints, add Matrix and meeting notes badges r=korken89 a=AfoHT Co-authored-by: Henrik Tjäder <henrik@tjaders.com>
2020-10-07Merge #385bors[bot]
385: Doclints r=korken89 a=dcarosone Some minor doc lints and wording cleanup Co-authored-by: Daniel Carosone <Daniel.Carosone@gmail.com>
2020-10-07minor md lints and wording clarificationDaniel Carosone
2020-10-07Merge branch 'master'Daniel Carosone
of https://github.com/rtic-rs/cortex-m-rtic
2020-10-06Fix MD-lints, add Matrix and meeting notes badgesHenrik Tjäder
2020-10-06Merge #173bors[bot]
173: add sandbox example r=AfoHT a=etrombly Added a real world example for my sandbox project. Co-authored-by: Eric Trombly <etrombly@yahoo.com>
2020-10-06Merge #346bors[bot]
346: fix badges / clean up README r=AfoHT a=fuchsnj Co-authored-by: Nathan Fox <fuchsnj@gmail.com> Co-authored-by: Henrik Tjäder <henrik@tjaders.com>
2020-10-06Restore links to docsHenrik Tjäder
2020-10-05spawn examples updatedPer Lindgren
2020-10-05spawn POC works, likely unsound, cleanupPer Lindgren
2020-10-05spawn POC works, likely unsoundPer Lindgren