This video goes over some of the basic concepts of a synthesizer, how to create one using Tone.js and p5js, an finally two different methods of control.
As a side note, be sure not to trigger playback in the draw function just like playing back a sound file. all of the same rules still apply here.
#synthwave #tone.js #livecoding