Hot tub remote

Wifi remote control for the Lay-Z-Spa

Similar projects worth following

This project is to enable remote control, monitoring and auto-restart after 24H of my hot tub pump. 

The hot tub is an early Bestway Lay Z Spa which has an external pump / heater / filter. The filtration pump and heater turn off after 24 hours (manufacturer intended feature), I check and bleed the pump daily - but not always at the same time (so some days it would be cooling down until I turn it back on, wasting energy)

Inside the pump unit there are two seperate controllers, one which deals with 230v power distribution to the heater, filter pump and massage blower, the other has a set of three seven segment displays and buttons which turn the heater, filter and massage blower on and off.

In the model i have the two controllers are connected via a three wire cable (Gnd, Data, 5v) which carries serial data in both directions. The bulk of the serial data is the main controller sending status messages and the temperature to the display controller.

The plan is to embed an ESP8266 in the form of a Wemos D1 Mini inside the hot tub pump which will host a web api and a webpage to control and monitor the pump.

  • 1 × ESP8266 WiFi Module

  • Signal timing and interface circuit woes

    ximon09/23/2019 at 12:18 0 comments

    Had a bit of a nightmare with the timing of the outgoing commands, i managed to get single bits to be the correct length (440us), but the timing changed when sending commands with multiple consecutive highs or lows. It turns out opto-isolators are pretty slow and building a suitable level translator with output enable uses too many components (in the sizes i have) to fit on the D1 mini proto board, so i'm swapping the interface circuite to use a single 74lvc1t45 instead. I'll update the schematics and code sometime this week.

  • A Weekend's work

    ximon08/11/2019 at 22:17 1 comment

    I've made a lot of progress over the past couple of days, the rest interface is mostly done, sending and receiving commands mostly works and I created a rudimentary test page. Check it out on Git hub

  • More timing diagrams

    ximon08/06/2019 at 22:38 0 comments

    I found a nice tool called WaveMe to draw the timing diagrams of the various messages passed back and forth between the main controller and the display controller. I've added the diagrams to the github repo here, the file is called signals.xml.

  • Getting Started

    ximon08/05/2019 at 14:22 0 comments

    I've finally got the motivation to get back on this project. 

    I've hooked up wires to the serial bus inside the pump and connected my OLS logic analyser to try and decode the signals. 

    I think i've figured out the pump state, heater state, blower state and temperature in C and F from the recorded signals.

    Last night I built a prototype of the hardware required to interface the ESP8266 3v3 to the pumps 5v bidirectionally.

    Tonight I'm going to carry on writing the code for the serial decoder.

View all 4 project logs

Enjoy this project?



zenntrix wrote 04/04/2020 at 20:38 point

Have you considered modifying your repo to also support the 4 cable control boards?

I am happy to help with that if you need.

  Are you sure? yes | no

asgeirholms wrote 04/24/2020 at 16:16 point

I'm in the same spot as you are :O I don't have all the know how to make this work for a 4 cable Laz-y-spa if you find a solution please let me know :) I'll do the same  

  Are you sure? yes | no

FunFR wrote 02/24/2020 at 13:31 point

Hi, thx for your work. Il will try to use it for my lay-z-spa Paris.

I already made a read-only esp8266 hack but now i want to manage it by remote.

Is your repo and the schematic up to date plz ?

  Are you sure? yes | no

Dominik wrote 08/10/2019 at 21:06 point

I saw that you updated the readme at GitHub with a lot of interesting stuff, is the ino file also completed already? :)

  Are you sure? yes | no

ximon wrote 08/10/2019 at 22:07 point

I'd just uploaded where i was up to so i could work on it at work on my lunch, it's not quite there but getting there - I've got a chunk of work ready to be committed after some testing tonight / tomorrow.

  Are you sure? yes | no

Dominik wrote 08/11/2019 at 19:47 point

I'm not sure if it will be possible to send within the 40ms, as there might be some fixed frequency.

I would rather go with 2 connections (Controller, Mainboard) and discard the messages sent from Controller to Mainboard. I just built a circuit for that and will try to do some tests next week. Furthermore it would be interesting to see which signals are sent by whom. If you disconnect the controller before startup, the Mainboard isn't sending any commands, so I think the Mainboard waits for some heartbeat from the Controller which can be seen on the Controller.

  Are you sure? yes | no

ximon wrote 08/11/2019 at 22:20 point

Sending in the 40ms window works fine, I tested it today (it's what the display controller does) do you have the startup waveform? I haven't logged it yet.

  Are you sure? yes | no

ximon wrote 08/05/2019 at 14:15 point

Back on this after some time away, I've committed my initial work on the web api to the github repo, will get on with the serial decoder tonight.

  Are you sure? yes | no

Dominik wrote 08/07/2019 at 20:16 point

I just had a look at your github repo and the signals with WaveMe. Have your aready successfuly initiated a button command (e.g. start pump) with your findings?  What do your mean with P0_.., PG_...?

Shall we continue the discussion here or on github? I have the same pump with 3-wires and connected my osci 2 days ago :)

  Are you sure? yes | no

