Worst case is going to be 1LSB + on one DAC and one LSB - on the other for the same commanded value (i.e. about 6-7 cents total) unless you have some kind of calibration or closed loop control. We have to assume the chip will perform no better than the guaranteed specs unless we’re binning them ourselves.

My less-than-stellar Subcon reissue Model 15 and Model 37 will track without beating over an octave or two without any problems–actually they can track so closely that I get cancellation and phasing effects. But this isn’t unusual in my experience, even my Doepfer A-143-9 quadrature oscillators track pretty well. Maybe I have just been lucky, but I have had to calibrate the 1V/octave scaling on every oscillator I’ve owned.

“Granted the averaging on most uC ADCs actually provides sub-LSB accuracy …” … really? My direct experience is limited to the PWM outputs on AVRs (which you can get good 12 bit resolution out of with some stacking magic), but the settling times are awful: 3ms+ after smoothing. The rest of the standard DACs I’m aware of all have real world INL that’s waayyy too high unless you spend a bit and can deal with SMT parts–you have to spend a lot more for DIP parts you can breadboard with.

TSSOP … hmmm …

I would love to see some kind of scale definition functions in the teletype, though I would generalize such a thing so that it was a more general purpose array index with mapping thing. I do something like this in my quantizer firmware to process incoming voltage samples to scales–and the scales don’t have to be octave-based. I see some capability for this now in teletype, but it sure would be awesome to be able to have a bunch available simultaneously. Depending on the max number of notes in a scale (currently 43 for Harry Partch compatibility), I can get a hundred or two in an AVR’s firmware–I’d figger teletype has more room. :slight_smile:

It’s on my todo list. In fact it’s probably the main reason I started my various rewrites of the teletype code, I find entering scales into patterns quite tedious. The syntax might end up being too esoteric for common use, so it’s possible I’ll just keep them in my own branch. I not sure if they’ll fit your use case though.

It’ll really be a set of inline array functions (for example)…

#4.L 3 7 9 10 T       // would take the Tth item from the first 4 values looped (nice for arps)
#7.S 0 2 3 5 7 9 10 X // make a (western) scale from the first 7 values, take Xth value
#7.Q 0 2 3 5 7 9 10 Y // make a scale form the first 7 values, find the nearest to Y (i.e. quantise Y to the scale)

The common format being a #, then the size of the array, then the function name. On technical level it will be a bit of a hack, essentially I’d create an op for each array size (e.g. #1.L, #2.L, #2.L, etc) with some C macros to ease repetition.

I’m also planning on writing up a tutorial on how to write your own ops, most likely in the form of creating your own tables, the example will probably be a table of primes or the Fibonacci sequence.

7 Likes

Looks interesting, Sam!

The general algorithm I use for quantizing is something like:

  • Calculate the scale span from the scale definition (usually an octave, but the code is agnostic on this point)
  • Divide the incoming voltage by the scale span; multiply integer quotient by scale span to get offset
  • Use Arduino map() or similar function to get a scale index (note value) from the remainder
  • Add the offset and note value
  • Write result to the DAC

There has to be some kind of anti-jitter code in there too: a simple array lookup doesn’t function very well if it is driven by external CV. It’s also very helpful to know if the note has changed or not.

I handle everything in cents internally, it’s much easier to enter e.g. Scala archive scales that way.

1 Like

Something worth remembering is that teletype scripts only run in response to events, either the metronome, triggers, or manually via the keyboard. So you won’t be able to write a traditional quantiser that works continuously, instead you’d have to trigger a script that would then sample the IN value. (You will also need to deal with the IN value not being stable when the trigger fires… DEL comes in handy here.)

1 Like

indeed. teletype is more of a control environment and event system, not so much a processor.

Perhaps this is OT, but wondering if you’ve experimented with the ‘note windows’ for parts of a scale?

