Pool iAqualink driver

So I got a new pool and wanted to control the aqualink system via iaqualink 2.0 in Hubitat. The primary reason was that they only support Alexa and I use google assistant. But once I get some tablets setup it will be nice to see the status of some of the devices. Right now this driver only allows you to turn the 7or8 equipment switches on and off. Current limitation is that it only get the first pool controller serial number so if you have more I am not sure what will happen.

I am looking at a good way to put the pool temp and air temp show that it would show up well on the dashboard.

I used RByers reverse-engineered api document to develop the code. So it could break if jandy decides to change it.

Update 6/30/2020: Now available via Hubitat Package Manager

Once you setup the driver with user password info, you will need to click the get serial button.


I'm so excited by this, just finished mine too and can't wait to set this up. Was about to go another approach, this seems far less invasive.

Thank you, how may I donate?

This is amazing. I have many pools in my account (15) and it works perfectly for my personal pool using my serial # (I logged into iAqualink the manual way, copy and pasted my serial # into Hubitat). I am able to see the status and turn on/off most auxiliaries including my variable speed E-pump (Aux 1) as well as my Blower (Aux 4). However, I do not have control of my main filter pump (which is not an auxiliary) and do not have control of my color lights (watercolors) not even on/off even though they are Aux 3. Also, as stated no temperature read outs yet. I am happy to do any testing you need.

Awesome glad it's helping others too.

I will look at adding the ability to turn on and off the filter pump. The color lights, however, I do not have any of those so not exactly sure how they work or differ in the app. It might be a different api call that it would require.

With that many pools you should use the parentchild version that is on the github.

Also looking at adding a status to notify me if the iqualink status becomes offline as well.

On the parent child version I have added the FilterPump as an additional onoff device. I also added on the parent device a state variable "aqualink_status" to keep track of the aqualink connection of whether it is Offline or Online.

Ok, I'm a new ST grad - so I'm having trouble. I've added both Driver & ParentChild via Drivers Code, (couldn't figure out where to find Device# in Driver), but changed device to the ParentChild one and it pulled up my aux!

Added serial number, username & PW to ParentChild & Component Devices - and it SEEMS to know if they're "on" or "off".

But when I try and change them, I get this error in my logs.

dev:4202019-12-12 09:48:12.636 pm errorgroovyx.net.http.HttpResponseException: Unknown Reason on line 241 (off)

dev:4202019-12-12 09:48:10.661 pm infoToggle Device OFF Spa Light

dev:4202019-12-12 09:48:10.659 pm info4 on

I also added 2 more aux's, because your driver was only picking up my first 6, not 8. Now I can see my Stairs Lights!! I'm so close, yet still a "Hey google, turn on my spa lights." virgin.

You only need one or the other, You can remove the "aqualink-driver" one. I wrote that one first to just control one aux port then decided to write a driver that did all of the aux ports.

Is your spa light a color light?

hmmm I think my panel was only showing 6 but will test again though, and go up to 8 if it does not cause some issues.

Here were my additions, not that you need my help.

devices = GetDevices()
CreateChild("1", devices.devices_screen[3].aux_1[1].label )
CreateChild("2", devices.devices_screen[4].aux_2[1].label )
CreateChild("3", devices.devices_screen[5].aux_3[1].label )
CreateChild("4", devices.devices_screen[6].aux_4[1].label )
CreateChild("5", devices.devices_screen[7].aux_5[1].label )
CreateChild("6", devices.devices_screen[8].aux_6[1].label )
CreateChild("7", devices.devices_screen[9].aux_7[1].label )
CreateChild("8", devices.devices_screen[10].aux_8[1].label )
CreateChild("FilterPump", "FilterPump" )

Yes, 14 distinct options for both Spa & Pool Lights. Stairs & Kitchen are white leds. I love how "easy" this is to read it with my 0 knowledge of this script, and edit with reasonable success. :slight_smile:

Thank you again!!

Do you want to try and test the Color setting? Unfortunately, I did not spring for the color lights was already over budget on the pool itself.

Here is a direct link to the api doc. iAqualink protocol - Google Docs
its on last page.

If you turn on debug in your logs what does aux8 look like? Mine does not show aux8 but aux_EA. Does yours list that too? Mine is throwing errors on number 8 as well.

{aux_EA=[{state=0}, {label=AUX-11}, {icon=aux_1_0.png}, {type=0}, {subtype=0}]}]}

