Or the digital way: on the Commodore 64 disk drive (the 1541), you'd flip a bit of a certain memory-mapped location to switch the LED on or off. Doing this a variable amount of times per second would result in a smoothly fading led. Not sure if anyone ever made a sinusoidal fade, but there were demo's with the LED following the beat of the music.