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

Bigtrout

Valuable Member
View Badges
Joined
Dec 16, 2018
Messages
1,189
Reaction score
2,826
Rating - 0%
0   0   0
@Bigtrout i just tested out the 2.3 builds, i think its fixed now. Can you test it out(just download the debian file and re-install) when you have time, and let me know if its still not working.

There was two different issues intermingled.. one involving the core pca9685 driver (i2c stuff), and the other around the reef-pi<-> pca9685 integration that was modified during the HAL work,.

Testing now, woohoo i think that has it...i have pwm, set it to 200hz and able to dim and brighten!! Ill do some meter testing later but it appears I can set the frequency now!!!

Many thanks!
 
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
Some macro shots from my biocube 29,
DSC_1548.jpg
DSC_1547.jpg
DSC_1545.jpg
DSC_1544.jpg
DSC_1543.jpg
DSC_1539.jpg
DSC_1537.jpg
DSC_1535.jpg
DSC_1533.jpg
DSC_1532.jpg
DSC_1527.jpg
DSC_1526.jpg
DSC_1525.jpg
DSC_1528.jpg
 

stefanm

Active Member
View Badges
Joined
Oct 11, 2017
Messages
360
Reaction score
397
Location
Sweden
Rating - 0%
0   0   0
@Ranjib I just reached home and checked my pi, the status claimed the chiller was on, but it wasn't, it was working as expected ( the pi), though I did reboot yesterday as memory use was constantly increasing.

I rebooted and the chiller came back on, so the relay didn't switch as instructed, I use a separate PSu for the relay board.

Is there a way to analyse this?
 
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 I just reached home and checked my pi, the status claimed the chiller was on, but it wasn't, it was working as expected ( the pi), though I did reboot yesterday as memory use was constantly increasing.

I rebooted and the chiller came back on, so the relay didn't switch as instructed, I use a separate PSu for the relay board.

Is there a way to analyse this?
Next time this happens, you have to check the GPIO state, and if its on, then reef-pi did its job, and something else is wrong, if not then its a bug in reef-pi itself.
You can check a gpio state like this
Code:
cat /sys/class/gpio/gpio<N>/value
where N is the pin number of outlet thats controlling the chiller. You expect the value to be 1 (assuming the outlet is not configured as reverse) when reef-pi is expected to turn the chiller on
 

crusso1993

7500 Club Member
View Badges
Joined
Oct 21, 2018
Messages
8,671
Reaction score
44,651
Location
SW, FL, USA
Rating - 0%
0   0   0
@Ranjib I just reached home and checked my pi, the status claimed the chiller was on, but it wasn't, it was working as expected ( the pi), though I did reboot yesterday as memory use was constantly increasing.

I rebooted and the chiller came back on, so the relay didn't switch as instructed, I use a separate PSu for the relay board.

Is there a way to analyse this?

Happy you caught it before anything too bad happened!
 

Bigtrout

Valuable Member
View Badges
Joined
Dec 16, 2018
Messages
1,189
Reaction score
2,826
Rating - 0%
0   0   0
Next time this happens, you have to check the GPIO state, and if its on, then reef-pi did its job, and something else is wrong, if not then its a bug in reef-pi itself.
You can check a gpio state like this
Code:
cat /sys/class/gpio/gpio<N>/value
where N is the pin number of outlet thats controlling the chiller. You expect the value to be 1 (assuming the outlet is not configured as reverse) when reef-pi is expected to turn the chiller on
Adding to this, if the gpio state is on, check the pin for an output, if its on and giving an output voltage, then reef pi, and the raspberry pi are functioning correctly. That leaves your wiring and relay board.
How much power does the chiller draw? Is it motor driven or some type if big inductive load?
The relay boards used with reef pi are good for general equipment, but the relays in both the American dj and the relay boards most of us use..are NOT rated for very much on an inductive type load.
 

crusso1993

7500 Club Member
View Badges
Joined
Oct 21, 2018
Messages
8,671
Reaction score
44,651
Location
SW, FL, USA
Rating - 0%
0   0   0
I did some verification with my Fluke meter, the PCA9685 is changing frequency as its supposed to, and duty cycle is correct, and looks like the 100 percent bug is gone as well, I can set my lights at 100 percent and they work!
Well done!!!

You must be stoked!
 

Bigtrout

Valuable Member
View Badges
Joined
Dec 16, 2018
Messages
1,189
Reaction score
2,826
Rating - 0%
0   0   0
You must be stoked!
Been playing around with frequencies and the auto settings...but right now the tank is dimming right down slowly, going to transition to dim moonlighting soon. Whats great is now I can run BOTH lights and dim them vs having to run one or the other on timers, overlapping to get 100 percent light for 2 hours and 50 percent for the rest of the time.
Now i can run all the white on both lights with a slow ramp up, 100 percent for 2 hours and a slow ramp back down!
 

stefanm

Active Member
View Badges
Joined
Oct 11, 2017
Messages
360
Reaction score
397
Location
Sweden
Rating - 0%
0   0   0
Adding to this, if the gpio state is on, check the pin for an output, if its on and giving an output voltage, then reef pi, and the raspberry pi are functioning correctly. That leaves your wiring and relay board.
How much power does the chiller draw? Is it motor driven or some type if big inductive load?
The relay boards used with reef pi are good for general equipment, but the relays in both the American dj and the relay boards most of us use..are NOT rated for very much on an inductive type load.


The load is only 6.7 amps (rated by the manufacturer, LG) at start up, the Hitachi compressor is 1100 watts @ 220~240 volts, so that's approx 5 amps, mostly our mains voltage hovers between 190-230 volts, so should be well in range of the relay, rated @10 amps 250 volts.
 

stefanm

