Analog PWM
Impostare la frequenza del PWM tramite un input analogico.
+
+- Schema: http://lab.piffa.net/schemi/arduino-pwm-diagram.png
*/
-int inputPin = A0; // set input pin for the potentiometer
-int inputValue = 0; // potentiometer input variable
-int ledPin = 3; // output pin, deve avere il PWM
+const byte inputPin = A0;// set input pin for the potentiometer
+int inputValue = 0; // potentiometer input variable
+const byte ledPin = 3; // output pin, deve avere il PWM
void setup() {
// declare the ledPin as an OUTPUT: