AudioKit: How can I sync an AKOperationGenerator to the frequency of an other Oscillator (oscillator-sync)?

243 Views Asked by At

I am new to AudioKit. I want to build a Synth with two Oscillators where one is synced by the other, means every wavelength of OSC1 (every second zero-crossing) the OSC2 is restarted (phase set to 0). Is this possible with AKOperation oscillators? thnx!

Edit: Maybe my explanation was very bad. Wikipedia is better: "One oscillator will restart the period of another oscillator, so that they will have the same base frequency. This can produce a musical sound, rich with harmonics. The timbre can be altered on the synched oscillator by varying its frequency input. A synched oscillator that resets the other oscillator(s) is called the master, and any synched oscillator that is reset by another oscillator is called a slave."

And here is some nice sounding visualization on YouTube.

Another Link with image and some maths.

EDIT 2: I have a strong feeling that this needs some DSP code. I thought about triggering stop()-and-start() with phase set to 0 by an Metronome running with the master osc frequency - but this does not sound like a good performing solution. any thoughts/help is very appreciated!

0

There are 0 best solutions below