Go Down

Topic: what is the ~ pins and what do they do? (Read 380 times) previous topic - next topic

circuitsguy

Hey guys,

     I am totally new and was trying the blink sketch for the first time, and I realized, what is the differencce between the i/o pins with ~ and without ~ ? I can't light an led on the one that has the ~ on it. So I was just wondering. THANKS!  XD

marco_c

The ones with the ~ are PWM pins. You should be able to use them like normal pins.
Arduino libraries http://arduinocode.codeplex.com
Parola hardware & library http://parola.codeplex.com

MarkT

Not just "should", they definitely are standard digital pins that can also be used with analogWrite() for PWM (pulse width modulation - see google for more details)

For PWM pins the PWM is turned on when calling analogWrite() and turned off again when calling digitalWrite().  The '~' symbol is, I suppose, a crude representation of a square wave.
[ I won't respond to messages, use the forum please ]

Go Up