Peristaltic pump in reverse

General project help for Adafruit customers

Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.
Locked
User avatar
lame_sauce
 
Posts: 9
Joined: Tue Aug 24, 2021 11:30 am

Peristaltic pump in reverse

Post by lame_sauce »

Hi All,
I'm working on a project and could use some help. I was wondering how I could run a peristaltic pump in reverse using circuit python. I have the pump turning on through a non latching relay attached to a FunHouse (code below). Any tips would be great!

Thanks

Code: Select all

import board
import time
import digitalio

water_pump = digitalio.DigitalInOut(board.A2)
water_pump.direction = digitalio.Direction.OUTPUT

water_pump.value = True
time.sleep(5)
water_pump.value = False

User avatar
adafruit_support_bill
 
Posts: 88086
Joined: Sat Feb 07, 2009 10:11 am

Re: Peristaltic pump in reverse

Post by adafruit_support_bill »

You can't do it with a single relay. To reverse a motor you need an 'H-Bridge' like the one on a TB6612B: https://learn.adafruit.com/adafruit-tb6 ... r-breakout

User avatar
lame_sauce
 
Posts: 9
Joined: Tue Aug 24, 2021 11:30 am

Re: Peristaltic pump in reverse

Post by lame_sauce »

adafruit_support_bill wrote:You can't do it with a relay. To reverse a motor you need an 'H-Bridge' like the one on a TB6612B: https://learn.adafruit.com/adafruit-tb6 ... r-breakout
Oh thank you I'll check this out!

User avatar
adafruit_support_bill
 
Posts: 88086
Joined: Sat Feb 07, 2009 10:11 am

Re: Peristaltic pump in reverse

Post by adafruit_support_bill »

Also check the current requirements of your motor. If it pulls more than 1.2A, you will need something with more current capacity like the DRV8871: https://www.adafruit.com/product/3190

User avatar
jps2000
 
Posts: 811
Joined: Fri Jun 02, 2017 4:12 pm

Re: Peristaltic pump in reverse

Post by jps2000 »

Of course you can use 2 relays wired like a h bridge
( single pole double throw relay contact)

Locked
Please be positive and constructive with your questions and comments.

Return to “General Project help”