Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Adding Temperature Probe to Heater

If we want to add a temperature sensor to the heater, we can add one to the outlet (see f in diagram below). 


Would add it to "f" - M 3/4" NPT

...

The Jandy LXi/JXi heater needs to be pinged (68 00 00) or sent a command at least every 20 seconds or it shuts off all settings and reverts back to its built in control panel. This means if you had a heat set point on the control panel before you initiated communication it will not resume heating to that temperature without physical interaction. So it's all rs485 or nothing. To turn the heater on in pool mode you send 68 0c e9. That's device 104, command 12, argument 233. (I think there are other command variations in the 0c range but I haven't explored further since i found what i needed). Spa mode is on is 68 0c ee. To continue heating you have to KEEP sending it commands at least every 20 seconds or the heater turns back off. Now that I think about it I'm sure there are 0c commands to turn the heater off without timing out and I'll track them down next. It responds with an 0d 08 if the heater is on or 0d 10 if the heater is off.

So, how do you know when to turn the heater on or off? You have to ping the temperature sensor using the 0x25 block. I've been sending it 68 25 00 but it may not need an argument. It responds with a 7 byte message. 25 33 xx 04 f7 f5 yy. The yy value is the temperature in Farenheit with 20 added for reasons. So 85 degrees would be 105, or 0x69 . 80 degrees = 100 / 64. The xx byte seems to be incrementing slowly except when my heater sat idle, so I presume it is the lifetime hours the heater has been active or maybe amount of gas used. None of the other values change so I have no info on them yet and they may just be filler. Regardless, I don't need any more info to write a controller, I just needed a way to check the current temperature and turn the heat on or off.

To summarize here's the logic loop the power center uses:
1) ping for unit presence about every 10 seconds: 68 00 00
2) get the temperature: 68 25 00
3) if the pool is below whatever the aqualink temperature is set to then also send a heater on command: 68 0c e9
4) ill bet there's a heater off command xx once if temperature is equal or above the set point. 68 0c xx .. or just let it time out.

I'm sure there's extra code to keep the heat from cycling on and off too quickly, and perhaps different heat levels...but this is enough to get started.
I have a Pi Zero that will have a web/api control panel. It will need a hardware stop/start button outside the unit so I can hand over control to the built-in keypad if necessary, plus an air-temp sensor for science.
Phase 2 will be adding my Hayward pump to the slave chain so it will kick up the GPM when the heater is on.
I don't suppose anyone has investigated the control of a Hayward pump?


Pool/Off/Spa Solutions

Micro Controller

For this solution, we are using a Sonoff SV controller. This is a nice controller since it has everything we need to control the heater's remote relays. Additionally, we can power it from the heater itself since it accepts 5-24 volts input and the heater will supply us with 10v. We are going to use the Sonoff SV in isolation mode by removing the two resisters that would normally supply the power to the controller using the input voltage.


Image Added

Wiring Diagram


Adding a Temperature Sensor

We are going to add a temperature sensor to the heater so that we can turn the heater on or off based on temperature.

We are going to use

  • Waterproof Digital Temperature Temp Sensor Probe DS18b20
  • a 1/2″ male NPT x 1/4″ compression fitting
  • 2 1/4" o-rings
  • 3/4" male NTP to 1/2" female NTP adaptor

  • teflon tape


Image AddedImage AddedImage Added



We can add one to the outlet (see f in diagram below). You may have a different setup, check your owner's manual for details.


Image Added


Since the header Type 'B' has a 3/4", we will need a 3/4" male NTP to 1/2" female NTP adaptor.


....





References

...