Cheap, Simple web-enabled pool automation with Google Assistant Integration

Can you tell me how to do temperature control with this or the Sonoff using a 10K thermister?

Sonoff makes a th10/th16 switch that will read a DS18b20 temp sensor. I think you can get it to turn something off and on based on the temperature.
 
  • Like
Reactions: skola28
How do you integrate a temp probe? I don't see a way to do that on the 4 ch version. Do you use something like IFTTT? I would prefer to simply wire the 10K thermister directly to the Sonoff.

Chris

Temp probe connects with a separate SONOFF TH16. There isn't a way to do it directly on the SONOFF 4CHPROR3 (that I know of!). I was going to use IFTTT to control the heater from a remote temp sensor, but it turns out that wasn't necessary!
 
I'm of your same mind for my pool controller: no coding, no soldering! Try to avoid it wherever possible. Does ewelink allow you to map a button to a simple webhook call? If so, you could use the nodejs-poolcontroller program on a raspberry pi to act as a protocol translator. Send it a properly formatted web request and it'll convert the language to RS-485 commands that your VSF pump understands without all the coding.

At the moment, Ewelink does support what they call "DIY Mode" and you can also flash it with Tasmota. Both I think will get us what we're looking for. I believe someone figured out the RS-485 protocol commands for the my Pentair VSF, so that'll be on the 'to do list' for next year.
 
I'm of your same mind for my pool controller: no coding, no soldering! Try to avoid it wherever possible. Does ewelink allow you to map a button to a simple webhook call? If so, you could use the nodejs-poolcontroller program on a raspberry pi to act as a protocol translator. Send it a properly formatted web request and it'll convert the language to RS-485 commands that your VSF pump understands without all the coding.

Not for nothing, but once you are willing to put a pi out there for a protocol translator, why not have the pi do everything?
 
WOW, what an amazing write up! Awesome project. I am trying to do something similar but much simpler. I just want to hookup a "MHCOZY 4CH WiFi RF Wireless Switch" (link - which is basically a Sonoff from what I can tell) to a Jandy actuator.

I set it all up and it would not work. Spoke to my supplier who sent out a new Jandy - when it arrived I noticed that the original one looked old. Part of me thinks it might have been faulty, and the other part of me thinks that I fried it by connecting it wrong - and so I'm not game to hookup the replacement until I am more confident - hence my post.

I have set the button to "momentary press mode".

Is there any chance that you can review the photo below and confirm if the connection is correct? (I have a 1amp fuse on the V+)

View attachment 169400

I'm NOT an electrical expert, but what you've hooked up looks correct. HOWEVER, I don't know how your relay is setup - I don't know for sure if 'center' is the common and the other two are the Normally Closed/Open contacts. I also don't know what your voltage is actually set to -- looks like there is a voltage adjustment on your power supply. Make sure you check that its at ~24V with a voltmeter.

Lastly, make sure your "MHCOZY 4CH WiFi RF Wireless Switch" is compatible with 24V power in.
 
Ok, the hookup looks correct EXCEPT I noticed something else. My valves are 24V AC. It looks like you have a 24V DC power supply. If your valves are 24V DC, you should be OK.
Good catch. I know of 4 different valve manufacturers, they all use 24V *AC*.
 
  • Like
Reactions: Katodude
>> Ok, the hookup looks correct EXCEPT I noticed something else. My valves are 24V AC. It looks like you have a 24V DC power supply. If your valves are 24V DC, you should be OK.

OMG God! You're right! It is 24VAC. I'll swap the power supply out and give it a go!
Do you know how many AMPS the sonoff needs to work? I found a 24VAC power supply that supplies 1amp, and my handy needs 0.75 amp leaving 0.35amps for the MHCOZY(same as the SONOFF)
 
Last edited:

Enjoying this content?

Support TFP with a donation.

Give Support
Do you know how many AMPS the sonoff needs to work? I found a 24VAC power supply that supplies 1amp, and my handy needs 0.75 amp leaving 0.35amps for the MHCOZY(same as the SONOFF)

I don't know how many Amps the SONOFF needs, but its likely not much. Again, I'm not an expert, but having too low of Amps provided by the power supply I don't think will ruin anything, but it will just likely be intermittent. I did notice that the MHCOZY has a 5VDC USB Mini power input that looks like you could use as well. Additionally that tells me that its likely the MHCOZY system runs on 500ma or less as I think that was the original USB standard current requirement.
 
Album Link with Diagram and short demo video:

Using a SONOFF 4CHPROR3, I have integrated the control of my Filter Pump, Booster Pump, and two Jandy JVA Actuators.
I have a Jandy Aqualink RS (older) which the pool guy wanted $$$$$$ to change out to a simple web interface with very few relays expandability.

Reusing the DPST relays, 24VAC Transformer, and Jandy JVAs. Most of the wiring is already complete -- just have to remove the Jandy Control Board and strip the leads. Too bad the relays aren't 24VAC or it would be even easier!

$28 SONOFF 4CHPROR3
$18 24VDC Power Supply
$9 SONOFF TH16
$3.50 SONOFF Temp Sensor-DS18B20

About an hour and a half to setup HW and another hour to setup the SW.

The 4th channel is for lights. I also added a SONOFF TH16 to automate the heater temperature and use the built in Google Assistant routines to 'Turn on the Hot Tub'.

