Because the discussion of this thread moved from adding one or two preset to an idea of making a generic tuner, I thought it was better to start a new discussion.

I've made a new branch on the gxtuner repo and will use that one, to (try to) rework GXtuner in a generic just intonation tuner.

The cool thing about JI is that you have infinite (but) discrete ratios. But what is needed at a certain time is just a small selection of these intervals: A base note and a scale which contains an amount of notes with a certain (ratio based) distance from the base note.

For example the diatonic scale contains the following ratios 1/1, 9/8, 5/4, 4/3, 3/2, 5/3, 15/8, when a basenote is selected the other notes can easily be calculated.

I have the math figured out to make all the necessary calculations, but have a couple of questions about how to get an extra input switch.

@Hermann: Do you mind to add a few comments in the code of where and how the treshold or presets inputs are generated?

What I need to proceed is a couple of inputs for integers. So variable x is set at -1 or 2 or something like that and can be changed just as changing a preset (from diatonic to shruti for instance).

Hans