Tonight I fixed it up so that you can hit play and change patterns and the pattern won't change to the one currently displayed until the first finishes playing.
This is important because by dissociating playback from editing, I can build in looping functionality.
The current plan is to let the user pick loops of 1, 2, 4, or 8 patterns. (Or pick 0 to not loop at all.) Then the user can pick a starting pattern (which will adjust itself based on the length of loop. A loop of 4 patterns could start at 1, 2, 3, 4, or 5, but not 6, 7, or 8, and so on).
When the user hits A to start playback, the currently-displayed pattern will play and then if it's part of the loop, playback will continue until the end of the loop is reached and then start over at the beginning of the loop. If the pattern is not part of the loop, that pattern will play and then it will jump to the start of the loop. So if I have a 4-pattern loop starting at 5 and I'm on 1 and hit play, it will play 1 and then 5, 6, 7, 8, and 5 again and so on.
These settings will be saved along with the patterns and tempo to eeprom.
When this part is done, I'll clean up the comments and debug junk and release the source! I suspect swing quantization will take enough time to sort out that I might as well let people play with what's here and not make them wait for me to figure out something complicated that I didn't quite design the thing around.