Go Down

Topic: Big capacitor near microcontroller - Circuit stops working (Read 3381 times) previous topic - next topic

BenF

Sorry - I didn't catch that.

Still it is difficult to explain this issue besides faulty wiring. Other than that I would check reset, power (including brown-out detection)  and clock.

bubulindo

Stupid question, can you take the capacitor out of the circuit? Or change the program you're using to troubleshoot the problem?

If you're not sure if it's the capacitor or the software, changing one of them would be enough to determine that. Also, what's the voltage on the capacitor pins once it finishes charging?
Eu não sou o teu criado. Se respondo no fórum é para ajudar todos mediante a minha disponibilidade e disposição. Responder por mensagem pessoal iria contra o propósito do fórum e por isso evito-o.
Se realmente pretendes que eu te ajude por mensagem pessoal, então podemos chegar a um acordo e contrato onde me pagas pela ajuda que eu fornecer e poderás então definir os termos de confidencialidade do meu serviço. De forma contrária toda e qualquer ajuda que eu der tem de ser visível a todos os participantes do fórum (será boa ideia, veres o significado da palavra fórum).
Nota também que eu não me responsabilizo por parvoíces escritas neste espaço pelo que se vais seguir algo dito por mim, entende que o farás por tua conta e risco.

Dito isto, mensagens pessoais só se forem pessoais, ou seja, se já interagimos de alguma forma no passado ou se me pretendes convidar para uma churrascada com cerveja (paga por ti, obviamente).

Coding Badly


brenin

I don't think the capacitor is defective, as I switched it and the problem wasn't solved...

bubulindo, I took the capacitor out of the circuit, and the problem never happened again. I'm just trying to understand what happend, so I don't make the same mistake again.

BenF, I also don't think that wiring problem. I soldered it, but it's a manucfatured board. Reset is right, and the brown-out detection is disabled. Also, I checked the 3v3 line after the system got stuck, and it's just fine... fixed at 3v3

CrossRoads

So what is the capacitor voltage starting at and ending at?
Designing & building electrical circuits for over 25 years.  Screw Shield for Mega/Due/Uno,  Bobuino with ATMega1284P, & other '328P & '1284P creations & offerings at  my website.

brenin

It just goes to 3v3 when I power the circuit and stays there forever...

CrossRoads

And when it gets to 3.3V the circuit stops working? Watch it with a scope - does it ramp up smoothly, or does it look to have some switching noise or something on it?
Designing & building electrical circuits for over 25 years.  Screw Shield for Mega/Due/Uno,  Bobuino with ATMega1284P, & other '328P & '1284P creations & offerings at  my website.

brenin

#22
Mar 20, 2011, 06:08 am Last Edit: Mar 20, 2011, 06:10 am by brenin Reason: 1
As i pondered before, it was more like a coincidence that the circuit stopped working and it worked again when I discharged the capacitor.

It stops working long time after the capacitor charges completelly... It has a ripple noise of around 100mV... There are also some 300mV spikes..

CrossRoads

#23
Mar 20, 2011, 06:13 am Last Edit: Mar 20, 2011, 06:15 am by CrossRoads Reason: 1
That sounds like a really crappy power supply, or there is some other signal connected in.
What are you using for a power source?
With that size cap, it should be a lot smoother.
Designing & building electrical circuits for over 25 years.  Screw Shield for Mega/Due/Uno,  Bobuino with ATMega1284P, & other '328P & '1284P creations & offerings at  my website.

brenin

