I'd like to create a really fast square/pulse VCO that's running at a higher frequency than the factory VCOs. Basically as fast as the Axoloti will let me (how much kHz would that be?). The object should have an inlet and a dial to set the frequency.
I'm not totally new to coding and tried to modify the cheap square factory object, but I don't really understand how loops work in Axoloti (k-rate/s-rate) and how to make the inlet/dial thing.
Can somebody help me with this?
EDIT: here is what I came up coming from the cheap square object, creating a fixed square wave OSC running at maximum speed (I guess):
int j;
int on = 0;for(j=0;j<BUFSIZE;j++){
if (on == 0){ outlet_outlet[j] = (1<<26); on = 1; } else { outlet_outlet[j] = -(1<<26); on = 0; }
}