update sequences
This commit is contained in:
parent
1bdb68c0d4
commit
a1767420f2
3 changed files with 158 additions and 317 deletions
|
|
@ -295,7 +295,7 @@ pub struct Sequences {
|
|||
pub led0: sequencer::BasicSequence<'static>,
|
||||
pub led1: sequencer::BasicSequence<'static>,
|
||||
pub led2: sequencer::BasicSequence<'static>,
|
||||
pub audio: &'static [&'static [sequencer::SequenceEntry]],
|
||||
pub audio: &'static [(&'static [sequencer::SequenceEntry], usize)],
|
||||
}
|
||||
|
||||
// things that touch hardware
|
||||
|
|
@ -528,9 +528,8 @@ impl App {
|
|||
// TODO
|
||||
#[cfg(feature = "enable_print")]
|
||||
println!("click");
|
||||
self.services
|
||||
.sequencer
|
||||
.play_sequence(self.sequences.audio[self.settings.button_sound_index], 1);
|
||||
let data = self.sequences.audio[self.settings.button_sound_index];
|
||||
self.services.sequencer.play_sequence(data.0, data.1);
|
||||
|
||||
self.settings.button_sound_index += 1;
|
||||
if self.settings.button_sound_index > self.sequences.audio.len() - 1 {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue