hotchk155 / arpie

A compact and full featured MIDI arpeggiator, Open source, Arduino based

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Improve how sequencing begins if chord is not held in low thru high order and HOLD is off

hotchk155 opened this issue · comments

The set-up is "Hold" is off, the mode/arp pattern is "up" and I am going to play a three note chord 1-2-3 where note 1 is the lowest and note 3 is the highest. We would expect to get 1-2-3-1-2-3-1-2-3 etc as the sequence but sometimes I get 3-2-3-1-2-3-1-2-3-1-2-3 etc. (ie the first note is 3 instead of 1).

As far as I can fathom the case occurs like this. I try and play all notes at the same time, but in practice there will always be a tiny time difference between them. If the Arpie gets them in 1-2-3 order than all is well. If the Arpie gets them in the order 3-2-1 then trouble can start. In this case the behaviour depends on whether all three notes are read in the same call to arpReadInput() or not. If all three notes are read in the same call then they will be sorted correctly in to a three note sequence when arpBuildSequence() is called. However if the first call to arpReadInput() only gets the "3" note then Aprie will immediately start to play the one note sequence of "3". A subsequent call to arpReadInput() will get notes "1" and "2" and for the next beat the expected three note sequence will be built. This would give the output I described above.

As a user you can kind-of work around this by making sure you play the chord as 1-2-3 in sequence but it's tricky and perhaps defeats the object of having an "up" mode.

I think there is a trade-off between responsiveness and handling of race conditions between notes of what the player intends to be one chord. It might be useful to have a very short buffer before you start playing a new chord to make sure that there are no other notes coming along. It's a tough call and I don't know what commercial products do.