Water pump issues please help!

Hi Everyone,

I'm working on a project that needs a 5 V water pump to be switched using an Arduino. But the system also uses sensors that need a 5 V feed. Initially I had the pump on a digital pin that switches to high when the conditions from the sensors are met but this won't work because it needs 130 mA minimum to function and if I'm not wrong, the digital pin can only supply 40 mA.

My first thought is to switch the circuit around a bit, both the sensors need less than 40 mA and 5 V so in theory could I use the digital pins for their power supply? That would free up the 5 V pin which my research suggests can supply 800 mA (more than enough for the pump to draw), issue then becomes switching as the pump only needs to come on at certain times.

The alternative is to use a digital switch and the same 5 V source for all but not sure how this would work and I've got quite a short deadline!

I'd really appreciate some input on this one!

, might be on interest or not.

You do not need a pin to feed your sensors. They can be fed from 5V pin.
Your pump should not be fed from arduino power supply. It will draw far more current during startup. This can give a power dip that will restart your Arduino. Put it on a separate supply. An old usb phone charger should do.
Control it from arduino with a mosfet or a relay or a motor controller (if you want to run it at variable speed).

Thank you! That's definitely something I can use for the report offering ways to overcome the issue. I'm hoping to make it work with the components I have but if not this is a brilliant solution.

Thank you! I think I may need to admit defeat on the prototype and show a theoretical circuit that would do the job!

The thing to get your head around is that the microcontroller (arduino) is not a power supply. It only supplies logic (low current, low voltage signals). You use this logic signal to activate some form of electronic switch if you requite a device to be powered (eg transistor, mosfet, relay). You need to draw schematics which you can do on paper or use free online software such as Kicad, Easyeda or similar. Fritzing seems to impress people that are new to the sport but is not recommended.

When designing test circuits (that demonstrate your logic) you can use LEDs in place of components. Just call one LED the 'pump' and when it is on it represents the pump being on. That is enough to show functionality and will work on a breadboard. The arduino can power LEDs with an appropriate resistor. When you convert to a prototype you obviously replace the LED with the 'switch' for the real component although many people retain an LED to show when things are on/off (you might want to move it to the power side rather than logic side though).