Question: what is the difference between analog and digital pins in arduino?
Answer: The Arduino can input and output analog signals as well as digital signals. An analog signal is one that can take on any number of values, unlike a digital signal which has only two values: HIGH and LOW. ... The function used to output a PWM signal is analogWrite(pin, value). pin is the pin number used for the PWM output.