PLEASE don't use delay. Because if you get it right, the next thing you'll be wanting, is a method to do something else at the same time.
If you want a step rate of 440 hz that's about 2272 microseconds per step
So you could do it something like this.
unsigned long stepDelay=2272;
int stepPin=3;//Just something I picked at random
void setup()
{
pinMode(stepPin,OUTPUT);
}
unsigned long lastStep=0;
bool lastState=0;
void loop()
{
unsigned long t= micros();
if((t-lastStep) >= stepDelay)
{lastState= !lastState;
digitalWrite(stepPin,lastState);
lastStep += stepDelay;
}
//then you can have other stuff happening here too.
//PERHAPS EVEN UPDATING THE VALUE OF stepDelay based on something else
}