void setup() { // initialize digital pin 7 as an output. pinMode(7, OUTPUT); } void loop() { // Increment the PWM value from 10 to 250 in steps of 10 for (int pwmValue = 10; pwmValue <= 250; pwmValue += 10) { analogWrite(7, pwmValue); // Set the PWM value delay(1000); // Wait for a second } }