reef-pi :: An opensource reef tank controller based on Raspberry Pi.

Ok. I am planning on starting with (4) relays.
(1) white led on / off
(1) blue led on / off
(1) return pump
(1) wave maker

White channel 5v pwm dimming on daytime cycle

Blue channel 5v pwm dimming on daytime cycle.

Eventually add in the analog sensor IC
 
Ok. I am planning on starting with (4) relays.
(1) white led on / off
(1) blue led on / off
(1) return pump
(1) wave maker

White channel 5v pwm dimming on daytime cycle

Blue channel 5v pwm dimming on daytime cycle.

Eventually add in the analog sensor IC
You have a 4 channel relay? If so, declare 4 outputs of type relay with pi gpio pins, and two output with pca9685 pin , type pwm
 
You have a 4 channel relay? If so, declare 4 outputs of type relay with pi gpio pins, and two output with pca9685 pin , type pwm

I have an 8 relay board. But was keeping it as simple as possible for now.

I followed your fritz diagram to hook up the pca9685 but I don't know anything about the pins or numbering etc.

I didn't see a diagram for the relay board so it's just sitting.

Forgive my ignorance on all this. I love electronics and want to learn more. I figured if I dove into it, that would be the best way to learn!
 
Do you have an example for the board section of config. I think I figured out the outlets and pins. They don't show up on the browser yet though.
 
Outlets assigned to pins, equipments are assigned to outlets. What you see in browser is equipment, outlets are hidden. The example config in github I shared before should give you a hint. I'm outside now, will grab the necessary links once I'm home
 
Outlets assigned to pins, equipments are assigned to outlets. What you see in browser is equipment, outlets are hidden. The example config in github I shared before should give you a hint. I'm outside now, will grab the necessary links once I'm home

No worries here I am happy with how far I got so far!

The browser shows dashboard/electronics/equipment/ etc. I think this is what is confusing me.
4ca38ef151fe782103af60c9ef284f1e.jpg


What I have so far

5702021395253cafb9949b6c485e4201.jpg


Nothing showing here though.
 
Ooh, hoo .. party time :-) . Remember to assign the GPIO pin number for relay correctly, they are not contiguous , this is the reference: http://www.jameco.com/Jameco/workshop/circuitnotes/raspberry_pi_circuit_note_fig2.jpg
For example pin number 7 (denoted in green circle) is GPIO4, so in configuration file, use 4. For PCA9685 just use contiguous pin number (starting from 0 till 11).
Once you declare an output as pwm type in config, the equipment using that output will automatically have a slider, to control the pwm value. For LED lights this will dim it, for DC pumps it will vary the speed (can be used to do nice wave makers).

you should be able to combine any equipment and action (on/off, set pwm values) for setting up periodic jobs.

Godspeed
 
Following along, you guys are doing a great job! Now that my tank is showing signs that it has cycled I am hoping to be able to start developing something to use as a controller (in between coming into the home stretch for our wedding next month).
 
Following along, you guys are doing a great job! Now that my tank is showing signs that it has cycled I am hoping to be able to start developing something to use as a controller (in between coming into the home stretch for our wedding next month).

Congrats!!
 
@Ranjib
I have relays working along with 2 channels pwm. After editing the config file, the browser still shows the old equipment from the original, along with my new added equipment labels. Any ideas why the old labels are sticking around?
 
everytime you change the config file with new or modified equipments, delete the data base and restart reef-pi service
```
sudo systemctl stop reef-pi.service
sudo rm -rf /var/lib/reef-pi/reef-pi.db
sudo systemctl start reef-pi.service
```
also, when you visit browers, do a Cmd +Shift + r (refresh with cache delete)
I should revisit the config based equipment, may be revert back to UI based equipment/outlet management...
 
everytime you change the config file with new or modified equipments, delete the data base and restart reef-pi service
```
sudo systemctl stop reef-pi.service
sudo rm -rf /var/lib/reef-pi/reef-pi.db
sudo systemctl start reef-pi.service
```
also, when you visit browers, do a Cmd +Shift + r (refresh with cache delete)
I should revisit the config based equipment, may be revert back to UI based equipment/outlet management...

I have certainly learned a lot by the way it is now, it just leads noobs like me to questions.[emoji3] I am gonna keep learning away, however you set it up. I do think the UI adressing is cool though.
 
Ranjib, a few days ago I asked about wiring using the PCA9865 board and a transistor for 0-10V. I see Adafruit's example python code for the breakout on their website ( https://github.com/adafruit/Adafruit_Python_PCA9685/blob/master/examples/simpletest.py ), but I'm wondering if you could possibly share your python code for dimming? If not no big deal, I know some python but could definitely use a head start on this particular library and program!

Thanks!!
 

IF YOU HAD TO TAKE A REEFING EXAM, WOULD YOU PASS?

  • Yes!

    Votes: 32 45.7%
  • Not yet, but I have one that I want to buy in mind!

    Votes: 9 12.9%
  • No.

    Votes: 26 37.1%
  • Other (please explain).

    Votes: 3 4.3%

New Posts

Back
Top