gligli / p600fw

Teensy++ based Sequential Circuits Prophet 600 firmware remake
http://gligli.github.io/p600fw/
41 stars 23 forks source link

UI for live retuning notes/scale #72

Closed snickell closed 9 years ago

snickell commented 9 years ago

Not redy to merge yet, but wanted to get @gligli thoughts on my UI approach early.

I'd love to chat if you have time in the next few days. My skype is sethnickell, also going to hang out on efnet as sethn in #p600 . Most likely to be around your evening (paris time).

1) I'm using the Record + Tune button combo to toggle 'live retuning ui mode'. I think it stays out of the way of other UI features well, reuses the existing 'blink record on press to indicate further input needed' code, makes UI sense, and requires no extra UI state. That UI make sense to you?

2) Now having live control of retuning, I realized that preset.perNoteTuningInCents is too coarse (can hear stepping, can't tune in resonances). I want to update the storage/preset to redefine perNoteTuning to allow greater precision (e.g. millisemitones instead of centisemitones). Do you want me to bump the version number to v8 and write code for updating between v7 and v8? Or do you feel comfortable that probably nobody except you and me used v7 in the past few days?

gligli commented 9 years ago

Yeah cool, I use skype and also have an irc client. I'll try to add you when I'm home.

1) Hmm, the usual "shift" key is FROM TAPE, It already has a pressed flag too, it may be better to use that one, for consistency.

2) Yeah I don't think it's necessary to bump the version number, I didn't even release an alpha version since then.

gligli commented 9 years ago

Just thinking: couldn't you store the tunings in a power of two instead of centis or millis (eg: 1024), this would remove the need for the division (they are really costly). It would just require some additional math when setting the tunings I think.

snickell commented 9 years ago

Yeah I agree. My original goal was to have the equal-tempered maths result in exactly the same values as before, but I think that's a silly goal, because as you point out it takes an extra division, AND it reduces the tuning precision from 16-bits to 11-bits. With the extra 5-bits of precision (=tuning in 1/4096s of a semitone), I think it doesn't matter when the maths result in a value 'between bits'.

It'll actually require less math in setting the tunings because, not surprisingly, midi uses a power of two for specifying pitch too.

snickell commented 9 years ago

@gligli: I think this is ready for merge....

The preset.perNoteTuning format change to 'power of two' is complete, and should be more performant, as well as permitting more precise tuning, and a basic UI is in place. I will probably want to update the details of the UI later, but I think it would be good to land the storage format change sooner rather than later, before anyone uses the prior cents format.

snickell commented 9 years ago

Still should be ready for merge.

Just wanted to separate out retuning code from wheelEvent, and provide a placeholder for a future pitch-wheel=abs positioned coarse-tuning, mod-wheel=relative fine-tuning UI (current temporary UI doesn't permit fine enough tuning for just intonation).

gligli commented 9 years ago

Ok, thanks!