Sebs reef-pi Build

Ranjib

7500 Club Member
View Badges
Joined
Apr 16, 2016
Messages
9,876
Reaction score
16,680
Location
Pleasant Hill, Concord
Rating - 0%
0   0   0
In case anyone is interested. I wrote a small program to control the pumps that were not communicating with the reefpi software. It automated the phing process for me.

def ph_reading():
device = atlas_i2c(99)
ph_value = device.query("R")
return ph_value

def job():
ph_set = 5.5
print (ph_set)
while True:
curr_ph = round(ph_reading(), 1)
print("Current pH: %s" % curr_ph)

if 5 >= curr_ph <= 6:
break

elif curr_ph >= ph_set:
# Turn on pump supplying acid_pump
rr.set_motors(0,0,0.8,1)
print("Dispensing acid...")
time.sleep(3)
rr.stop()

time.sleep(60*3)

schedule.every(5).minutes.do(job)

while True:
schedule.run_pending()
time.sleep(1)
This is very nice @Sebastian Stankiewicz . I always wanted to write a python binding for reef-pi api , but never got the time to work on it. Very happy to see you all still using the raw circuits using their own bindings
 

Ranjib

7500 Club Member
View Badges
Joined
Apr 16, 2016
Messages
9,876
Reaction score
16,680
Location
Pleasant Hill, Concord
Rating - 0%
0   0   0
@Ranjib Unfortunately I didn't get it to work. I used this code to specify the pins
dtoverlay=pwm-2chan, pin=14, func=4, pin2=24, func=4
But it did not work.
I missed this. Is it still an issue ? I am happy to help diagnosing this if you are interested
 

TOP 10 Trending Threads

WHAT AMOUNT OF LIVE ROCK AND SAND SHOULD BE PRIORITIZED FOR OPTIMAL BIODIVERSITY/FILTRATION?

  • 100% live rock + bagged sand

    Votes: 37 27.8%
  • 100% dry rock + 100% live sand

    Votes: 45 33.8%
  • 50/50 live/dry rock, 50/50 live/bagged sand

    Votes: 29 21.8%
  • 75% live rock, 25% live sand

    Votes: 12 9.0%
  • 25% live rock, 75% live sand

    Votes: 10 7.5%
Back
Top