Left side of the channel 'triangles' is the Normally Open (NO). Right side is Normally Closed (NC) while the center is common.
View attachment 169211
View attachment 155164
(Note, this image is out of date as it doesn't show the lighting circuit and the TH16 heater controller)

EDIT: Updated wiring diagram and description to include lighting and heater circuits.
Hi.
I have a jandy JXI with three wires for remote control. “Pool-off-Spa”. Would you happen to know if I can use the TH16 to control it? If so, how would it be wired?
Thanks in advance.
 
Hi.
I have a jandy JXI with three wires for remote control. “Pool-off-Spa”. Would you happen to know if I can use the TH16 to control it? If so, how would it be wired?
Thanks in advance.
Is this the unit you're talking about?



If so, it seems like you'd hook it up almost exactly the same way I did.
NOTE you MUST modify the TH16 circuit board to isolate the input voltage and make the TH16 into a 'dry contact' relay. Some websites call this "isolated mode". The device is designed to pass its line voltage from the input side of the card, to the output side of the card. You need to modify it so that the power no longer goes to the relay. If you're handy with a soldering iron and a Dremel, its not too hard.

After modifying the TH16 circuit board, you'd hook one wire of the TH16 up to the POOL screw and the other to the COMMON screw. According to the manual, you'll also need to adjust the service settings through your Jandy JXi Touch Pad: (reference here: https://www.jandy.com/-/media/zodiac/global/downloads/h/h0574300.pdf)

7.2.2 Configure the Control Panel:
• Make sure the pool heater is OFF.
• Press and hold MENU, then the POOL and SPA
buttons for 5 seconds to access Service Setup mode.
NOTE: The display will revert back to OFF 1 minute after the last key press.
• Press MENU, REMOTE OFF (default) is displayed.
• Use Up or Down to scroll through the Remote
options until REMOTE TSTAT is displayed, then
press MENU to select.
• Press POOL or SPA to exit Service Setup mode.
• Press POOL or SPA to adjust the set point to the
maximum 104°F (40°C).

Then, whenever the TH16 is set to "ON" manually, or if automatic temperature range mode is selected, the heater will turn on. Remember though, you MUST turn on your filter pump first. Normally, your heater won't kick on without the filter on, as there is a safety pressure switch, but don't rely on it!
 
Last edited:
This is the same way most automation systems use to control the heater. You are just using the Sonoff to trigger the "fireman's switch". I've been using this method for years, it's so simple and just works!
 
  • Like
Reactions: skola28
Is this the unit you're talking about?



If so, it seems like you'd hook it up almost exactly the same way I did.
NOTE you MUST modify the TH16 circuit board to isolate the input voltage and make the TH16 into a 'dry contact' relay. Some websites call this "isolated mode". The device is designed to pass its line voltage from the input side of the card, to the output side of the card. You need to modify it so that the power no longer goes to the relay. If you're handy with a soldering iron and a Dremel, its not too hard.

After modifying the TH16 circuit board, you'd hook one wire of the TH16 up to the POOL screw and the other to the COMMON screw. According to the manual, you'll also need to adjust the service settings through your Jandy JXi Touch Pad: (reference here: https://www.jandy.com/-/media/zodiac/global/downloads/h/h0574300.pdf)



Then, whenever the TH16 is set to "ON" manually, or if automatic temperature range mode is selected, the heater will turn on. Remember though, you MUST turn on your filter pump first. Normally, your heater won't kick on without the filter on, as there is a safety pressure switch, but don't rely on it!
Thanks for the help. This is exactly the one I have. Mine is the 260. Glad I found this post. It’ll be a fun project. It’ll be a few months before I get started, but when I do I’ll be asking you some questions if you don’t mind.
btw. I used to be an avionics “specialist” in the AF also. F-16’s block 30s. What did you work on ?
 
Thanks for the help. This is exactly the one I have. Mine is the 260. Glad I found this post. It’ll be a fun project. It’ll be a few months before I get started, but when I do I’ll be asking you some questions if you don’t mind.
btw. I used to be an avionics “specialist” in the AF also. F-16’s block 30s. What did you work on ?
Happy to help! I've worked on several cockpits over the years; mainly rotary wing (CH-47F, CH-53K) but also some fixed wing C295 and C-130. Collins Aerospace (my employer) does the cockpit interfaces on those aircraft including the mission computers and flight displays - Lots of exciting stuff!
 
Thanks skolar,
I just setup my pool automation by using Sonoff 4CH PRO R3, which control ON/OFF on 2 pumps (cleaner and spa jet), solar heater, and SWG. I have few questions:
1. Using eWelink (version 4.11), setup start time and stop time, needed 2 schedules separately (on eWelink tutorial It showed need only 1 schedule for ON/OFF)? and there is no loop time feature?
2. I stay at home everything works OK, but if far away from home (with my setup mobile phone) then all devices are turned ON but did not turn OFF? so weird.
 
Thanks skolar,
I just setup my pool automation by using Sonoff 4CH PRO R3, which control ON/OFF on 2 pumps (cleaner and spa jet), solar heater, and SWG. I have few questions:
1. Using eWelink (version 4.11), setup start time and stop time, needed 2 schedules separately (on eWelink tutorial It showed need only 1 schedule for ON/OFF)? and there is no loop time feature?
2. I stay at home everything works OK, but if far away from home (with my setup mobile phone) then all devices are turned ON but did not turn OFF? so weird.
I run my On/Off schedule through Google Home Routines instead of through the eWelink app "schedule" function so I can't really help there.
For mine, I go to the Google Home app, click Routines, and I have two routines defined: "Clean the pool" and "Stop cleaning the pool"

"Clean the Pool" has two triggers:
1: When I verbally say, "Hey Google, Clean the Pool"
2: When the time is 8:00AM everyday
When Triggered, the routine will "adjust lights/plugs and more"
1 - [Outside] Spa Mode set to "Turn Off"
2 - [Outside] Pool Filter set to "Turn On"
3 - [Outside] Pool Cleaner set to "Turn On"
All the rest are set to "Don't Change"

"Stop cleaning the pool" similarly, has two triggers
1: Verbally saying "Stop cleaning the pool"
2: When the time is 4:00PM everyday
When Triggered, similarly, the routine will
1 - "Turn pool cleaner off"
2 - "Turn pool filter off"
The above two commands were created by doing an "Add action" > "Try adding your own" and then simply typing in the words that would normally command the Google Assistant to change settings.

Its essentially the same as the method for "Clean the Pool" above, but a slightly different implementation. I just wanted to try it out.

The only time I run into issues is if my internet is down at 8AM or at 4PM as the routines then do not run. There are ways around this with the LAN mode on eWeLink but I really haven't found it to be much of a problem ... yet!
 

Enjoying this content?

Support TFP with a donation.

Give Support