Say you have a seven note scale spanned over an octave, but in the scale you have 4 different tunings of a 3rd. In the standard divide input by total elements, then table lookup, this would emphasize the 3rd intervals as they take up most of the values.

One alternative would be to make ‘windows’ where the divisions between note changes occur halfway to the next note in the scale. This would have the inverse effect of emphasizing the notes which are most unique in the scale. I’m sure there’s many alternative approaches, but I’m certain this would make a quantizer feel entirely different – whether it’d be more musical requires investigation!

1 Like

It’s my thread, so I declare it on topic. :smiley:

Yes, I have thought about this quite a lot because it’s a strong element in some kinds of musical traditions: Indian, Middle Eastern, blues, etc.: those quarter tones (or smaller) aren’t full-fledged notes in the sense we’ve come to expect in the western 12TET tradition: they are ornamental in some cases, and part of a progression (I think!) in others.

Having been a woodwind, brass, and string player, I don’t think about synthesizers in a very piano-oriented way (though I also play piano): some of the conventions piano/keyboard players take as “the way music works” drive me insane.:slight_smile:

One way around it is to define different modes with different emphasis, much the same way as we would use a minor, mixolydian, etc. in western scales. This requires some form of algorithmic or other control of scale/mode selection … and the code grows longer …

this is an interesting point to consider, i always thought of quantizers in terms of a simple lookup, but note emphasis also makes me think of whether there are some interesting results to be had from implementing a “smart” quantizer that does some analysis on the previous notes and uses it as an additional criteria for note selection (so, say, including certain notes only after a specific progression). is there anything of the sort?

and welcome to lines, john!

1 Like

Hi, nice to see some familiar faces here. :slight_smile:

I don’t know if any available quantizers will do e.g. melodic minor scales–I don’t think so. They are part of the road map for my own design.

Note weighting and some other things have great musical potential in generative music.

I really like this idea – If you play a chromatic passing tone, the quantizer heavily weights the next note to land back in the scale. It becomes a difficult proposition though as once you get to that kind of sophistication it makes me feel a need for harmonic leading to smartly shift scales.

Of course this shows my very western sense of harmony & jazz background, so perhaps there’s a way to abstract some of these ideas to make them more open-ended.

It’s a wonder these kinds of ideas haven’t been pursued more in the very mainstream world of pitch correction. Seems to me a smarter quantizer would facilitate much faster autotuning!

4 Likes

What do you guys think of the tip quantiser? They worked on that for years

Dogma, I publicly pouted in one of the Eurorack Facebook groups about how the Tiptop isn’t microtonal. :smiley: It seems like a nice quantizer, but very conventional. I wouldn’t trade my Doepfer A-156 for it.

Galapagoose, there’s a whole world of musical traditions that get ignored in electronic instrument design. I don’t know if it’s because the gear gets built by engineers and not musicians, lack of imagination, or what, but it’s totally inexplicable to me. I think computers have stunted musical education for a lot of people: the omnipresent grids, 12TET scales and conventional modes, etc. have conditioned a generation of people to think this is how music is.

About half of my first album, which was made entirely wit my modular, incorporates microtonal scales (Indian, 19 tone, 24 tone, etc), and I make fairly “conventional” music.

I highly recommend the chapter on “Musical Scales, Tuning, and Intonation” from Musimathics by Gareth Loy, I read that when I want to get my head around the whole A# is not equal to Bb business. In the end it made me appreciate what equal temperament brings to the table, and the new types of music it brought in.

3 Likes

This is an interesting point I hadn’t quite considered – ie Jazz, at least bebop on, is inherently indebted (and thus somewhat trapped) in 12TET scales. I should definitely do more reading on how alternate tunings can relate to / interact with shifting key centers. The wholetone scale (for eg) only really makes sense in equal temperament (right?)…