I only have 7 Aux live, and my 8th shows as Extra Aux/EA. Will absolutely try your colored LEDs, but still can't figure out how to Change a setting - but they are reporting accurately. Odd.

dev:3852019-12-13 10:04:44.851 pm infopool pump status 1

dev:3852019-12-13 10:04:44.831 pm info{message=, home_screen=[{status=Online}, {response=AQU='70','0B 00 01 02 03 05 06 07 09 0E 0F 1A 01 00 01 03 00 5B 00 63 00 30 00 64 00 00 00'}, {system_type=0}, {temp_scale=F}, {spa_temp=100}, {pool_temp=}, {air_temp=48}, {spa_set_point=99}, {pool_set_point=91}, {cover_pool=}, {freeze_protection=0}, {spa_pump=1}, {pool_pump=1}, {spa_heater=3}, {pool_heater=0}, {solar_heater=}, {spa_salinity=}, {pool_salinity=}, {orp=}, {ph=}]}

dev:3852019-12-13 10:04:40.087 pm errorjava.lang.NullPointerException: Cannot invoke method rundeviceupdate() on null object on line 200 (on)

dev:3852019-12-13 10:04:26.200 pm errorjava.lang.NullPointerException: Cannot invoke method getAt() on null object on line 108 (updated)

dev:3852019-12-13 10:04:26.071 pm info{message=, devices_screen=[{status=Online}, {response=AQU='72','8|1|2|3|4|5|6|7|32|0|1|0|0|Waterfall|0|1|0|0|Rockfall|0|1|0|0|Air Blower|0|7|2|4|Spa Light|0|7|2|4|Pool Light|0|1|0|0|Kitchen Ligh|0|1|0|0|Stair Lights|0|1|0|0|Extra Aux'}, {group=1}, {aux_1=[{state=0}, {label=Waterfall}, {icon=aux_1_0.png}, {type=0}, {subtype=0}]}, {aux_2=[{state=0}, {label=Rockfall}, {icon=aux_1_0.png}, {type=0}, {subtype=0}]}, {aux_3=[{state=0}, {label=Air Blower}, {icon=aux_1_0.png}, {type=0}, {subtype=0}]}, {aux_4=[{state=0}, {label=Spa Light}, {icon=aux_7_0.png}, {type=2}, {subtype=4}]}, {aux_5=[{state=0}, {label=Pool Light}, {icon=aux_7_0.png}, {type=2}, {subtype=4}]}, {aux_6=[{state=0}, {label=Kitchen Ligh}, {icon=aux_1_0.png}, {type=0}, {subtype=0}]}, {aux_7=[{state=0}, {label=Stair Lights}, {icon=aux_1_0.png}, {type=0}, {subtype=0}]}, {aux_EA=[{state=0}, {label=Extra Aux}, {icon=aux_1_0.png}, {type=0}, {subtype=0}]}]}

dev:3852019-12-13 10:04:24.506 pm infoupdated...

Did you have to customize any portion of:

line 234 void OperateDevice?

I'm curious that you and I cannot control our lights, (Aux 4 & 5) - but you can turn on/off your Aux 1 & 4. I can Toggle on/off my Pool Pump, and use every button besides "Off" and "On".

Updated the code to include 7 and added EA as well. Seems to work will now.

Can you turn on debugging and see what it says for aux 4 and 5?

I went to test this and none of my Aux devices work now. I had them working just fine using the individual driver but when I replaced it with the parent/child, I can see the status for the Aux devices but lost control of them. It looks to me like the parent is getting the correct status but the children are not working. I'll need to check the driver code to see if I can tell what changed from the http request on the individual vs the parent/child driver. The individual worked great so long as you enter your serial #, credentials, and aux # into the settings of the device.

dev:8112019-12-16 06:33:38.462 am errorgroovyx.net.http.HttpResponseException: Unknown Reason on line 241 (on)

dev:8112019-12-16 06:33:37.626 am infoToggle Device ON Air Blower

Sorry, pulled from wrong HE. I have updated the github repo. Was not sending the command to the parent to make the call to iaqualink on the github version.

Let me know if that fixes it for you.

I think the last pull came from the original driver, that includes Device #, vs ParentChild driver. Although now I'm starting to understand how each are different. I can put the Aux # on Device, and it seems to pull it directly. Still can't control any, but I'm getting very close. I'm going to keep cracking at it, but it's like giving a monkey a gun - but I enjoy this!!

Anything you need from me (logs), let me know.

The original update threw errors at the original get session, where it didn't prior.

Download the Hubitat app