Fade an LED on

The LED fades up because the loop() function repeats. You can do something similar with a for loop that increments the value to be written to the LED, writes it to the LED then delay()s a while.

That may not be the best way to do what you want, but it is easy.