I might be getting somewhere in the other forum (avr-freaks: http://www.avrfreaks.net/index.php?name=PNphpBB2&file=viewtopic&t=104717&postdays=0&postorder=asc)... There was a suggestion that maybe my capacitor (which probably has relativelly high ESR) is introducing noise to the supply source with the raise of both the output capacitance and ESR for the supply source with the extra capacitor inserted.

CrossRoads, I'm using a L5973D based circuit using the 12V of a regular computer power supply. I'm getting a ripple of around 100mV...

Nick Gammon


I have a circuit and when I put a big capacitor (330uF) near the atmega, the atmega gets stuck after running for a while. When I discharge the capacitor the circuit works again for a while and then stops again. On oscylloscope, i saw that the circuit stops working after the capacitor charges.


I don't understand this bit. Until the capacitor charges, the processor does not have full VCC voltage, right? So it shouldn't be working before it charges. And you are saying it doesn't work *after* it charges. So it doesn't work at all, basically?

What the capacitor might be doing is confusing the processor with a slow VCC ramp-up. At a certain threshold the processor detects that VCC is high enough and initiates reset processing. But the very act of doing this causes extra power consumption (eg. pull-up resistors) which drops VCC down below operating voltage. The processor might be confused.

What might help is a capacitor/resistor on the reset pin that delays reset processing slightly.
Please post technical questions on the forum, not by personal message. Thanks!

More info:
http://www.gammon.com.au/electronics

brenin


As i pondered before, it was more like a coincidence that the circuit stopped working and it worked again when I discharged the capacitor.

It stops working long time after the capacitor charges completelly... It has a ripple noise of around 100mV... There are also some 300mV spikes..


Quote from: Nick Gammon link=topic=55711

I don't understand this bit. Until the capacitor charges, the processor does not have full VCC voltage, right? So it shouldn't be working before it charges. And you are saying it doesn't work *after* it charges. So it doesn't work at all, basically?


The circuit works after the capacitor is charged... It actually charges pretty fast, much faster then the time needed to get stuck...
What happens is that it stop working after running for some time (i.e hours on the first time it happens and up to minutes on the following occurrences)

TeslaFan

Off the top of my head, I think you're just using way more power supply than you need.

You have a switch mode regulator that can switch 2.5 amps powering a 3.3 volt circuit drawing a few milliamps or so.

And, to make it's life hard, you have a 330 uf capacitor on there too.

Add some resistive load. Make that regulator do at least a little work. That should also reduce the ripple on the 3.3 volt output.

"It stops working long time after the capacitor charges completelly... It has a ripple noise of around 100mV... There are also some 300mV spikes.."

See what's happening? When the regulator sees the voltage start to drop, it turns it's switch on and drives current through the output inductor. It can't just switch to a smaller switch when there's virtually no load on the output. The result is excessive ripple on the output. It's like using a firehose to fill a drinking glass.

Even though... it SHOULD be able to handle it better. I gotta wonder how far away from the regulator the circuit is, and if you have a large capacitor (330 uf or so) at the regulator as well.

The worst possible set up is the regulator more than a few feet away, with no output cap, and then the 330 uf cap right at the CPU.
Linux and Arduino, two great things that go great together!
http://www.roboticcore.com

wayneft

The datasheet for that regulator shows a 330uF cap on the output, however if you look at the BOM it's calling for a tantalum cap.  Crossreferencing the cap in the BOM shows it is a very low ESR cap (in the 40mOhm range).  If you have a tantalum cap at that value, try it instead and see if your problems go away.  If you only have electrolytic caps try placing several smaller caps in parallel to get to the 330uF value.  If the parallel approach works then it's possible the problem is with the ESR value.
I2C GPS Shield

Checkout my Open Source GPS Tracker on Kickstarter

Grumpy_Mike

Let's assume everything is connected as per the diagram (which is in some doubt).

If you can see the capacitor charging, then during that time the arduino is running on less that the supplies voltage output.
The fact that you can see it charging implies the power supply has quite a high input impedance.
When it does charge up the processor stops.

Possible causes:-
1) If a voltage regulator is fitted there is not enough voltage drop across it to make it operate properly when there is 5V on the output side.
2) The power supply is some value over 5V which is stopping the clock oscillator from working when the supply voltage finally reaches it.
3) A low voltage drop out regulator is being used. They don't like too much load capacitance as it makes them unstable.

However best guess is that there is something else going on.

Go Up