ximon wrote 08/07/2019 at 20:26 point

Nothing sent just yet, I've just been building the decoder / encoder, I've updated the signals with better descriptions.

  Are you sure? yes | no

Dominik wrote 08/07/2019 at 20:44 point

Thx for the update of the signals. I haven't had all of them yet, but the ones I have look exactly the same :)

  Are you sure? yes | no

Dominik wrote 08/07/2019 at 21:15 point

Btw, my controlling unit sends signals all the time, therefore I'm not sure if we could just send a signal 'on the bus' or need to build a man-in-the-middle circuit to discard the signals from the controlling unit during the sending part. What do you think?

  Are you sure? yes | no

ximon wrote 08/10/2019 at 22:06 point

The display controller seems to just send them whenever and get away with it, my plan was to time it so that the commands were sent in the 40ms between commands from the pump controller - i'm just testing it now.

  Are you sure? yes | no

Dominik wrote 01/20/2019 at 16:44 point

Has anybody successfully implemented it? I'm just working on the same thing. I thought of

 - use the 3 wires between the input board and the 230v board

 - set the temperature/on/off/... values via the 3 wires

 - receive the temperature/on/off/... button presses and send the proper signals via the 3 wires

The only thing I'm concerned of is the status displayed on the input board as I'm not sure if I can set the status from the 3 wires. Has anybody decoded the serial protocol?

  Are you sure? yes | no

ximon wrote 08/07/2019 at 06:07 point

The signal diagrams are in my GitHub repo. The file is called signals.xml and was created with WaveMe.

  Are you sure? yes | no

ximon wrote 12/08/2018 at 19:08 point

That sounds exactly what I was hoping to implement, are you going to create a project for it on here?

  Are you sure? yes | no

Dominik wrote 08/07/2019 at 06:15 point

wow, thanks! I'll try it tomorrow.

  Are you sure? yes | no

mrQ7 wrote 12/08/2018 at 19:03 point

hi all, maybe i have what you are talking about?
my lay-z spa pump model 54123 has a 4 wire bus between display (DSP) an IO controller (IOC) (gnd,+5V, data up, data down). i inserted a controller module /w cellular support (no wifi 'cause i have no wifi in my garden/at the pool) at the plug between DSP and IOC. decoding the serial protocol was quite simple. at the moment i can replace the functionality of the DSP and play all it's control features my own. due to cellular uplink a have access to the
* current pool status (temperature, Exx, units active..), some
* history (e.g. for checking energy consumption and temperature curve) and 
* control parameters of my own scheduler
via an internet server.
my control software supports 10 schedule-able programms, freeze-protection at any selectable temperature (i use 8°C), stops the pump when not heating, switches air blower on/off as well as a "silent" mode to turn all noise off,... all of it with remote access, and some (blower on/off, siltent mode on/off) via local button. 
all these features work at the moment with a very rudimentary web page. i expect to finish the UI before end of year.
does this sound good to you?
ps: as an extra, my controller supports a dimmable RGB LED stripe, too

  Are you sure? yes | no

accarien wrote 05/31/2018 at 17:13 point

The page doesn't exist

  Are you sure? yes | no

Taylor wrote 05/30/2018 at 17:18 point

Here is someone else working on an Arduino modification:

  Are you sure? yes | no

Me wrote 12/22/2017 at 01:48 point

Hi all, this is not exactly what the project is about but I'll tell you how I achieved wifi control of my bestway spa for a little over $100.

Parts list:

1) TP-Link smart plug HS110 (~$35)

2) "Microbot Push" ($50)

3) Raspberry pi 3 ($35) & 16gb SD ($10)  [supposedly you can use a cheaper PiZero W as well]


1) Install TP-Link smart plug and configure & link to IFTTT via TP-Link Kasa

2) Download "Prota OS" image and write to SD Card; insert in RasPi

3) Install "Microbot Push" over spa heater toggle button using 2 sided tape

4) Install "Prota places" app on phone, setup "Prota Pi" within that and then setup "Microbot Push" within that.  You can then adjust the button-push distance down to 30-40%

5) Link Microbot Push to IFTTT


The "Microbot Push" does not activate the button (or any button) on the spa, presumably because it requires more capacitance.  I solved this by removing the rubber part of the button toggle and replacing it with the coiled end of some threaded copper wire (14awg) I had laying around.  About 4-5ft of wire is just hanging off the egg - not connected to anything.  My understanding of capacitance is limited to say the least but this seems to provide whatever oomph (surface area?) was needed to get the button to toggle every time in my testing.

Once everything's setup and talking to IFTTT then any measure of automation is within reach, including Alexa/Google Home or script-based control with webhooks.  You can't adjust the temperature (you could if you bought another Microbot Push and put it over the temp down button) but you can easily put the spa into three states:

1) Totally off (toggle off TP-Link switch)

2) On, pump only (toggle off, toggle on, push button once to activate heat & pump, push button a second time to deactivate heat, leaving just the pump running)

3) On, pump & heat (toggle off, toggle on, push button once to activate heat & pump)

It goes without saying that due to the time lock, all changes require a power cycle first.

Pros to this method include:

1) Warranty not voided

2) Safety features remain in effect

3) You can use TP-Link Kasa to see current consumption which gives you an idea of what the spa's doing (idle, pump, or heat+pump)

4) (if you're in California) You can link the TP-Link switch to Ohmconnect and get paid to automatically shut off your spa for an hour at a time like I do, while still having the ability to turn it back on after the end of the ohmconnect hour.

According to TP-Link, my "egg" consumes 1 watt in standby, 24 watts pump-only, 1201 watts pump & heat.  I did not test bubbles as I do not use them.  In our mild winter (60s day / 40s night) it consumes 14-15 kWh per 24 hour period to more or less stay at 40C/104F all the time.

Future plans include automatically turning the spa on and off throughout the day and night to conserve energy and ensure correct temps during our typical morning & evening use times.  I am also considering adding a simple temperature probe (DS18B20) to the raspberry pi running prota OS since it supports simple sensors on gpio out of the box.  That would give me some feedback on temps to further save energy.

Edit to add a few notes:

1) Added DS18B20 and successfully monitoring temperature as well as current/power.

2) The heater has two 600w elements and the egg does use just one of them in the beginning, though there is no way of seeing this from outside.  Also note that though the egg acts like the heater is on while the blower is firing, that's not the case. The heater gets turned off whenever the blower is on.

3) I can finally turn the heater/tub on and off throughout the day and night automatically!  In fact, I never have to touch the screen during normal use.

4) "Hey google turn on the spa" triggers a script that power cycles and then activates the heater.  I also added "Hey google how's the spa" and that voices the current temperature via a quick chromecast. Dumb cheap spa now fits in my futuristic house!

5) Here is my logic for inferring egg state from power usage (watts):

        if(spaPower < 2):
                spaState = 'On Standby' # usually ~1 watt
        elif(spaPower < 500):
                spaState = 'Circ pump only' # usually ~24 watts
        elif(spaPower < 1100):
                spaState = 'Half-heating'  # usually ~625 watts (600 + 24 pump)
        elif(spaPower < 1280):
                spaState = 'Heating' # usually ~1225 watts (600*2 + 24 pump)
                spaState = 'Blower'  # usually ~1325 watts (1300w blower + 24 pump)

6) Further reading:




  Are you sure? yes | no

Cory Verellen wrote 01/05/2018 at 01:54 point

A friend and I were discussing all this and ran across your mechanical finger method. Wonder if you could attach the Microbot to an XY controller?

  Are you sure? yes | no

Taylor wrote 09/13/2017 at 01:16 point

Here is an interesting design where someone replaced the core of the unit with an Arduino:

  Are you sure? yes | no

Taylor wrote 09/13/2017 at 01:07 point

Here is a video showing the parts inside. How would one start to reverse engineer this thing? 

  Are you sure? yes | no

ximon wrote 09/13/2017 at 07:51 point

Just on holiday, will post what I have when I get back. I have the older pump.

  Are you sure? yes | no

accarien wrote 07/04/2017 at 20:54 point

Hi, did someone manage to communicate with Bestway Lay-z spa ? Im very interrested.

  Are you sure? yes | no

Hogges wrote 02/10/2016 at 22:25 point

Bestway Miami. Same idea here. And trying to get it to go higher than 104...

  Are you sure? yes | no

ximon wrote 09/13/2017 at 07:57 point

The aim of this project is to just remotely control the existing controller, retaining its safety features. You'd have to reverse engineer the potted main control board to go higher than 104, a bit more work!

  Are you sure? yes | no

Hogges wrote 09/13/2017 at 09:54 point

Update on the temperature increase: This Spa uses a single resistive temperature sensor. I was able to solder a resistor in series in order to allow a small offset. Now the water temperature is always a couple degrees higher than indicated on the controls. 

  Are you sure? yes | no

ironreaper23 wrote 11/28/2015 at 19:15 point

Any progress on this?  I have the same spa kit and wanted to make it wifi enabled. My control board has more wire's out though.  8 wires and then a 4 wire plug.  

  Are you sure? yes | no

Similar Projects

Does this project spark your interest?

Become a member to follow this project and never miss any updates