int led = 6; int poti; void setup() { Serial.begin(9600); } void loop() { poti = analogRead(A0); int pwm = map(poti, 0, 1023, 0, 255); analogWrite(led, pwm); Serial.print("PWM-Wert: "); Serial.print(pwm); delay(5); }