mirror of
https://github.com/Start9Labs/start-os.git
synced 2026-03-27 02:41:53 +00:00
fix note timings (#449)
This commit is contained in:
committed by
GitHub
parent
2dfd5d994f
commit
b23d46f254
@@ -86,9 +86,9 @@ impl SoundInterface {
|
||||
) -> Result<(), Error> {
|
||||
{
|
||||
self.play(note).await?;
|
||||
tokio::time::sleep(time_slice.to_duration((tempo_qpm as u64 * 19 / 20) as u16)).await;
|
||||
tokio::time::sleep(time_slice.to_duration(tempo_qpm) * 19 / 20).await;
|
||||
self.stop().await?;
|
||||
tokio::time::sleep(time_slice.to_duration(tempo_qpm / 20)).await;
|
||||
tokio::time::sleep(time_slice.to_duration(tempo_qpm) / 20).await;
|
||||
Ok(())
|
||||
}
|
||||
.or_else(|e: Error| {
|
||||
|
||||
Reference in New Issue
Block a user