#define LED 11
#define SLIDE_POT A0
void setup() {
// put your setup code here, to run once:
Serial.begin (115200);
pinMode(LED, OUTPUT);
pinMode(SLIDE_POT, INPUT);
}
void loop() {
// put your main code here, to run repeatedly:
int potValue = analogRead(SLIDE_POT);
Serial.println(potValue);
int pwm = map (potValue, 0, 1023, 0, 255);
analogWrite(LED, pwm);
}