Do i need capacitors

MarkT:

polymorph:
It is important to pay attention to where the ground lines run, too, not just Vcc.

All of those 6 images are poor as the traces between IC pins and decoupling
capacitor are narrow signal traces, not low-inductance wide traces. This is
more important than where you route the wires to the regulator, there must be
as low-inductance a path from chip to the fast decoupling cap as possible. At least
they are short traces, but it shows a lack of understanding of Maxwell and Heaviside's
equations...

Also its perfectly fine to use planes in place of traces for GND and/or Vcc. Planes
are as low-inductance as you can get!

Can you please take a look at the image i posted on my previous post and tell me if i can wire the caps that way ? thanks a lot !!!

You can place them like that but they won't do as much good as if you soldered them on the motor.

Those capacitors you show are polerised, that is no good if the motor can change direction.

Hi, I hate to repeat what everybody has asked, but , what SIZE is your 9V battery?

A picture of your project would help us to see what you have and provide accurate information.

Tom..... :slight_smile:

TomGeorge:
Hi, I hate to repeat what everybody has asked, but , what SIZE is your 9V battery?

A picture of your project would help us to see what you have and provide accurate information.

Tom..... :slight_smile:

6*AA ALKALINE batterries.. I rarely run the project on batterrties, most tests happen on usb..
I wikl post a picture later on the day..

Grumpy Mike, so its better to solder them on the motor, what capacitors should i use then??

Thanks a lot

Ahh, a battery-holder with 6 AA-cells. That is much, much better than a 9-volt block battery that we thought you were using.
Like this: Nine-volt battery - Wikipedia

Actually, you could do yourself a favor. Only put 5 batteries in the holder, then you will not waste as much power in the voltage regulator on the Arduino, and your batteries will actually last longer! - Solder a wire across one position in the battery holder, or make a "dummy" battery out of a dowel wrapped in tinfoil, or whatever you can come up with.

// Per.

so its better to solder them on the motor,

Yes, as a rule it is best to get it as close to the source of interference as possible.
You need both a 0.1uF ceramic capacitor for high frequencies and a large one for the low frequencies. If the motor runs in both directions you need a non polarised capacitor, otherwise an electrolitic will do. The larger the better.

So we got the battery sorted out, people were concerned you just might be using a "PP4" battery. :smiley:

OK, so you are not that silly!

If you are not using PWM, a 0.1µF ceramic capacitor soldered directly across the motor terminals. YOu will notice this as standard in radio controlled toys. (Serious models use ESC.)

If you are using PWM, you can still do this, but will need to provide an inductor in series with one or each of the motor terminals - I will "bow out" at this point, of explaining how you should calculate the value.

Regarding capacitors on motors for noise-dampening, all you need to know is here:
http://www.beam-wiki.org/wiki/Reducing_Motor_Noise

// Per.

Sure i wouldn't use a solid 9V battery !!! :smiley: :smiley: :smiley:

Thanks everyone for the useful replies !!!

Only put 5 batteries in the holder, then you will not waste as much power in the voltage regulator on the Arduino, and your batteries will actually last longer!
// Per.

That can be easily done...

Grumpy_Mike:

so its better to solder them on the motor,

You need both a 0.1uF ceramic capacitor for high frequencies and a large one for the low frequencies. If the motor runs in both directions you need a non polarised capacitor, otherwise an electrolitic will do. The larger the better.

Thanks Mike...

Paul__B:
If you are using PWM, you can still do this, but will need to provide an inductor in series with one or each of the motor terminals - I will "bow out" at this point, of explaining how you should calculate the value.

i do use PWM, so can you tell me more about the inductor ? :astonished:
it wont work if i use a polarized or electrolytic capacitor as Mike said ?

Up to now i hear about capacitor on motors, no need to add bypass capacitors anywhere else?
LCD,Bluetooth and distance sensor are powered through arduinos 5V, maybe i should add a bypass capacitor on the 5V output ?
Also should i add a bypass capacitor to the power supply of arduino?

Thanks again !!! :smiley: :smiley: :smiley:

maybe i should add a bypass capacitor on the 5V output ?

You should have a capacitor on each of your three modules, as close to the module as possible.

Grumpy_Mike:

maybe i should add a bypass capacitor on the 5V output ?

You should have a capacitor on each of your three modules, as close to the module as possible.

Mike really thanks for replying again.. So one capacitor in each module, electrolytic or ceramic and what capacity?
Also Paul said that PWM won't work if i use a capacitor ..why?

