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

MaccaPopEye

Well-Known Member
View Badges
Joined
Jan 5, 2016
Messages
697
Reaction score
1,234
Rating - 0%
0   0   0
So the PWM control in the jobs tab works great. I can program on and off dim points for both white and blue channels. The relays don't respond in either "on" or "off" state from the jobs tab.

Another note. If you toggle a relay "off" from the equipment tab, then navigate to another tab, when you return to the equipment tab it shows all relay state as "on"

Have you done a write up on the "Lighting" tab? This is the function that I am most interested in right now. I want to do sunrise to sunset dimming for my Chinese black box. Currently I can control it via the "equipment" tab via sliders. It would be super cool if we could set up lunar cycle via location.

I've decided to jump in and give this a go so I ordered a Pi, a bread board and some jumper cables the other night :D I will be ordering the relays and things needed for dimming this week.

I also have Chinese black box lights and the dimmer for them is 10V. I will need to control 6 dimmers now and 8 in the future. So the 16 channel PCA9685 is fine (I think) but to step up 6 channels (and in the future 8) to 10V will I need to get 2x L293D chips?
https://core-electronics.com.au/dual-h-bridge-motor-driver-for-dc-or-steppers-600ma-l293d.html
https://core-electronics.com.au/ada...t-pwm-servo-driver-i2c-interface-pca9685.html
 

Aaron Smith

Active Member
View Badges
Joined
Apr 9, 2017
Messages
250
Reaction score
273
Location
Oregon
Rating - 0%
0   0   0
I've decided to jump in and give this a go so I ordered a Pi, a bread board and some jumper cables the other night :D I will be ordering the relays and things needed for dimming this week.

I also have Chinese black box lights and the dimmer for them is 10V. I will need to control 6 dimmers now and 8 in the future. So the 16 channel PCA9685 is fine (I think) but to step up 6 channels (and in the future 8) to 10V will I need to get 2x L293D chips?
https://core-electronics.com.au/dual-h-bridge-motor-driver-for-dc-or-steppers-600ma-l293d.html
https://core-electronics.com.au/ada...t-pwm-servo-driver-i2c-interface-pca9685.html

Are the drivers PWM or 0-10v analog?
 

MaccaPopEye

Well-Known Member
View Badges
Joined
Jan 5, 2016
Messages
697
Reaction score
1,234
Rating - 0%
0   0   0
Are the drivers PWM or 0-10v analog?
I believe they are 10V PWM but I am not certain. I'm brand new to all this stuff so I'm still learning.

All the write ups and videos I have seen over the last day or two have said the POT dimmers have 4 incoming wires. An on/off wire, a 12V wire, a PWM wire and a ground wire. To use an LED controller apparently you have to jump two of the wires together to make the LEDs constantly on (I think it was the on/off and 12V wires) and then the PWM wire and the ground wire go to your LED controller. The write ups I have read or watched have all talked about 0-10V PWM
 
OP
OP
Ranjib

Ranjib

7500 Club Member
View Badges
Joined
Apr 16, 2016
Messages
9,848
Reaction score
17,081
Location
Pleasant Hill, Concord
Rating - 0%
0   0   0
So the PWM control in the jobs tab works great. I can program on and off dim points for both white and blue channels. The relays don't respond in either "on" or "off" state from the jobs tab.

Another note. If you toggle a relay "off" from the equipment tab, then navigate to another tab, when you return to the equipment tab it shows all relay state as "on"

Have you done a write up on the "Lighting" tab? This is the function that I am most interested in right now. I want to do sunrise to sunset dimming for my Chinese black box. Currently I can control it via the "equipment" tab via sliders. It would be super cool if we could set up lunar cycle via location.

A realy can be configured to be on by default or off by default, depending upon how you wire it. Theres a config under controller called high_relay, you can toggle it to reflect how you configured the relay. I'll recommend try enabling it and see if that fixes your problem (it should)
in /etc/reef-pi/config.yml
```
controller:
high_relay: true
```
Give the lighting cycle a try, and let me know if you encounter any issue. Its relatively new, and I am actively developing it.
 
OP
OP
Ranjib

Ranjib

7500 Club Member
View Badges
Joined
Apr 16, 2016
Messages
9,848
Reaction score
17,081
Location
Pleasant Hill, Concord
Rating - 0%
0   0   0
I've decided to jump in and give this a go so I ordered a Pi, a bread board and some jumper cables the other night :D I will be ordering the relays and things needed for dimming this week.

I also have Chinese black box lights and the dimmer for them is 10V. I will need to control 6 dimmers now and 8 in the future. So the 16 channel PCA9685 is fine (I think) but to step up 6 channels (and in the future 8) to 10V will I need to get 2x L293D chips?
https://core-electronics.com.au/dual-h-bridge-motor-driver-for-dc-or-steppers-600ma-l293d.html
https://core-electronics.com.au/ada...t-pwm-servo-driver-i2c-interface-pca9685.html

