Hi! I am currently working on a circuit to controll a waterpump by buttonpress. I ordered the waterpump already and tested the button I have at home. I am using a relais module to controll the waterpump via RP. I looked online and other people did the same but instead of a battery I wanna try and connect it with a cable. What options do I have. Will a cut up phone charger be enough?
As long as the wall wart (the charger) will provide the voltage and current the pump requires that should be fine. You would probably need to use the generic power supply Fritzing part (search for “generic power supply” in the forum search bar to find the part) as I don’t know of a wall wart part for Fritzing.
Peter
What about the cable? I don’t want to cut up one of mine. Is there any cable I can purchase?
The wall warts use barrel jacks to connect (and there are barrel jacks in core parts), if the charger is for a cell phone then it likely uses a USB connector (although ti may also be a custom connector that isn’t available.) You do need to know what voltage and current it will provide and what voltage and current the pump requires to know if this will work. Selecting a wall wart that matches what ever the pump wants is your best bet though.
Peter
I am using this pump from amazon:
https://www.amazon.de/gp/product/B08BZBN29C/ref=ewc_pr_img_2?smid=AT0FJ7CZCB0G9&psc=1
The cable should work as long as the wall wart provides more than 200Ma of current. It would be unwise to plug the cable in to a USB socket and try and power the pump though. The pump is fairly likely to damage a USB connection, you want a wall wart that connects to the power line and provides 5V (i expect for USB at probably 0.5A) which should be fine to power the pump.
Peter
Ok thank you very much I will try it out!