Arduino heating up!

Hello everyone!

I had for a very long time the project of creating an automated aquarium project with an Arduino UNO.

I started my work towards that goal yesterday by hooking up a waterproof temperature sensor (https://www.gotronic.fr/art-sonde-etanche-ds18b20-19339.htm) to the Arduino and a simple LCD screen (https://www.gotronic.fr/art-afficheur-lcd-lmb0820-19017.htm) that will simply display the temperature of the water in the tank.

I then hacked a 50W aquarium heater (removing the thermostat) and connected it to a relay controlled by the Arduino, and wrote some basic code to turn the heater on/off based on a certain range of temperatures.

Everything works flawlessly up to now, no obvious problem, the relay, the temperature sensor and the lcd screen all work as expected.

And then I noticed that something was wrong...

I touched the Atmega328 chip on the UNO and noticed that it was quite hot, it made me a worried. When I then touched the linear voltage regulator, it was burning hot!

Something was obviously wrong... I thought about obvious possible problems, but since I'm still a beginner in the field I wanted to have some feedback from pros!

  1. I instantly thought about one of the components from my project driving excessive current ? But thinking about the connected components this seemed quite unlikely (they do not require so much current) ?

  2. I thought also about the power supply being at an excessive voltage (I'm using a 24V, 1A power supply) that I hooked to a buck converter lowering the voltage to ~8V and plugged the output of the Buck to the Vin pin of the Arduino, which if I'm not mistaken accepts between 7-12V DC ? So it shouldn't be the problem no?

  3. The Arduino is damaged and behaves in a weird way ? I noticed yesterday that even though the project prototype was working fine when the relay was switched on/off sometimes something was going wrong with the screen displaying some random weird text and freezes... I have genuinely no idea what this means?

If someone could give me some hints about this?

Best,

Tom

Remove all external components and check the temperature. If any component becomes hot, something on your board has died.

Then connect the external components, on after another, until you find which one causes the chips to boil.

A circuit diagram also would be very helpful, perhaps you made a mistake yourself.

Thanks for the advice!

I will link the schematics as soon as possible and do the testing this evening with a DMM to check where the problem is coming from,

Best,

Tom

What sort of relay is it (module or raw relay) ?
Is the relay coil powered directly from an Arduino pin, the regulated 5 volts or what ?
If it is powered by an Arduino pin, the coil resistance should be less than about 125 ohms.

Hi again,

@6v6gt : To answer your question the relay I'm mentioning is indeed a Duo relay module : Module 2 relais 5 Vcc GT114 - Modules à relais | GO TRONIC that apparently can be directly connected to the Arduino ?

Here is a schematic of the setup,

Thanks again guys!

Best,

Tom

Unless I have missed something, it all looks OK.
The relay coils probably use c 100mA each but the load is on the 5 volt regulated power supply, which should handle it without problems. Maybe check the coil of the unused relay is not energised.
The advice to remove components until the problem goes away is good.
You could also try powering the UNO through the USB socket instead of via the buck converter, to see if you have the same effect.

Thanks!

Good to hear that everything looks normal!

I'll do a testing session this evening to try and identify the problem and will update this thread,

Best,

Tom

Since you have a switchmode "buck" regulator, just calibrate it to 5 V and connect it to the 5 V line of your Arduino (and ground of course). Test all voltages.

That fixes the burning regulator, not sure why the 328 would be hot. :astonished:

Always "lose" the connection from the contrast potentiometer to Vcc. A persistent blunder that just will not die! :roll_eyes:

6v6gt:
Unless I have missed something, it all looks OK.

You have missed something - pretty much the most common blunder we see.

6v6gt:
The relay coils probably use c 100mA each but the load is on the 5 volt regulated power supply, which should handle it without problems. Maybe check the coil of the unused relay is not energised.

But as it stands, he does not have a 5 volt regulated power supply; he was deriving the relay power from the Arduino with its essentially useless on-board regulator.

Paul__B:
. . .
You have missed something - pretty much the most common blunder we see.
But as it stands, he does not have a 5 volt regulated power supply; he was deriving the relay power from the Arduino with its essentially useless on-board regulator.
. . .

As you worked out, I was using a less strict interpretation of "Regulated Power Supply". I simply meant the the power went through a voltage regulator. Exactly which regulator it is will depend on the version, clone etc.
But I don't believe that that alone would cause the overheating of the ATmega328p chip which the OP complained about.

My interpretation was to include a Regulated Power Supply fit for purpose. :grinning:


Looking at it another way, if it shuts down then, well, it is not regulated.

Hi guys,

Thanks for your answers!

I changed the Arduino Uno when I came back home, while keeping all connections exactly the same...

And well, it works without an issue!

The regulator is not hot and the Atmega328 neither, so I guess that the Arduino Uno I was using was broken or damaged...

@Paul__B : 1) "Always "lose" the connection from the contrast potentiometer to Vcc" ? Sorry I didn't get this one ?

  1. So if I understand correctly you would lower the output voltage from the buck up to 5V and just plug it straight to the 5V pin on the Arduino? And at the same time supply this 5V buck output to power up the relay as well? Sounds good! I wanted to keep the voltage higher, maybe even up to 12V to supply an LED strip with the buck output while still supplying the Arduino at the same time... But I guess this would overheat the linear regulator even more...

Thanks again!

Best,

Tom

The contrast pot should not connect to Vcc. This was a mistake in an early application note for the HD44780 that has been mindlessly copied since, which is a fascinating example of how readily things can be fouled up. The pot should only connect as a variable resistor between Vo - pin 3 - and ground. And a 1k works better in this case.

Yes, if you have a proper buck converter, use it to provide the voltage you actually require.

Hi,
I hate to complain but a schematic of your project, rather than a Fritzy picture may be a bit clearer.

Can you please post a copy of your circuit, in CAD or a picture of a hand drawn circuit in jpg, png?

Tom... :slight_smile:

Hi guys !

@Paul__B : Thanks! I think I got your point :slight_smile:

@TomGeorge : Here is a schematic of the current prototype

I changed up the system yesterday for an Arduino Mega since I wanted to add some components to the board.

The LCD is hooked up to digital pins 21-27, the temperature sensor is labeled as DS18B20 right next to it. I added a DC motor (Pompe péristaltique PPERIS - Pompes | GO TRONIC) 12V, 300mA max that will refill the tank whenever the level sensor (Détecteur de niveau NO FLSW1 - Niveau | GO TRONIC) (labeled LD on the scheme) is too low. The relay on the right (K2) is triggered by the temperature sensor and turns on a 50W heater if the temperature is too low. I also added a 3m LED strip (Kit ruban à leds RGB LEDS15RGB Velleman - Rubans à Leds | GO TRONIC) 12V, 24W that will latter be controlled based on the hour of the day (using a real-time module ex:ADA3296)...

I don't know if I should post it here or create a new post since the changes that are made are quite big ?

But I just wanted to ask you if all the connection look fine for you, and if you think that the power supply that I bought (Alimentation LRS50-12 - GO TRONIC) 12V, 50W for this project is enough ? Because all together the LED strip + motor + the rest should consume not more than 35-40W no?

Thanks again for you kind help,

Best,

Tom

Tomtop:
Hi guys !

@Paul__B : Thanks! I think I got your point :slight_smile:

@TomGeorge : Here is a schematic of the current prototype

I’m not sure whether you got my point at all!

I pointed out you should not have the contrast potentiometer connected to 5 V. Now you have it connected to a pin on the Mega! That is ridiculous! :astonished:

Hi !

@Paul__B : Well looks like I didn’t understand what you meant then :confused: … I’m still not sure I understand what you meant by “The pot should only connect as a variable resistor between Vo - pin 3 - and ground”, Why Pin3?

Is this the right way of doing it?

If I understand well connecting pin3 of the LCD to Gnd directly sets the contrast to max by default?

Sorry, just trying to learn… I’m not an engineer but would love to learn…

Best,

Tom

Umm, no!

You connect the potentiometer - 10k will work but 1k is better - with one end to ground, and the wiper to Vo - pin 3 - to control the contrast. The other end of the pot is not connected at all so it is acting simply as a variable resistor.

This will make it control the contrast - which you only really ever need to do once unless your supply voltage is varying or you encounter substantial changes in temperature - over a wider range and indeed, a 1k pot connected as a variable resistor will spread the contrast adjustment over its whole range instead of just at one end.

Removing the wrong connection to 5 V also reduces the current drawn by half a milliamp for what it is worth.

Thanks!

I think I understood !

Here it is :

Do you see any other inconsistencies on the current board?

Best,

Tom

Hi,
It might be a small thing, but instead of letting the LCD and Relay supply, 5V, current run through the Mega PCB, it would be better to connect them to the 5V going INTO the Mega.
edit12345.jpg

Tom… :slight_smile:

Tomtop:
I think I understood !
Here it is :

That’s right. :grinning:

TomGeorge:
It might be a small thing, but instead of letting the LCD and Relay supply, 5V, current run through the Mega PCB, it would be better to connect them to the 5V going INTO the Mega.
edit12345.jpg

Well caught. :grinning: It is most important that the relay supply does not come through the Arduino. The wires to it must both run together directly from the power supply (the buck converter).

It may be beneficial to put a 470 µF capacitor across the power wires at the relay board. The control wire also should run along with the power wires back to the power supply and then travel with the power wires to the Arduino board. All wires from one module to another must be bundled together as one unit.