Closed SchallertDK closed 2 years ago
are you on a 4-wire pump? Auto discovery isn't implemented yet on the 4-wire firmware...
Yes i have. How do i so do? :)
You have to manually add in the sensors at the moment - using the code and help in the repo https://github.com/visualapproach/WiFi-remote-for-Bestway-Lay-Z-SPA/tree/master/Code/Home%20assistant%20config
Thank you, I will try to set it up. But i'm not an expert at this HA yet :)
It's not too difficult if you follow the readme, and go slowly. Best bet is to just test ONE sensor, such as the bubbles as a switch sensor. If you then see it in HA, and can toggle it, and the bubbles go on/off - you've cracked it(!) carry on with importing the rest of the sensors!
Best of luck!
Dev branch version has now autodiscovery for 4 wire pumps. You are welcome to test it.
Ohh i may test! My efforts worked, but the climate wouldn't import for me.
Will try the new dev branch......
Ohh i may test! My efforts worked, but the climate wouldn't import for me.
Will try the new dev branch......
I had some trouble too. Turned out the message was too long for the ESP to handle so don't use long base names.
Ahhh - i was getting there.... cutting down the packaged worked. Good to know I was on the right track!
Just added a PR for model NO54154 as it was missing AIR in the config @visualapproach.
Alright, will handle it when !AFK
Auto discovery worked really well - but the God Mode switch didn't import into HA?
My HA went in "Safe Mode" after trying adding new "text"
I made a file named "layzspa.yaml" into the folder "package" and pasted everything from the layzspa.yaml file at github + removed the # at the 2 areas where it only was for the 4-wired pump.
In the configuration.yaml i added:
In the automations.yaml i added what was in the "automations.yaml" file at github
About the two helpers i need to make, i cant find any helpers who can take the infos from the github file?
To get out of "safe mode" at the HA i had to delete "homeassistant: packages: !include_dir_named packages" from the configuration.yaml
So i'm back to start again and dont know what i have done wrong
If you can download the "Development" branch of this project - HA Autodiscover is now in place and does work for me - adds in all the required sensors (apart from god mode switch?). Maybe try the development branch - treat it like a new project - so you will need to set your model number etc and upload again. But then at least HA will/should work.
Alternatively you can just add in the sensors and switches and climate in the configuration.yaml file in their appropriate places.
I've not used packages in HA, so can't advise. But the helpers - one is a Number helper, and the other is a "Toggle" helper.
I had now downloaded the development zip file, opened like a new project, change the parameters so it is matching my pump and ip. Build image file, uploade to the spa module. everything with "succes". But i stil dont se any activity at the MQTT in HA. The Spa module is connected with MQTT an no fails there. About this GOD MODE you write about, where do i manually enable that? I cant find it in the PlatformIO file?
Hmm, not sure if it's not working for you? If you go to Integrations, MQTT it should be there as a new device with entities?
The god mode switch is the "Take Control" switch which allows us to control the 4-wire pumps. It was/is called god mode in the code in parts(!).
Ok, the Take Control bottom is at the Spa "website" - So i think it is ok? The MQTT is still not reacting for any new device?
I have restartet the HA and the Spa ESP 3 times, with no respons.
When i'm typing # at the configuration in the MQTT it shows the communication to the spa module:
Is discovery enabled in Mosquito? If you click on re-configure MQTT and check it is? and the topic is homeassistant/status ?
Yes it is:
hmm, i'm not 100% sure what the issue is, sorry?
You can still try to add the switches and sensors manually into HA using configuration.yaml
Try adding the below in configuration.yaml
where you have switch:
(you can't have more than one switch:
declaration, so look for it and add below it, or copy and paste all of the below if there is no switch:
)
switch:
- platform: mqtt
name: "Hot Tub Bubbles"
icon: "mdi:chart-bubble"
state_topic: "layzspa/message"
command_topic: "layzspa/command"
value_template: "{{ value_json.AIR }}"
payload_on: '{"CMD":2,"VALUE":1,"XTIME":0,"INTERVAL":0}'
payload_off: '{"CMD":2,"VALUE":0,"XTIME":0,"INTERVAL":0}'
state_on: 1
state_off: 0
availability_topic: "layzspa/Status"
payload_available: "Alive"
payload_not_available: "Dead"
This text i have to replace in the configuration.yaml, where the "switch" for air bubbles is right? In yoour switch it is named hot tub bubbles
Yeah, mine is called Hot Tub Bubbles, you can call it what you like.
Right now my HA is down, and i cant reach it. I tried to make those 2 helpers, and then it went down.
Next question is: the 2 areas with "#" , i have to delete the # at both areas right?
When i try to make that "layzspa.yaml" file in the "package" folder, then i have to add this in the configuration.yaml, and remove the "#", right? :
But when i do this, the HA says it is wrong and, when i delete it, the HA is happy again. Right now i have it all in the configuration.yaml - But it is right?
I'm not sure on using the packages way - mine was all just added to the main configuration.yaml file in one go. Editing yaml is tricky to get the indents and format right.
Okay, then i will do the same. What about this: ? Did you add this in the configuration.yaml in the bottom after all the other stuff?
No, I have them added individually - my HA is a large setup that's been worked on for years now. I would recommend reading up or watching some tutorials on how to add custom switches and sensors to yaml.
Thank you for your help today, i will watch som tutorials :)
I fixed a minor thing in HA config for the 4w now. Best result is when you do it in this order: 1 - Update ESP 2 - delete the old device from HA: 3 - restart ESP 4 - look at the device in HA again. Refresh page with F5 if it's not populated yet.
And for now, use max 14 chars in base topic.
I couldn't remove the old device as you shows in the screendump, because i never got the chance to find it. I have uploaded the last version to the ESP I have manually removed all text regarding the spa in the configuration.yaml Restartet the ESP and refreshing (F5) the HA multiply times, but nothing is popping up?
What are the "max 14 chars in base topic"?
is the Client ID and Base Topic: layzspa2 - in the instructions is the name "layzspa" I have try setting the Telemetry Interval from 600 to 5, but no changes
I don't understand what you're asking. Base topic is whatever you type in the box. And you should not type more than 14 characters for now. Changing the telemetry interval will, well, change the interval between mqtt messages
My spa module says it is connected with MQTT My HA gets data from the spa module But i cant make lovelace or get the lovelace as shown in the instructions pages. When i manually import node-red flow, and set up af lovelace with that, there is no communication between lovelace and spa module. But it shows in node-red that it is connected and running:
You don't need node red to get a dashboard. Disable that flow, I think it just messes things up unless you have a good reason to use it. Then restart HA then restart ESP. Go to devices in the configure page.
Still no sign of new device in the MQTT :(
Judging from your picture you are looking at the wrong place. Click on DEVICES in the top menu
This one? - And how do i do then? :)
No! Go back to devices and find layzspa device instead of the mqtt broker
There is nothing called layzspa, nothing at al even with the word "spa" (?)
You need v3.4.0 of the firmware
Now you lost me again :) Firmware to the esp (spa module?)
Yes - he has released a new release which includes HA auto discovery for 4 wire as standard.
But i downloaded the last development file yesterday (21.07.2022) and uploaded it.
But the firmware at the spa module says:
It will be very similar, if not the same as a dev branch. I am just testing the new release now.
Is there any where else i can check that it is the right version? I tried to search in the Visual Studio Code for "firmware" but couldn't find any "version" number
But the firmware at the spa module says:
Meaning you didn't upload it properly because then it would say 2022-07-21
The latest release is the latest, which includes HA Auto discovery. I have just downloaded it, set it up on my pump and it's connection to MQTT, HA, and pulled in as a device with all sensors. The firmware/code works, but there is an issue with your setup somewhere?
Have you set the model number and PCB version in model.h file. Then upload and set MQTT etc. IT should then work with autodisovery...?
Hi, I cant get my MQTT Broker to automatic find the Spa module. Everything's seems to work. The spa modul is connected to MQTT:
And the Home Assistant receive data from the spa module:
But the broker wont find it? And i cant get the lovelace as showed in your "Build-instructions-Bestway-WiFi-remote.pdf":
What am i missing? 2 peoples has tried to help me, but we cant find the "error"?