Thats awesome :) . I am here to help you with the build.
For your light, does each channel has dedicated +ve and gnd connection ? If so, get ULN2803a if not (i.e. LED channels have only dedicated +ve connection and a common gnd connection, like kessil do), then get a logic level p channel mosfet like FQP27P06
 
OP
OP
Ranjib

Ranjib

7500 Club Member
View Badges
Joined
Apr 16, 2016
Messages
9,848
Reaction score
17,081
Location
Pleasant Hill, Concord
Rating - 0%
0   0   0
I dont think it will be hard to get 0-10v analog output as well. There are several DAC ICs out there that works well with Pi. Also, we can use a digital potentiometer (will not be very energy efficient).

I am little busy with my scroll saw this weekend, but I am noting down all the issues, I''ll get back to fixing the software bugs once I am done with the 3rd build's housing :)
 

Aaron Smith

Active Member
View Badges
Joined
Apr 9, 2017
Messages
250
Reaction score
273
Location
Oregon
Rating - 0%
0   0   0
I believe they are 10V PWM but I am not certain. I'm brand new to all this stuff so I'm still learning.

All the write ups and videos I have seen over the last day or two have said the POT dimmers have 4 incoming wires. An on/off wire, a 12V wire, a PWM wire and a ground wire. To use an LED controller apparently you have to jump two of the wires together to make the LEDs constantly on (I think it was the on/off and 12V wires) and then the PWM wire and the ground wire go to your LED controller. The write ups I have read or watched have all talked about 0-10V PWM

What brand lights? I have galaxy hydro. Mine are able to PWM dim 0-5v, 0-10v and potentiometer.

If you have the lights, open up and look at the driver PCB. You will be able to tell how it dims. If needed post a pic.[emoji41]
 

MaccaPopEye

Well-Known Member
View Badges
Joined
Jan 5, 2016
Messages
697
Reaction score
1,234
Rating - 0%
0   0   0
Thats awesome :) . I am here to help you with the build.
For your light, does each channel has dedicated +ve and gnd connection ? If so, get ULN2803a if not (i.e. LED channels have only dedicated +ve connection and a common gnd connection, like kessil do), then get a logic level p channel mosfet like FQP27P06
What brand lights? I have galaxy hydro. Mine are able to PWM dim 0-5v, 0-10v and potentiometer.

If you have the lights, open up and look at the driver PCB. You will be able to tell how it dims. If needed post a pic.[emoji41]
Thanks Ranjib and Aaron. I have the mars aqua lights, I'll see if I can open one up tonight and get some pics of the insides to make sure I get the right parts for dimming :)
 

Aaron Smith

Active Member
View Badges
Joined
Apr 9, 2017
Messages
250
Reaction score
273
Location
Oregon
Rating - 0%
0   0   0
I dont think it will be hard to get 0-10v analog output as well. There are several DAC ICs out there that works well with Pi. Also, we can use a digital potentiometer (will not be very energy efficient).

I am little busy with my scroll saw this weekend, but I am noting down all the issues, I''ll get back to fixing the software bugs once I am done with the 3rd build's housing :)

I think you need a 3d printer! Another project I'd like to build!
 

Aaron Smith

Active Member
View Badges
Joined
Apr 9, 2017
Messages
250
Reaction score
273
Location
Oregon
Rating - 0%
0   0   0

Aaron Smith

Active Member
View Badges
Joined
Apr 9, 2017
Messages
250
Reaction score
273
Location
Oregon
Rating - 0%
0   0   0
A realy can be configured to be on by default or off by default, depending upon how you wire it. Theres a config under controller called high_relay, you can toggle it to reflect how you configured the relay. I'll recommend try enabling it and see if that fixes your problem (it should)
in /etc/reef-pi/config.yml
```
controller:
high_relay: true
```
Give the lighting cycle a try, and let me know if you encounter any issue. Its relatively new, and I am actively developing it.

I am assuming that "high_relay: true" will only change my state from normally open to normally closed?

Can you show me what to change in the config file for remote access from my tablet. My wife is gonna kill me if I stay in the office much longer! LOL!
 
OP
OP
Ranjib

Ranjib

7500 Club Member
View Badges
Joined
Apr 16, 2016
Messages
9,848
Reaction score
17,081
Location
Pleasant Hill, Concord
Rating - 0%
0   0   0
I am assuming that "high_relay: true" will only change my state from normally open to normally closed?

Can you show me what to change in the config file for remote access from my tablet. My wife is gonna kill me if I stay in the office much longer! LOL!


