Commit 7dbb9fbc authored by Jacob Vosmaer's avatar Jacob Vosmaer

Don't update clock with delta 0

parent 6e37aac5
...@@ -95,13 +95,16 @@ do_clock_update(void) ...@@ -95,13 +95,16 @@ do_clock_update(void)
uint8_t clock = TCNT0; uint8_t clock = TCNT0;
uint8_t delta = clock - prev_clock; uint8_t delta = clock - prev_clock;
prev_clock = clock;
if (delta == 0) {
return;
}
vibrato_update(delta); vibrato_update(delta);
gate_update(delta); gate_update(delta);
pitch_update_clock(delta); pitch_update_clock(delta);
(*update_clock[current_program])(delta); (*update_clock[current_program])(delta);
prev_clock = clock;
} }
void void
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment