Hayward AquaConnect Device Handler

project_pool
dth_pool

(Steve Tremblay) #1

Hi everyone,

I’m sharing here my WIP Aqua Connect device handler for Hayward Pool Automation. It’s working well, but features are a bit limited by the architecture of the Aqua Connect bridge.

Still you can view current status of the pool lights, heater, filter and aux relays + control the lights, mode and filter easily. Sadly, the mode/lights will not show current status after a change right away, but it will at next refresh, this is also due to the AquaConnect architecture.

You can also view current Pool/Spa temp (for spillover spas).

Code will need to be adapted a bit for led statuses based on your configuration. I also recommend using Pollster to refresh the device.

Anyway, I’m posting to see if there is anyone looking for this, then I can give more info if you want to try it !

Here is the handler :

https://github.com/SteveTheGeekHA/AquaConnectDeviceHandler/blob/master/AquaConnectDH.groovy

As usual with IP based devices you need to configure the device with the HEX encoded IP/Port, there is a lot of doc on this in this forum.

Steve


#2

Hi Steve…

Im looking to add the AquaConnect to my SmartThings as well. Just getting into the community, so still fumbling with setting up my account. Will be looking to you for further support once I get through the developer setup and documentation. I have found the Hayward API for serial communication, but not the Home Network interface API. Assume they should be close, so will go through your work and see where to begin. Thanks for the start…

R.D.


(Steve Tremblay) #3

With pleasure !

Sadly it’s not really an API, but I kinda watched how the device replied to the web browser and leveraged it :wink:


(Jamie Sanbower) #4

Steve,

Does the code need to be modified to put in IP/Port of the AquaConnect?


(Glenn Beck) #5

Hi Steve, I’m new to ST and was trying to get my Aquaconnect integrated via your code. I pulled the code from GitHub but when I added the device it doesn’t show anything. I wasn’tb sure what type of device to choose when I created it, and I don’t see where to add the converted IP? It’s not clear to me as to how ST can talk to the controller…
Thanks,
Glenn


(Steve Tremblay) #6

Hi Glenn,

You added my device handler and added the device from the Graph API console ? Did you set the ID as the encoded IP/PORT of the device ?

Steve


(Glenn Beck) #7

Thanks Steve, that’s what I needed. I had to set the device network ID as 50 so that it would be seen as 80? (0A000170:50)

Once I did that then it works. This app is awesome!

2 more questions:
The temperatures are not showing in ST, is there something that I need to modify in the code?

You mention pollster, but it’s there a native function in ST now that can be added to refresh?

Thanks again,
Glenn


(Steve Tremblay) #8

Hi Glenn,

The native refresh is kinda bad, sometimes it refreshes, sometimes it doesn’t. That’s why I use pollster.

And the temperature is linked. The way AquaConnect works is that it shows the line currently shown on your P4 display in the webapp and that’s what I read to get the data. So each minute or 2 minutes with Pollster I take what’s there and if it’s Spa or Pool temperature, I update the value. It’s not that great, but it’s the only way as there is no access to the raw data…

Steve


(Glenn Beck) #9

That makes sense. Kind of highlights what a poor job Hayward did on their design. It’s a shame they don’t redesign and push everything to the cloud and expose the API’s so we can leverage them. They had a good idea but fell short on the follow through, or maybe it’s just not a big enough market for them to focus on so it was a learning experience for their newer products.
I haven’t figured out for to use pollster yet but I’ll take a look at it and see if I can get it going. I just got my ST hub and have been enjoying seeing all the possibilities, this could get expensive. :slight_smile:
My ToDo list will probably keep me busy for a while:TappecuepHinCyberstatGarageDoorBuddyXFinity sensors - I suspect those are locked down since it’s part of home security… I moved all of my plugs to ST but would love to get at the door sensors and smoke detectors that have to stay on the XFinity zigbee network.

SteveTheGeek Steve Tremblay
January 2 |

Hi Glenn,

The native refresh is kinda bad, sometimes it refreshes, sometimes it doesn’t. That’s why I use pollster.

And the temperature is linked. The way AquaConnect works is that it shows the line currently shown on your P4 display in the webapp and that’s what I read to get the data. So each minute or 2 minutes with Pollster I take what’s there and if it’s Spa or Pool temperature, I update the value. It’s not that great, but it’s the only way as there is no access to the raw data…

Steve

Visit Topic or reply to this email to respond.

In Reply To

glenn-beck
January 2 |

Thanks Steve, that’s what I needed. I had to set the device network ID as 50 so that it would be seen as 80? (0A000170:50) Once I did that then it works. This app is awesome! 2 more questions: The temperatures are not showing in ST, is there something that I need to modify in the code? You menti…
Visit Topic or reply to this email to respond.

To unsubscribe from these emails, click here.


(Steve Tremblay) #10

Agreed, it’s a TERRIBLE design from Hayward. Not having a simple API to get the data easily is ridiculous…

Pollster is pretty easy, you install it and tell it which device to update and how often.


(Daren) #11

This is great. I didn’t think anything like this existed. I am afraid I am really new at this. Just installed my smart things hub today and still figuring out how all this works. Is there a step by step guide how to get this installed? I would appreciate any help.


(Steve Tremblay) #12

Hi sir ! I did not create a step by step guide, but I can surely help.

You have the AquaConnect on your home network, same as the Smartthings hub?

If so, do you know the IP address of the AquaConnect?


(Daren) #13

Sorry it took so long to respond. Got buried at work. Yes, the SmartThings hub is connected and I have already tested it with a light switch I just installed and my garage door. Having fun with it.

I can find out the IP address of my AquaConnect via my router. So yes.


(Steve Tremblay) #14

Great, so you need to configure the device with the HEX encoded IP/Port, there is a lot of doc on this in this forum. But basically, you encode in hexadecimal each part of the IP + the port also.

This becomes the device ID in Smart things. Then the device handler should communicate well with the device.


(Daren) #15

When you say configure the device you mean the Smarthings hub or the AquaConnect hub? I am assuming if I search HEX I should find what I need?


(Steve Tremblay) #16

You need to manually add your AquaConnect device with my device handler in the web Graph API console.

The device id needs to be:

HEX_IP:HEX_PORT with each number of the IP converted to 2 characters HEX

So for instance, my AquaConnect device id is:

C0A85631:0050

Which equals to :

C0 = 192
A8 = 168
56 = 86
31 = 49

So my hub IP is 192.168.86.49

And the port is 0050 in HEX which is 80. This is the normal port to talk to the AquaConnect, so it should be the same for you.


(Daren) #17

Oh OK that makes sense. Let me look at your code and take a stab at entering it.