Examples need to import the resources

This commit is contained in:
Henrik Tjäder 2020-05-26 10:48:24 +00:00
parent 46bf583cc2
commit dcc31fb884
5 changed files with 13 additions and 0 deletions

View file

@ -16,6 +16,10 @@ use panic_semihosting as _;
#[rtic::app(device = lm3s6965)]
mod app {
use heapless::{
consts::*,
spsc::{Consumer, Producer},
};
// Late resources
struct Resources {
p: Producer<'static, u32, U4>,

View file

@ -17,6 +17,8 @@ pub struct NotSend {
#[app(device = lm3s6965)]
mod app {
use super::NotSend;
struct Resources {
#[init(None)]
shared: Option<NotSend>,

View file

@ -16,6 +16,9 @@ pub struct NotSync {
#[rtic::app(device = lm3s6965)]
mod app {
use super::NotSync;
use core::marker::PhantomData;
struct Resources {
#[init(NotSync { _0: PhantomData })]
shared: NotSync,

View file

@ -14,6 +14,8 @@ pub struct MustBeSend;
#[app(device = lm3s6965)]
mod app {
use super::MustBeSend;
struct Resources {
#[init(None)]
shared: Option<MustBeSend>,

View file

@ -13,6 +13,8 @@ pub struct NotSend {
#[rtic::app(device = lm3s6965)]
mod app {
use super::NotSend;
struct Resources {
x: NotSend,
#[init(None)]