Issue Relay module

I'm making smart farm where i'm using
Ldr to control led
Dht11 to control 5v fan
And water level to control pump

And iam using relay module 5v to control the pump

But when the relay works it flickers resting the whole system

And when i disconnect the relay everything works fine

Welcome to the forum

Please post a schematic of your circuit showing the components used, how they are interconnected and powered

A 'photo of a hand drawn circuit is good enough

To post images etc. you need trust level 1, you can get there by:

  • Entering at least 5 topics
  • Reading at least 30 posts
  • Spend a total of 10 minutes reading posts

Users at trust level 1 can...

  • Use all core Discourse functions; all new user restrictions are removed
  • Send PMs
  • Upload images and attachments

If it is a DC motor, add a kick back, free wheel diode across the motor.

Have a look at this forum topic, it sounds similar to what you are doing with a solution to your problem

2 Likes

give links to the specific modules you are using?

what voltage/current is the pump?

relays used with arduino type dev boards are typically rated 250volt/10amp resistive load - when controlling an inductive load such as a squirrel cage motor reduce the rating to 2 to 3amps

e.g. recently controlling a Jabsco_28520_pump I used a ESP32 driving a 3.3V relay which switched a Contactor, LC1D, 12 A, DIN Rail, 230 VAC, 3PNO, 3 Pole, 5.5 kW to control the pump

I find it good idea to use screened cable to connect the microcontroller relays to the contactor/pump


See post #4 on how to fix the problem.