Uncategorized

rpi gpio driving pump

Asked 
Active today
Viewed 18 times
0

I am still a beginner in raspberry pi world. I have a 3 B+ and a small water pump that can work with 3V to 12V, and a multimeter that I use to measure voltage.

First when I measure voltage between pins 1 & 6, I can see a clear 3.3V, then when I measure voltage between pins 3 & 6, I also see a clear 3.3V. So far so good.

Then when I connect the water pump to pins 1 & 6, it works and I can see it move water from its input to output, but when I connect the pump to pins 3 & 6, it does not work. The weird thing is when I measure voltage between pins 3 & 6 while the pump is connected, the multimeter reads only 0.4V which is not enough to power the pump. What’s wrong here and why there is such inconsistency?

Thanks!

 New contributor
  • Ah let me see. Pin1 is 3V3 power pin, and can provide power to your little pump, without any problem. On the other hand, Pin3 is a logic level pin, which can set by python program to become High level, or Low level, to control for example a relay whose input terminal takes only a couple of mA which the GPIO pin can give. But your little pump might take more than 50mA which the GPIO pin cannot entertain, therefore kneels down. A get around is to use a “buffer” such as NPN transistor 2N2222, which can give 500mA. – tlfong01 2 hours ago   
  • The idea of a “buffer” is a little bit hard. You might like to read the following tutorial to get a better idea: “Digital Buffer Tutorial – Electronics Tutorials” electronics-tutorials.ws/logic/logic_9.html. “… Digital buffers can provide current amplification in a digital circuit to drive output loads.” – tlfong01 1 hour ago    
  • The idea of “amplifying” current is a bit weird”. One of the many ways is to use a transistor. If you wish to dig deeper, then I again recommend Electronics Tutorials: “Transistor as a Switch – Electronics Tutorials” electronics-tutorials.ws/transistor/tran_4.html “… Transistor switches can be used to switch a low voltage DC device, eg a LED, on or off.” – tlfong01 1 hour ago   
  • Electronics Tutorials stuff is a bit scary to beginners. For a more newbie friendly introduction to transistors such as 2N2222, I would recommend AdaFruit or SparkFun: :Transistors Tutorial _SparkFun: learn.sparkfun.com/tutorials/transistors/all. Happy learning. Cheers. – tlfong01 1 hour ago    
  • WARNING: It is a bad idea to drive an inductive load such as a motor/solenoid/pump using a buffer/switch such as 2N2222 or similar, because when switching off an inductive load, there will be a “Back EMF (Electro Motive Force) potential which drives backward the current being switch off and might fry the driving circuit, including Rpi. To play safe, a relay is usually used. References: (1) Raspberry Pi: Control Relay switch via GPIO – Rapiberrypi.com Tutorials tutorials-raspberrypi.com/…, / to continue, … – tlfong01 7 mins ago    
  • When selecting a relay, it is important to get a “HIGH LEVEL TRIGGERED” relay, because Low level triggered relays compatible with Arduino often do not work with Rpi An example of high trig relay is KY019: (2) AliExpress KY-019 1 Cheanel High Level Trigger 5V Relay fr.aliexpress.com/item/1914599302.html You can find more Rpi compatible relays here: (3) Rpi GPIO Controlling 5V Relay Problem raspberrypi.stackexchange.com/questions/99988/…. – tlfong01 2 mins ago    Edit   

1

Pin 1 is 3.3V power, and can supply up to 800mA (although it is inadvisable to connect a pump to the supply – particularly without any protection).

Pin 3 is a GPIO – if programmed as an output it can supply a maximum of 16mA. By default it will supply ~2mA (because it has a 1.8kΩ pullup) – neither is capable of running any kind of motor. Also connecting any inductive load without any protection risks damaging the Pi.

PS I hope you are NOT poking at the pins with a multimeter probe. Accidentally touching the adjacent pins 1 & 2 will instantly kill the Pi!

Categories: Uncategorized

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.

%d bloggers like this: