The Different of Generating PWM Frequency in Arduino Board

"The pin parameter is the pin number which must be capable of generating PWM signal. For Arduino Nano or Arduino UNO the PWM pins are 3,5,6,9,10 and 11. The pins 3, 9, 10 and 11 generates PWM frequency of 490Hz and pins 5 and 6 generates PWM frequency of 980Hz. "
(Quoted from ee-diary.)

I'm still newbie even though I've been doing many projects of Arduino. And, I have a question related to the quote:

When I use 5 & 6 pins and connect it to motors, will it be different result (e.g speed, disturbance if exists, etc which I don't know)?

PLEASE HELP

I moved your topic to an appropriate forum category @jimmyjr2023.

In the future, please take some time to pick the forum category that best suits the subject of your topic. There is an "About the _____ category" topic at the top of each category that explains its purpose.

This is an important part of responsible forum usage, as explained in the "How to get the best out of this forum" guide. The guide contains a lot of other useful information. Please read it.

Thanks in advance for your cooperation.

1 Like

Thanks- I will read it carefully.

1 Like

Usually the PWM frequency doesn't matter. It depends on the needs of the load.

would you give me further explanation (about "depends on the load") since some pins have different Hz? say, with a led 5v, are 490Hz and 980Hz (based on their own PWM pins) will make different speed for examples, or anything else?

What is the load You want to control?

1 Like

Do you know what PWM is and how it works? See this:-
http://www.thebox.myzen.co.uk/Tutorial/PWM.html

The frequency of the PWM signal is largely irrelevant if you want to add a filter and turn it into a DC signal like I described in the above link. However, for any given filter component values the higher the frequency of the PWM the smoother will be the DC value.

For things like controlling the brightness of an LED the speed of the PWM will make little difference unless you want to wave the LED about. For the lower PWM frequencies you might see a series of dots through the air, as opposed to a continuous line with the higher frequency PWM.

For controlling the speed of high speed motors you might want the higher speed PWM.

For generating an Audio signal you might want the PWM to run much faster, say at 100KHz, then this can be done also by altering the PWM speed using special registers inside the Arduino.

1 Like

For examples: a 5v led and a travel servo

@Grumpy_Mike gave You all, I think.

A LED doesn't care about PWM frequency, but your vision could.
If you get below a certain frequency, you get flicker. But that happens below 30Hz.
500Hz or 1kHz won't make a diffference.
Servos use a special 50Hz PWM signal that does not need a PWM pin.
(almost) Any Arduino pin can be used for servos.
Leo..

1 Like

To tell you the truth, I'm ZERO in electronic, but crazy in this science, specially robotic. I need to learn a lot step by step about all this. I'm a web developer :slight_smile: but really thirsty about electronic and robotic (especially arduino). I spend 9 hours a day for this awesome science.

To see your links, read carefully, I know little what PWM is and what the use of it in related to output purpose and how it works (need time to grasp them all).

But, as what wawa said:

This is very fast for me to understand the simple description about the differences of PWM freqeuency in arduino board and how it generates it. For this, I'm glad to do some experiments about it. This is wow for me.

Thanks for this clue. It makes me sense (as a newbie). Well, I will learn a lot.

Turning on the light when it gets dark and turning it off when you go to bed is a form of PWM.
The frequency is 24hours and the duty cycle could be 6 hours.
6/24 = 25% of the time the light is on.

When you do this faster, much faster, your vision can't follow that on/off switching any more.
Your vision/brain averages it, and sees it as a dim light.

So PWM is nothing more than fully on or fully off in a rapid succesion, with a varying on/off ratio that could make lights dim and motors receive less power.

The frequency usually stays the same, but the on/off ratio can vary.
Leo..

2 Likes

Yes I understand 100% with no doubt about PWM Frequency. You explained it as simple as that. But, that's the way for me to understand since my IQ is very low in this case. Time's to do some experiment on it.

Sorry but my internet service provider pulled the plug on the free web space they offered and took my whole site off line and didn't even offer a web redirection service. Tech support says every time they suggest this the CEO of the company says it will cost hundreds of thousand pounds to implement.
This file
PWM.zip (782.1 KB)

Will un-compress and you can double click the file and it should load just that page into your browser of choice. Let me know if you have any problems with this. Of course none of the links off this page will work.

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.