Active Member
View Badges
Joined
Oct 11, 2017
Messages
360
Reaction score
397
Location
Sweden
Rating - 0%
0   0   0
Next time this happens, you have to check the GPIO state, and if its on, then reef-pi did its job, and something else is wrong, if not then its a bug in reef-pi itself.
You can check a gpio state like this
Code:
cat /sys/class/gpio/gpio<N>/value
where N is the pin number of outlet thats controlling the chiller. You expect the value to be 1 (assuming the outlet is not configured as reverse) when reef-pi is expected to turn the chiller on

Last night the timer didn't come on either for the fuge light (it was showing off status), I just tried a different schedule and it worked. It had been working properly for the past week.
 

stefanm

Active Member
View Badges
Joined
Oct 11, 2017
Messages
360
Reaction score
397
Location
Sweden
Rating - 0%
0   0   0
Same thing again, the chiller didn't come on, I've just done a shutdown and seems to be working normally, I played with the threshold settings to check and it's coming on.
 

Bigtrout

Valuable Member
View Badges
Joined
Dec 16, 2018
Messages
1,189
Reaction score
2,826
Rating - 0%
0   0   0
The load is only 6.7 amps (rated by the manufacturer, LG) at start up, the Hitachi compressor is 1100 watts @ 220~240 volts, so that's approx 5 amps, mostly our mains voltage hovers between 190-230 volts, so should be well in range of the relay, rated @10 amps 250 volts.
A compressor is a heavily inductive load with quite a surge on startup. Those relays are rated for 10 amps on a resistive load, and only 3 amps on an inductive load.
If it were me, i would use the small relay on the board to run a better rated relay for the chiller.
 

stefanm

Active Member
View Badges
Joined
Oct 11, 2017
Messages
360
Reaction score
397
Location
Sweden
Rating - 0%
0   0   0
A compressor is a heavily inductive load with quite a surge on startup. Those relays are rated for 10 amps on a resistive load, and only 3 amps on an inductive load.
If it were me, i would use the small relay on the board to run a better rated relay for the chiller.

Maybe, but the chiller has a relay on board, shouldn't that be sufficient?

I'm suspecting that the relay module could be faulty? or its PSU maybe not up to the mark (2 amps) I've had the issue return just now, the chiller should have switched on but didn't and I tried to switch the pumps off for feeding and nada, again I rebooted. I'm going to update to 2.3 incase it's a software issue, the ambient temperatures are ok to keep the temperature relatively stable without getting to high.
 

Bigtrout

Valuable Member
View Badges
Joined
Dec 16, 2018
Messages
1,189
Reaction score
2,826
Rating - 0%
0   0   0
Maybe, but the chiller has a relay on board, shouldn't that be sufficient?

I'm suspecting that the relay module could be faulty? or its PSU maybe not up to the mark (2 amps) I've had the issue return just now, the chiller should have switched on but didn't and I tried to switch the pumps off for feeding and nada, again I rebooted. I'm going to update to 2.3 incase it's a software issue, the ambient temperatures are ok to keep the temperature relatively stable without getting to high.
In a word, no, every relay that the conpressor power goes thru needs to be rated for the compressor load. My educated guess is this chiller is close to 1hp.
Those little relays are nowhere close to being the right relay for that, you said that the chiller is rated at 5amps, with a 6.7amp starting current. Compressors are inductive loads and the relays may be rated at 10amps but thats for a pure resistive load like a heater. The spec sheet on the songle relays, rates them at 3amps max on an inductive load. You are more than double that on start up...when selecting relays for repetitive use the general idea is to pick one thats rated double of the load you are switching, to prolong relay life.
Either use that relay to run another relay rated for a 1hp motor, or if there is a schematic it may be possible to control it with reef pi thru the chillers own controls.
 

16Reefer170

Community Member
View Badges
Joined
May 14, 2018
Messages
44
Reaction score
67
Rating - 0%
0   0   0
@Bigtrout i just tested out the 2.3 builds, i think its fixed now. Can you test it out(just download the debian file and re-install) when you have time, and let me know if its still not working.

There was two different issues intermingled.. one involving the core pca9685 driver (i2c stuff), and the other around the reef-pi<-> pca9685 integration that was modified during the HAL work,.

I downloaded and installed the 2.3 build when you first posted it. When I try wget it agin, it replies “the file is. Fully retrieved; nothing to do”. Any thoughts?
 

Bigtrout

Valuable Member
View Badges
Joined
Dec 16, 2018
Messages
1,189
Reaction score
2,826
Rating - 0%
0   0   0
I downloaded and installed the 2.3 build when you first posted it. When I try wget it agin, it replies “the file is. Fully retrieved; nothing to do”. Any thoughts?
Type in rm <filename of the downloaded reef pi> and it will erase it and you can wget it again
 

stefanm

Active Member
View Badges
Joined
Oct 11, 2017
Messages
360
Reaction score
397
Location
Sweden
Rating - 0%
0   0   0
In a word, no, every relay that the conpressor power goes thru needs to be rated for the compressor load. My educated guess is this chiller is close to 1hp.
Those little relays are nowhere close to being the right relay for that, you said that the chiller is rated at 5amps, with a 6.7amp starting current. Compressors are inductive loads and the relays may be rated at 10amps but thats for a pure resistive load like a heater. The spec sheet on the songle relays, rates them at 3amps max on an inductive load. You are more than double that on start up...when selecting relays for repetitive use the general idea is to pick one thats rated double of the load you are switching, to prolong relay life.
Either use that relay to run another relay rated for a 1hp motor, or if there is a schematic it may be possible to control it with reef pi thru the chillers own controls.

Understood, I can get a single relay module rated at 30 amps also states 1 hp, I'll order it today and should reach by Monday, just when I thought my fiddling had finished!
 
Back
Top