So after I looked up modulation as it pertains to audio I understand now ![]()
My new code:(It makes a sin wave but also modulates the pitch really fast up and down.)
void loop() {
b=b+1; //for the sine wave
a=a+mod; //for the pitch modulation
if(a>40){mod=-mod;}
if(a<1){mod=-mod;} //these loop modulation back and forth
c=75*sin(.004*b)+1600+a*5; //all the numbers added up.
tone(13,c);
}