```
api:
address: "0.0.0.0:8080"
```
restart reef-pi service `sudo systemctl restart reef-pi.service`

after this you should be able to access the UI from any tablet, phone or laptop's browser, using the Pi's IP address (reef-pi dashboard will show the IP)
 

MaccaPopEye

Well-Known Member
View Badges
Joined
Jan 5, 2016
Messages
697
Reaction score
1,234
Rating - 0%
0   0   0
I will have to come back and read this in detail. I been slowly working on my own controller using a Pi. Here is my build thread (its on a different site. I have one here but its not as updated)

http://www.njreefers.org/threads/joys-of-diy-project.92252/
Awesome, now I have something to read for the rest of my shift :p I haven't quite decided which software I am going to go with yet, Ranjib's looks really good, but I really like the look of node red, then there is also JayFish which looks quite good as well. But atm I'm leaning towards ReefPi :)
 
OP
OP
Ranjib

Ranjib

7500 Club Member
View Badges
Joined
Apr 16, 2016
Messages
9,848
Reaction score
17,081
Location
Pleasant Hill, Concord
Rating - 0%
0   0   0
OP
OP
Ranjib

Ranjib

7500 Club Member
View Badges
Joined
Apr 16, 2016
Messages
9,848
Reaction score
17,081
Location
Pleasant Hill, Concord
Rating - 0%
0   0   0
Awesome, now I have something to read for the rest of my shift :p I haven't quite decided which software I am going to go with yet, Ranjib's looks really good, but I really like the look of node red, then there is also JayFish which looks quite good as well. But atm I'm leaning towards ReefPi :)
Thanks for the props :)
I had started working on reef-pi to solve my own problem, with a goal of making it easier, cheaper and hackable. Which mean reef-pi will never have any patents, always based on opensource software & hardware. I want to take time and build the software slowly, but with a steady cadence (if you notice its already a year old project). Happy hacking!
 

njtiger aquariums

Well-Known Member
View Badges
Joined
Oct 9, 2015
Messages
513
Reaction score
521
Location
NV
Rating - 0%
0   0   0
Thats awesome. Let me know if I can be of any help
Thanks. I might pick your brian on how you did the controls from the Kessil 360 but I'm no where ready for something like that. I have a ton of cleanup to do on my current system.
 

njtiger aquariums

Well-Known Member
View Badges
Joined
Oct 9, 2015
Messages
513
Reaction score
521
Location
NV
Rating - 0%
0   0   0
Awesome, now I have something to read for the rest of my shift :p I haven't quite decided which software I am going to go with yet, Ranjib's looks really good, but I really like the look of node red, then there is also JayFish which looks quite good as well. But atm I'm leaning towards ReefPi :)

Package software are nice but mine is coded using python, HTML, and some JavaScript. When I started this project, about 2 years ago, I didn't see many package software out there (or at least none found while I did my research). Personally I don't think I would use package software and that not because they are not good but more I like to do the coding myself and if there a bug I know my code so I know where to start looking
 

MaccaPopEye

Well-Known Member
View Badges
Joined
Jan 5, 2016
Messages
697
Reaction score
1,234
Rating - 0%
0   0   0
Package software are nice but mine is coded using python, HTML, and some JavaScript. When I started this project, about 2 years ago, I didn't see many package software out there (or at least none found while I did my research). Personally I don't think I would use package software and that not because they are not good but more I like to do the coding myself and if there a bug I know my code so I know where to start looking

Your thread was a good read :) it's coming along well. And I definitely understand where you are coming from with doing the software yourself.

The last coding I did was over 10 years ago in high school and I've only used HTML, basic and a bit of python so Im sure I could teach myself again with a bit of effort. If I go with pre made software it will be something like the one in this thread which is open source, so I can teach myself the language used and have a good understanding of the system. Wiring anything electrical (especially 240V) is 100% new to me and a bit daunting so that will be a new experience.

Initially I want temp monitoring (I live somewhere too hot for a heater so I don't care about control, I just need to know if my chiller bites the dust :p), 16 controllable outlets which I can assign some tasks to and dimming for my 3 Mars aqua lights (at some stage it will be 4). And I would like it all to be controlled / displayed on a tablet.

In the future I would like to add a solenoid on my RODI with a bunch of float switches to do automatic filling of my top off reservoir and general ATO functions. Then further down the line pH, salinity and ORP monitoring would be awesome but not required.

I also use aquarimate to monitor my parameters and remind me about tasks but I like how you included it in your software so I may consider something similar once I am happy with the majority of the controller.
 

HAVE YOU EVER KEPT A RARE/UNCOMMON FISH, CORAL, OR INVERT? SHOW IT OFF IN THE THREAD!

  • 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%
Back
Top