@jnoble there’s certainly much room to explore non-12tet technology approaches. I’m curious what methods you’ve used to compose / perform that album? I’ve often found myself frustrated when exploring just intonation (for eg) because the only way I could use existing tools was by just applying tuning tables to standard interfaces. Thus it still feels like a traditional piano roll / keyboard / synthesizer with different sounds – hard to shake ~20 years of western musical training when the instrument feels almost exactly the same.

Do you have thoughts on how to ‘unlearn’ some of these habits, or more broadly what was your experience like when first engaging in alternative tunings?

2 Likes

this is when i really regret not having formal music education and very little knowledge of music theory… using the opportunity, what books or resources would you recommend as a good start on music theory, maybe scales / chords specifically? i’ve also been meaning to get Musimathics but not sure if approaching it without any proper background in music theory would be a bad idea?

but it’s such a fascinating topic, developing a system that is capable of altering its behaviour [not just parameters but potentially the algorithm itself] based on its previous state and analysis of the incoming stream of events. neural networks / deep analysis is a big thing nowadays but it feels there is a vast territory of something much simpler that would still be capable of producing interesting results. a smart quantizer being one example, or a system that analyses gestural input and produces complimentary sequences or events.

and it’s interesting to think of how you could abstract it in a more open ended manner. so if i understood @Galapagoose correctly in a smart quantizer you wouldn’t just alter weights or probabilities given to different notes in a scale but alter the scale itself? so, kinda like having a 2 dimensional scale with different mapping rules applied to x and y?

1 Like

“If it sounds good, it is good.”

– Duke Ellington

I think the logical conclusion is a music AI that has a sense of style.

I’d like to point out that music is so much more than pitch and that musical decisions typically associated with quantizers (scales, modes and such) can also be applied to timbre, accent, duration, tempo, etc. A simple approach to this can be to apply pitch CV to, say, envelope decay, which results in higher pitches getting more and more legato. A more advanced approach would be to send a quantizer’s trigger out to an envelope that applies a little glissando chirp to an oscillator’s aux CV input–new notes get a gliss, repeated notes don’t. Run that trigger through a clock divider to get rhythmic variation.

The strength of modular synthesis is that these kinds of constructs are easy to implement. Time domain decisions can be made with e.g. slews, comparators, sample & hold and brethren like ASRs, etc., and their effects can be easily added, subtracted, multiplied and otherwise mangled.

But I preach to the choir. :smiley:

2 Likes

modulars do invite synesthesia like experiments by nature, don’t they.

but yeah, the idea can be applied to anything really, if you separate the analysis part. fixed filterbanks with envelope followers being one example, modules that produce gates when the incoming CV rises or falls etc etc.

for a smart quantizer you could also expose some of the parameters as inputs, then being able to influence them with an LFO or whatever.

there must be something already along these lines! a quick search turned up nothing so far, mostly getting time domain quantization…

yes, this. i was about to ask if y’all were equally interested in “slippery” time, etc. modular lends itself to and overabundance of metric rigidity.

3 Likes

i think it all depends on a patch, modular lends itself well to time domain modulation as well, CVable trigger delay as one example. extracting triggers from things, LFO with a CVable shape into a comparator. another source of interesting triggers - digital based modules that expect stable clock but feeding them something else just to confuse them, with the manner of confusion depending on the implementation, it’s interesting to “break” these things, get them out of their stable comfort zone.

i’ve also been thinking about the concept of events placed on a rigid grid, where the grid itself is placed on a rubber surface which is then stretched. so you have a bunch of events that still maintain some non linear relationship to each other. it’d be interesting to build a trigger sequencer where you program steps in a typical x0x fashion but then you have control over the grid surface where you can stretch/twist it.

2 Likes

You don’t need any music background to read Musimathics (I don’t). I really enjoyed the chapter on tuning, but I found the remainder of the book a bit dull. For me that one chapter was worth the price of the book, I feel like I have a really solid mathematical understanding of the fundamentals of music theory, even if I don’t know the first thing about tension and release.

2 Likes