Here is a really quick diagram of the wiring, please let me know if i did something wrong to the bypass capacitors..

Yes that is the idea, although you. Although you might get away with not having them on the lower current devices like the LCD.

I am not sure why Paul said that. In general you do not want to make the capacitor that big wired directly across the motor, just a 0.1 uF ceramic. You want the large one across the motor supply not the motor itself. That is the motor and the driver be it simple FET or h- bridge. When you do then you can put an inductor in seriese with the supply and a capacitor the other side. This is known as a pi filter because it resembles the symbol for the maths constant. Google for an example.

There was a question recently about how to claculate it's value and things got rather over heated. Basically every one was right but some were arguing from mistaken premmisis. (that is probbly a spelling joke - a dyslexic on an iPad is not a good combination as the spell corrector is rubbish )

Grumpy_Mike:
I am not sure why Paul said that. In general you do not want to make the capacitor that big wired directly across the motor, just a 0.1 uF ceramic. You want the large one across the motor supply not the motor itself. That is the motor and the driver be it simple FET or h- bridge. When you do then you can put an inductor in seriese with the supply and a capacitor the other side. This is known as a pi filter because it resembles the symbol for the maths constant. Google for an example.

So up to now i 've learned that i have to use a 0.1?F ceramic capacitors soldered on the dc motors and an electrolytic capacitor for each of the other modules(but what about their capacity? electrolytic or ceramic :~ :~ :~ :~ :~ :~ :~ :~ :~)..

Also i think i understand now why i will have problems if i use capacitors with PWM, however PWM is essential to my project so i don't really know what to do !!!
I think here says that a RC(resistor capacitor) filter can make the PWM wotk fine, right ? http://provideyourown.com/2011/analogwrite-convert-pwm-to-voltage/

(but what about their capacity? electrolytic or ceramic

Not sure what you mean? Use 47uF for the large capacitors.

I think here says that a RC(resistor capacitor) filter can make the PWM wotk fine, right ?

No. That is not suitable for a motor. It produces a varying DC voltage, that is not the way to drive a motor and have good speed control.

Read about PWM here:-
http://www.thebox.myzen.co.uk/Tutorial/PWM.html
For a motor you must apply it directly to the motor.
Read this on motors:-
http://www.thebox.myzen.co.uk/Workshop/Motors_1.html

For the motor Pi filter read this, it is the last schematic on the page:-
http://www.thebox.myzen.co.uk/Tutorial/De-coupling.html

Grumpy_Mike:

(but what about their capacity? electrolytic or ceramic

Not sure what you mean? Use 47uF for the large capacitors.

I think here says that a RC(resistor capacitor) filter can make the PWM wotk fine, right ?

No. That is not suitable for a motor. It produces a varying DC voltage, that is not the way to drive a motor and have good speed control.

Read about PWM here:-
PWM
For a motor you must apply it directly to the motor.
Read this on motors:-
Motors 1

For the motor Pi filter read this, it is the last schematic on the page:-
De-coupling

Mike thanks again, your help is so important !!! :smiley: :smiley: :smiley:

--Each module(Bluetooth,Distance sensor,LCD) as you said should have a 47uf capacitor ,right? Should it be Electrolytic or ceramic? or it doesn't matter?

--I am familiar with the way PWM works, i saw the schematic you told me and i think it doesn't worth trying to add 4 capacitors and an inductor to each of the four DC motors i use... Otherwise, is there anything else i can do ? Really, PWM ,in practice,wont work at all if i just add a ceramic capacitor to each motor?

a 47uf capacitor ,right? Should it be Electrolytic or ceramic?

You have no choice, you can't get 47uF ceramic capacitors.

Really, PWM ,in practice,wont work at all if i just add a ceramic capacitor to each motor?

Just adding a 0.1uF capacitor across a motor will not make PWM stop working.

Grumpy_Mike:

a 47uf capacitor ,right? Should it be Electrolytic or ceramic?

You have no choice, you can't get 47uF ceramic capacitors.

Great !!!

Really, PWM ,in practice,wont work at all if i just add a ceramic capacitor to each motor?

Just adding a 0.1uF capacitor across a motor will not make PWM stop working.
[/quote]
Nice to hear that.. So where was the problem? ??? :astonished: :astonished: :astonished:

So where was the problem?

You tell me?

Grumpy_Mike:

So where was the problem?

You tell me?

if i remember right Paul said that PWM wouldn't work if i use a capacitor...

That was if you used a big capacitor not a 0.1uF.