So you want an output that is LOW (0V) for 25 milliseconds and then HIGH (5V) for 25 milliseconds and repeats? The 'BlinkWithoutDelay' example can be easily modified to do that:
// constants won't change. Used here to set a pin number:
const int outputPin = LED_BUILTIN; // the number of the LED pin
// Variables will change:
int outputState = LOW; // outputState used to set the LED
unsigned long previousMillis = 0; // will store last time LED was updated
// constants won't change:
const long interval = 25; // interval at which to blink (milliseconds)
void setup()
{
// set the digital pin as output:
pinMode(outputPin, OUTPUT);
}
void loop()
{
unsigned long currentMillis = millis();
if (currentMillis - previousMillis >= interval)
{
// save the last time you blinked the LED
previousMillis += interval;
// if the LED is off turn it on and vice-versa:
if (outputState == LOW)
{
outputState = HIGH;
}
else
{
outputState = LOW;
}
// set the LED with the outputState of the variable:
digitalWrite(outputPin, outputState);
}
}