fix(bsp)
This commit is contained in:
parent
726632a35a
commit
8dda09689d
6 changed files with 67 additions and 9 deletions
12
src/main.rs
12
src/main.rs
|
|
@ -14,6 +14,16 @@ mod time;
|
|||
use energy::EnergyStatus;
|
||||
use state::*;
|
||||
|
||||
cfg_if::cfg_if! {
|
||||
if #[cfg(not(feature = "simulator"))] {
|
||||
use maduino_zero_4g as bsp;
|
||||
use bsp::hal;
|
||||
|
||||
use hal::pac::{CorePeripherals, Peripherals};
|
||||
use hal::prelude::*;
|
||||
}
|
||||
}
|
||||
|
||||
use arrayvec::ArrayString;
|
||||
use core::fmt::Write;
|
||||
use embedded_graphics::{
|
||||
|
|
@ -50,7 +60,7 @@ fn state_mut() -> &'static mut State {
|
|||
unsafe { &mut STATE }
|
||||
}
|
||||
|
||||
#[cfg_attr(not(feature = "simulator"), cortex_m_rt::entry)]
|
||||
#[cfg_attr(not(feature = "simulator"), bsp::entry)]
|
||||
fn main() -> ! {
|
||||
let mut display = display::Display::new();
|
||||
let mut keypad = keypad::Keypad::default();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue