This project refers to an Arduino sketch which with the help of an external potentiometer (input device) can control a bar graph of many LEDs. Finally, when the sketch starts running, it calibrates the potentiometer (and so there should be a spin at both ends manually).

For more information you can get the project itself: