jnsbyr / esp8266-intexsbh20

MQTT WiFi remote control for the Intex PureSpa SB-H20 and SJB-HS whirlpools
Other
64 stars 20 forks source link

Feature/esphome #26

Closed RianFlow closed 1 year ago

RianFlow commented 1 year ago

Hi. I'm new to the whole thing and would like to know how and what I have to install where so that it works with EspHome. I use Home Assistant. Do you have a detailed installation guide? Thanks

louis49 commented 1 year ago

Arffff I'm finalizing an other with ESP8266-Homekit ^^ And publishing a homebridge package too !

louis49 commented 1 year ago

Is ESPHome compatible with HomeKit ?

RianFlow commented 1 year ago

Is ESPHome compatible with HomeKit ? I don't know that

RealByron commented 1 year ago

@LubosD Hi guy, I'm porting physical layer for sb-h20 on picow, in order to integrate that to esphome. I already have serial decoding of frames and bp event action with very little PIO program. Would you like to contribute ?

Elektroarzt commented 1 year ago

If you have a pinout or schematic for the Pico W solution and like to share it, I could adapt to the PCB for an alternate placement of ESP8266 or Pico W and publish a new revision. I assume, the schematic of the Pico W solution is very close to the ESP8266.

RealByron commented 1 year ago

I will prepare that for you . But there almost nothing for my poc. I just use level shifters https://amzn.eu/d/gR04Rxb with : GP3: DATA GP4: CLK GP5: CS Pin order matters since I use PIO.

Elektroarzt commented 1 year ago

Ok, so there is no need to change from the discrete resistor / BS170 to the iHaospace module level shifter, right? Just a new mapping to the Pi GPIOs from what I see. I like to keep the existing design as far as possible. If you give me green light with the software and schematic I would go for PCB V2. Assuming you didn't use an external PSU, do you have any experience with the higher power consumption from the bus? Nominal it rises from 80mA to 300mA max from the data sheets.

RealByron commented 1 year ago

we should expect less than 80 mA according to this video. (with full time wifi emission).. https://www.youtube.com/watch?v=GqmnV_T4yAU I do not have equipement for measuring.

piitaya commented 1 year ago

Hi ! I converted the project to esphome : https://github.com/piitaya/esphome-intexsbh20 and added an installer (french installer and english installer). I use it for one month and I have no issues except wifi flashing issues. I had to do some retries when updating firmware via esphome ota.

image

I used @RealByron optimizing branch to add some optimization. I also used @LubosD esphome branch to add esphome compatibility. I removed the sleep mode because it was needed to make it works.

I don't know how we can merge this to the main project as there is some differences

RealByron commented 1 year ago

Hi Paul, I'm just doing the same on picow. I will push my repo tonight.

RealByron commented 1 year ago

Screenshot_2023-06-10-18-38-00-15_c3a231c25ed346e59462e84656a70e50

jnsbyr commented 1 year ago

Hi folks,

the main branch has recently received a significant update to support the Intex model SJB-HS and possibly also the SSP-H (see #13 and the README). The integration of the new model(s) is not jet complete, as these models support more features than the SB-H20. Especially reading and writing the disinfection time will require another significant code change, I am currently working on. My problem here: I do not own a SJB-HS and have to rely on guesswork and user feedback.

What @piitaya presented above looks really good. It would be perfect if we could find a way to bring it all together:

If everyone is willing to commit to support the sum of these features we are at a good starting point. It will probably take a while to get a stable version that supports all these ideas but this is what git branches are good for.

Apart from pulling the main project changes into the code from @piitaya before merging it back into the main project this will probably require a slightly different project directory structure of the main project.

Please let me know what you think about this.

RealByron commented 1 year ago

Hi there, if you want to see my work on Picow https://github.com/RealByron/PicoW-Intex-PureSpa

jnsbyr commented 1 year ago

@RealByron

The RP2040 on the PicoW seems to me like a reasonable choice to resolve the ESP8266 interrupt/timing problems. It has the advantage that the WiFi is not integrated into the MCU but provided by the Cypress chip. I have one on my desk for quite a while, but I am still playing with a SAMD21 - the Atmel/Microchip MCUs have the big advantage that they have more advanced timer units than the ESP8266 and the RP2040.

Regardless, I will not migrate this project to another platform or MCU for my own use, but anyone who starts from the beginning should know about the alternatives. For the time being I will support anyone who wants to improve this project. I still intend to have a look at your stability improvements, but as mentioned above, my current focus is the SJB model support.

RealByron commented 1 year ago

@jnsbyr I know, And I had to rework all part of the application. The real nenfit of Pico W is his PIO state machine. It deal all the bit banging stuff without any main CPU usage.

jnsbyr commented 1 year ago

closed due to inactivity