Brand new User working through the beginner Kit projects

Hi all , ( please be gentle )

I'm a brand new user of the DFRduino Uno R3 Which I got as part of the Beginners kit .

I'm just doing the simple Fading Light Project - really really simple .
( DFRduino_Beginner_Kit_For_Arduino_V3_SKU_DFR0100-DFRobot )

I notice if I use pins 13 or 12 the LED does not fade but just stays the same brightness - I just get a slow blinking effect

If I use the other pins ( 11, 10 , 9 , 8 etc ) it does fade as described.

Is there a reason that doesn't involve divine intervention for this ?

Thanks in advance .

cheers
John

analogWrite() outputs PWM (pulse witdth modulation, ie, turning pin on and off rapidly, with variable duty cycle).

PWM is generated using the hardware timers' output compare function - this is available on 2 specific pins for each of the three timers on the Arduino. I think these pins are marked on the Arduino board itself, but I don't recall exactly how - I don't have any Unos. They're 3,5,6 and 9,10,11 on the Uno.

On pins that don't support it, analogWrite(pin,128 or more) is the same as digitalWrite(pin,HIGH), analogWrite(pin,127 or less) is the same as digitalWrite(pin,LOW).

There are some wonderful pinout diagrams online, and these all mark which pins support PWM. Take a look, and save whichever one you like best (I recommend printing it out on a color laser printer and getting it laminated; that's what I did for the chips/boards I use most - the sort of copy-shop places you can take stuff to be laminated can usually also do color laser printing) https://www.google.com/search?q=arduino+uno+pinout&tbm=isch

Awesome - That helps - Many Thanks !

On a standard Uno, PWM pins are marked with a tilde "~". Your DFRduino may not show this.