remove SystemState from main
This commit is contained in:
parent
e1943accd2
commit
9e34e77e95
1 changed files with 1 additions and 14 deletions
|
|
@ -15,7 +15,7 @@ use synthesizer::AppSynthesizers;
|
||||||
|
|
||||||
mod app;
|
mod app;
|
||||||
use app::{
|
use app::{
|
||||||
sequencer::BasicSequence, App, Config, Interfaces, Sequences, Services, State, TimerConfig,
|
App, Config, Interfaces, Sequences, Services, State, TimerConfig, sequencer::BasicSequence,
|
||||||
};
|
};
|
||||||
|
|
||||||
use ch32_hal::{adc::AdcChannel, interrupt::typelevel::Handler, timer::low_level::OutputPolarity};
|
use ch32_hal::{adc::AdcChannel, interrupt::typelevel::Handler, timer::low_level::OutputPolarity};
|
||||||
|
|
@ -99,19 +99,6 @@ impl<'a> DebouncedGPIO<'a> {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// DeepSleep --coin button irq--> Active
|
|
||||||
// Active --2s button--> Idle
|
|
||||||
// Idle/Active --5s button--> DeepSleep
|
|
||||||
|
|
||||||
pub enum SystemState {
|
|
||||||
// system is asleep, waiting for wake from coin insertion
|
|
||||||
DeepSleep,
|
|
||||||
// system is in low-power mode, dimmed lights, waiting for interaction
|
|
||||||
Idle,
|
|
||||||
// system is active. on entry: play coin sound. on button press: play different sound
|
|
||||||
Active,
|
|
||||||
}
|
|
||||||
|
|
||||||
#[derive(Debug)]
|
#[derive(Debug)]
|
||||||
struct Flag {
|
struct Flag {
|
||||||
value: bool,
|
value: bool,
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue