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

GaryE

Well-Known Member
View Badges
Joined
Mar 12, 2020
Messages
992
Reaction score
1,385
Location
Coatesville, Indiana
Rating - 0%
0   0   0
The technique to use is drag soldering. Big tips, big solder, flux, and a little wick to clean up the occasional bridge you can't clear with flux and a clean tip.



Its ok to literally have everything swimming in flux for this.


Yep, I've done that. Can be a pain to clean up bridges.

Here's my progress for today. A bit more cleaning and solder on the Thru Hole parts are hope the *&%^^#*(&^#@ works this time. ;)

1643941205958.png
 

bishoptf

Valuable Member
View Badges
Joined
Jan 1, 2019
Messages
1,349
Reaction score
1,724
Location
Missouri
Rating - 0%
0   0   0
The technique to use is drag soldering. Big tips, big solder, flux, and a little wick to clean up the occasional bridge you can't clear with flux and a clean tip.



Its ok to literally have everything swimming in flux for this.

Thats funny since that was the exact video that I watched today before deciding to take the plunge, its not my soldering skills that are that bad, the dang parts are so small and I have OLD eyes, lol. I need to figure out what kind of magnifier/light that will make it easier for me to see what the heck I am doing. That video he used a lot of flux, made it look easy, pretty hopefully I can figure it out, thats the only part they did not have in stock and has I think 28 legs, 14 on each side and pretty tiny. :)

I just wished I understood a fraction of electronics like you guys do, I get the basics but how you put circuits together to come up with a layout etc, I'm not even close. trying to replicate my JLPCB parts list on newark since I have a bare board and find even getting the right parts difficult, lol.
 

GaryE

Well-Known Member
View Badges
Joined
Mar 12, 2020
Messages
992
Reaction score
1,385
Location
Coatesville, Indiana
Rating - 0%
0   0   0
Thats funny since that was the exact video that I watched today before deciding to take the plunge, its not my soldering skills that are that bad, the dang parts are so small and I have OLD eyes, lol. I need to figure out what kind of magnifier/light that will make it easier for me to see what the heck I am doing. That video he used a lot of flux, made it look easy, pretty hopefully I can figure it out, thats the only part they did not have in stock and has I think 28 legs, 14 on each side and pretty tiny. :)

I just wished I understood a fraction of electronics like you guys do, I get the basics but how you put circuits together to come up with a layout etc, I'm not even close. trying to replicate my JLPCB parts list on newark since I have a bare board and find even getting the right parts difficult, lol.
I have a magnifying glass with a light that is mounted on my desk. Very handy. USB powered so it doesn't take up an outlet.

As far skills, I have few. Trial and error and the ability to read data sheets and schematics.

And still I screw up a lot.

Could have had an Apex by now.....
 
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
@Ranjib

Im a knuckle dragger :) .. what is the Prometheus query you are scraping here? 1643909843027.png
just the metric name, in this case displaytank_heater where displaytank is the name of the temperature probe. It represents the heater run time per hour for the controller operating using the probe name "display_tank"
 
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
Prometheus is a metric system , hence it only supports numeric values. We can use the labels feature for this instead.

I configure Prometheus config with the job name same as the reef-pi controller name , and then use the built in “job” label to display the controller name as job label value
i wanted to circle back and mention that you can use {{label}} to use the labels in legend, for example (notice the legend value.
Screenshot from 2022-02-03 19-12-59.png
 
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
Sorry for the newby questions. I can get a 3A+ starter kit from local micro center. Anything wrong with jumping in the water with this?
I like 3A. i have half a dozen builds that are on 3a
 

bishoptf

Valuable Member
View Badges
Joined
Jan 1, 2019
Messages
1,349
Reaction score
1,724
Location
Missouri
Rating - 0%
0   0   0
So maybe someone can riddle me this, I am trying to put some parts to order for one of these boards and looking for a 200ohm rn, in the bom he has listed R_Array_Convex_4x0603 but all I can really find for the package is 1206 like this one - https://www.digikey.com/en/products/detail/bourns-inc/CAY16-221J4LF/2566715

I think that will work but the package size is throwing me off, lol.
 

theatrus

Valuable Member
View Badges
Joined
Mar 26, 2016
Messages
2,223
Reaction score
3,632
Location
Sacramento, CA area
Rating - 0%
0   0   0
Thats funny since that was the exact video that I watched today before deciding to take the plunge, its not my soldering skills that are that bad, the dang parts are so small and I have OLD eyes, lol. I need to figure out what kind of magnifier/light that will make it easier for me to see what the heck I am doing. That video he used a lot of flux, made it look easy, pretty hopefully I can figure it out, thats the only part they did not have in stock and has I think 28 legs, 14 on each side and pretty tiny. :)

I just wished I understood a fraction of electronics like you guys do, I get the basics but how you put circuits together to come up with a layout etc, I'm not even close. trying to replicate my JLPCB parts list on newark since I have a bare board and find even getting the right parts difficult, lol.

The actual soldering is more technique and art than a hard science. A fair bit of frustration, but knowing anything is fixable, just don’t try to jam more heat than you need
Lol, now I can't find a lowly uln2803, these part shortage is pretty lame. :)
Yeah, it’s lame. If I’m designing something, I literally will place individual part semiconductor orders as I’m placing a part in a schematic because they sometimes can be gone 20 minutes later. Very shipping inefficient.

I had to risk buy a bunch of parts to certain projects so I have a non-trivial amount of cash tied up in silly things like voltage regulators and MCUs. Oh well.
 

robsworld78

Well-Known Member
View Badges
Joined
Feb 14, 2020
Messages
985
Reaction score
1,325
Location
Edmonton, Canada
Rating - 0%
0   0   0
Looking to get some of @Michael Lane goby hat boards made up and looks like pca9685pw are OOS everywhere, I assume @robsworld78 you are seeing the same thing, where are folks ordering from etc...just thought I would ask.
Yeah it's not fun ordering parts these days. I order 50 or more at a time and look well before I'm out so luckily it's all worked out.
I have a reflow gun, picked one up for christmas but still learning how to use it etc. I am going to give it a try...:)
Here's some solder paste I highly recommend, I've gone throw a ton of it but the last year I've not needed it much, the great thing about it is the shelf life. I have a tube I use that's well over a year old and it's still comes out the original needle perfectly. If you order the small container on Mouser it'll turn to rock in less than a week. Keep this stuff in a zip lock in the fridge and you'll always have it. They have other listings of multiple tubes which is cheaper per tube.


If you get one of these the needles screw right on the solder tube and you can use a plunger to push it out. I use the black tips.


I use this to solder all my pca9685's, just did 4 tonight. I simply run a thin line across all the pads, then I place the pca9685 on the pad, nearly blind like yourself, make sure it's straight and hit it with the hot air. The part is floating and will straighten perfectly if close to begin with. Then I take my fine tipped soldering iron and do the drag soldering technique which removes all the bridges and leaves a perfect job. No flux required. Important to have a very clean solder tip when dragging. I drag one side, clean tip, drag again, then repeat on other side. Takes about 2 minutes per part.

So maybe someone can riddle me this, I am trying to put some parts to order for one of these boards and looking for a 200ohm rn, in the bom he has listed R_Array_Convex_4x0603 but all I can really find for the package is 1206 like this one - https://www.digikey.com/en/products/detail/bourns-inc/CAY16-221J4LF/2566715

I think that will work but the package size is throwing me off, lol.

I believe each 4 resistors in the array are 0603 but the array package is actually 1206. I don't think there's an 0603 4 pack array, at least not for general use.
 

GaryE

Well-Known Member
View Badges
Joined
Mar 12, 2020
Messages
992
Reaction score
1,385
Location
Coatesville, Indiana
Rating - 0%
0   0   0
Unsure why this is happening, but my heaters are not turning on on one of my tanks.

I get an error message in the logs:

Feb 4 06:25:14 nempi reef-pi[6535]: 2022/02/04 06:25:14 Current value of 'temp' is below minimum threshold. Executing up routine
Feb 4 06:25:14 nempi reef-pi[6535]: 2022/02/04 06:25:14 ERROR: Failed to execute temperature control logic. Error: Item 'nothing' does not exist in bucket 'equipment'

1643973968231.png



1643974207646.png



I would assume the error is complaining about the chiller having "Nothing" in it's control.. I do not have a chiller. (can we get a toggle to disable that in cases where the equipment does not exist?) So I thought setting a threshold it would never reach would satisfy the issue, nope.. So, when my tank gets below "Heater Threshold" it tries to turn on the heat, but can't because there is a "Nothing" setting on the chiller ?

My other tank is setup the same way, same version of reef-pi and it's happily turning on and off the heaters..
 

elysics

Valuable Member
View Badges
Joined
Jan 15, 2020
Messages
1,591
Reaction score
1,590
Rating - 0%
0   0   0
PSA:

If you are relying on a PCA9685 for your dosers, it might be wise to incorporate a couple safeties.

If your I2C wiring is susceptible to interference and other problems at all, the signal to start up a pump might be sent through fine, while the signal to stop it might be lost or corrupted. Resulting in the pump running non-stop until the next command is send to the PCA9685.

Had it happen 5 times so far in a couple years (that i know of). Twice it emptied my alk reservoir, once my calcium reservoir.

Steps to mitigate this:

1: Create a dummy doser in the reefpi ui that controls a pin on the PCA9685 where nothing is connected. Run that "doser" every minute for a second or so. I didn't go through the code so I don't know whether this works 100% of the time, but to me, running another doser for a second seems to help the previous lost command go through or resets the pwm or something.

2: I have my pumps connected to the PCA9685 and to power via L298N modules. Previously, i had the pins that control direction hardwired to 3.3V. What you can do instead, is connect than pin to a GPIO and only enable it in the timeframe dosing should happen. I have it set to only activate for a window of 30 seconds at each time dosing should happen. This solution relies on just a voltage or lack thereof and no complicated communications that could be subject to interference. I have the relevant direction pins of all pumps wired together to a single GPIO. Now if everything goes wrong and the first safety fails too, the motor driver is only powered for a couple seconds longer than it is programmed to run normally, instead of potentially minutes to hours until the next scheduled dose.

If the second method fails too, that means reef-pi is hung up entirely, not sure how to fix that without introducing more complexity that can fail, but this has never happened to me.
 
Last edited:
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
Unsure why this is happening, but my heaters are not turning on on one of my tanks.

I get an error message in the logs:

Feb 4 06:25:14 nempi reef-pi[6535]: 2022/02/04 06:25:14 Current value of 'temp' is below minimum threshold. Executing up routine
Feb 4 06:25:14 nempi reef-pi[6535]: 2022/02/04 06:25:14 ERROR: Failed to execute temperature control logic. Error: Item 'nothing' does not exist in bucket 'equipment'

1643973968231.png



1643974207646.png



I would assume the error is complaining about the chiller having "Nothing" in it's control.. I do not have a chiller. (can we get a toggle to disable that in cases where the equipment does not exist?) So I thought setting a threshold it would never reach would satisfy the issue, nope.. So, when my tank gets below "Heater Threshold" it tries to turn on the heat, but can't because there is a "Nothing" setting on the chiller ?

My other tank is setup the same way, same version of reef-pi and it's happily turning on and off the heaters..
This is ui bug that by mistake sets the cooler equipment Id to nothing. Edit the temperature control and explicitly set the chiller equipment
 
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
PSA:

If you are relying on a PCA9685 for your dosers, it might be wise to incorporate a couple safeties.

If your I2C wiring is susceptible to interference and other problems at all, the signal to start up a pump might be sent through fine, while the signal to stop it might be lost or corrupted. Resulting in the pump running non-stop until the next command is send to the PCA9685.

Had it happen 5 times so far in a couple years (that i know of). Twice it emptied my alk reservoir, once my calcium reservoir.

Steps to mitigate this:

1: Create a dummy doser in the reefpi ui that controls a pin on the PCA9685 where nothing is connected. Run that "doser" every minute for a second or so. I didn't go through the code so I don't know whether this works 100% of the time, but to me, running another doser for a second seems to help the previous lost command go through or resets the pwm or something.

2: I have my pumps connected to the PCA9685 and to power via L298N modules. Previously, i had the pins that control direction hardwired to 3.3V. What you can do instead, is connect than pin to a GPIO and only enable it in the timeframe dosing should happen. I have it set to only activate for a window of 30 seconds at each time dosing should happen. This solution relies on just a voltage or lack thereof and no complicated communications that could be subject to interference. I have the relevant direction pins of all pumps wired together to a single GPIO. Now if everything goes wrong and the first safety fails too, the motor driver is only powered for a couple seconds longer than it is programmed to run normally, instead of potentially minutes to hours until the next scheduled dose.

If the second method fails too, that means reef-pi is hung up entirely, not sure how to fix that without introducing more complexity that can fail, but this has never happened to me.
I wonder if there’s a circuit /hardware based solution for this. I’ll think through what we can do on the software side.
over the years I realized I don’t need software control of speed for most dosing use cases. I just use a hardware based driver to change and set speed of the dosing pump (Dc) and let reef-pi just turn it on/off with a timer.
next version of reef-pi brings stepper integration, that may offer another approach to this
 

theatrus

Valuable Member
View Badges
Joined
Mar 26, 2016
Messages
2,223
Reaction score
3,632
Location
Sacramento, CA area
Rating - 0%
0   0   0
Yeah it's not fun ordering parts these days. I order 50 or more at a time and look well before I'm out so luckily it's all worked out.

Here's some solder paste I highly recommend, I've gone throw a ton of it but the last year I've not needed it much, the great thing about it is the shelf life. I have a tube I use that's well over a year old and it's still comes out the original needle perfectly. If you order the small container on Mouser it'll turn to rock in less than a week. Keep this stuff in a zip lock in the fridge and you'll always have it. They have other listings of multiple tubes which is cheaper per tube.


If you get one of these the needles screw right on the solder tube and you can use a plunger to push it out. I use the black tips.


I use this to solder all my pca9685's, just did 4 tonight. I simply run a thin line across all the pads, then I place the pca9685 on the pad, nearly blind like yourself, make sure it's straight and hit it with the hot air. The part is floating and will straighten perfectly if close to begin with. Then I take my fine tipped soldering iron and do the drag soldering technique which removes all the bridges and leaves a perfect job. No flux required. Important to have a very clean solder tip when dragging. I drag one side, clean tip, drag again, then repeat on other side. Takes about 2 minutes per part.



I believe each 4 resistors in the array are 0603 but the array package is actually 1206. I don't think there's an 0603 4 pack array, at least not for general use.
I’ve used the paste on board technique but somehow forget to try it all the time.

For general SMD assembly I’ve hard switched to Loctite GC10 (T4 size) paste. I do keep it stored refrigerated (next to all the super glue in one of those mini drink fridges), but it has amazing working time. I can stencil a board and place components a day later without issue. The smaller T4 size solder beads is amazing for not messing up smaller pitched QFNs and the like.
 

bishoptf

Valuable Member
View Badges
Joined
Jan 1, 2019
Messages
1,349
Reaction score
1,724
Location
Missouri
Rating - 0%
0   0   0
PSA:

If you are relying on a PCA9685 for your dosers, it might be wise to incorporate a couple safeties.

If your I2C wiring is susceptible to interference and other problems at all, the signal to start up a pump might be sent through fine, while the signal to stop it might be lost or corrupted. Resulting in the pump running non-stop until the next command is send to the PCA9685.

Had it happen 5 times so far in a couple years (that i know of). Twice it emptied my alk reservoir, once my calcium reservoir.

Steps to mitigate this:

1: Create a dummy doser in the reefpi ui that controls a pin on the PCA9685 where nothing is connected. Run that "doser" every minute for a second or so. I didn't go through the code so I don't know whether this works 100% of the time, but to me, running another doser for a second seems to help the previous lost command go through or resets the pwm or something.

2: I have my pumps connected to the PCA9685 and to power via L298N modules. Previously, i had the pins that control direction hardwired to 3.3V. What you can do instead, is connect than pin to a GPIO and only enable it in the timeframe dosing should happen. I have it set to only activate for a window of 30 seconds at each time dosing should happen. This solution relies on just a voltage or lack thereof and no complicated communications that could be subject to interference. I have the relevant direction pins of all pumps wired together to a single GPIO. Now if everything goes wrong and the first safety fails too, the motor driver is only powered for a couple seconds longer than it is programmed to run normally, instead of potentially minutes to hours until the next scheduled dose.

If the second method fails too, that means reef-pi is hung up entirely, not sure how to fix that without introducing more complexity that can fail, but this has never happened to me.

I wonder if there’s a circuit /hardware based solution for this. I’ll think through what we can do on the software side.
over the years I realized I don’t need software control of speed for most dosing use cases. I just use a hardware based driver to change and set speed of the dosing pump (Dc) and let reef-pi just turn it on/off with a timer.
next version of reef-pi brings stepper integration, that may offer another approach to this

Yes I have had a similar experience using the pca9685 and having it stuck on, in my case it was after a power outage and either the 9685 is failed closed or a resistor etc. I happened to be by my tank when it happened and I was able to pull the plug so to speak and stopped using pca9685 and have gone to brs 1.1ml dosers on an outlet controlled by a timer, and I have timers to force shutoff incase of a power outage etc. I could still have a failed relay stuck closed but i feel the likelihood is much less than having something go wrong with the pca9685.

Ranjib can you elaborate more on the hardware driver for a doser/timer method. I understand what you are doing but what kind of drivers are you referring too? The BRS pumps work but they are kind of noisy and looking for a quieter alternative, for my nano tanks I do not need something fast just quiet and reliable, lol.
 

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