Arduino rebooting when shut down relay + 110V + transistor + diode + desk lamp

Pelleplutt:

Pelleplutt: First: Do it work with the 110 volt unconnected? If so, try a PMR209MC6100M100R30 across the relaycontacts.

The capacitor (100uF) should be placed between the powerlines near the relaydrivertransistor on the breadboard.

Pelle

In reply #3 I suggested a snubber circuit PMR209MC6100M100R30 across the rely contacts.

The capacitor on your breadbord looks like a small ceramic disk, not as a 100uF electrolytic. And closer to the other components.

Pelle

Thank you Pelle.

I just plugged any capacitor just to represent the position of that.

Zapro: That's why i posted a drawing. Sigh...

The RC snubber needs to be across the contacts of the relay.

You will never need to connect anything between Arduino and mains wiring, -that stuff is really dangerous.

// Per.

Thank you Zapro.

I saw your drawing.

Pelleplut recommended a capacitor model but how about the resistor?

What resistor should i use?

My recommended component are a RC combination There are a capacitor and a resistor in series. A complete snubbercircuit. Read the datasheet.

Pelle

Pelleplutt: My recommended component are a RC combination There are a capacitor and a resistor in series. A complete snubbercircuit. Read the datasheet.

Pelle

Thank youfor the answer.

I think that is better to buy a relay module for arduino.

Pelleplutt: My recommended component are a RC combination There are a capacitor and a resistor in series. A complete snubbercircuit. Read the datasheet.

Pelle

Is this what you're talking about?

This is a snubber circuit with capacitor and resistor?

https://www.elfa.se/elfa3~eu_en/elfa/init.do?item=65-635-22&toc=19366

Jepp

Pelle

Pelleplutt: Jepp

Pelle

I will try that.

Thank you.

I just set up the circuit. NPN & relay (common emitter set-up), the contacts click a desk lamp (120 vac) with a 40W bulb. The relay has a "6V" coil, but I'm running it (through the NPN) from 5V -- the Arduino 5V. It goes on, off, on, off... as it should, as I knew it would: No Glitches, No Problems.

To me, all of this "snubberation" stuff is absurd.

I hate "escapes", so I tried this powered from the usb connector and same-same, good-good.

The 10K base resistor is too high for the transistor to completely switch the relay's coil to ground. Try replacing with 330 ohm (ideal) to 1K max.

You may also need to use a separate power source for the relay coil rather than the Arduino. We don't have the part number of your relay, but it's datasheet should specify the coil resistance and/or coil current.

BTW - I HATE “fritzing”, it’s a goofball tool
(Maybe I’ll add that to my signature line.)

pinout.JPG

Hi there.

I bought a relay module and the problem keeps happening.

I will try to use a lower resistor as dlloyd suggested.

I did not tried with another desk lamp yet.

physyx:

Zapro:
That’s why i posted a drawing. Sigh…

The RC snubber needs to be across the contacts of the relay.

You will never need to connect anything between Arduino and mains wiring, -that stuff is really dangerous.

// Per.

Thank you Zapro.

I saw your drawing.

Pelleplut recommended a capacitor model but how about the resistor?

What resistor should i use?

I know that when I use a type pnp transistor to control my 12v LED strips I end up using 20k of resistance, or 2 10k ohm resistors, when I only use a single 10k resistor, my fade on my light strip is not correct and full brightness can not be achieved. if you are going to fade or dim the light at all, you have to match the gradients of your two voltages, thus 20k worth of resistance might be what you need to properly control your relay. just a guess, but it could be the reason your relay is surging and cutting power to your Arduino. Hope this is helpful. -jay