njanik / hayward-pool-heater-mqtt Goto Github PK
View Code? Open in Web Editor NEWA sketch to control an Hayward pool heater via MQTT
License: MIT License
A sketch to control an Hayward pool heater via MQTT
License: MIT License
Hi,
I am interested to connect my heatpump (based on PC1000 board) but I don't understand how you connect the ESP, the level shifter and the PC1000 together.
I see on the schematic that the PC1000 has a 12V pin and you say the NET is 5V.
As we Wemos D1 is a 3.3 V logic level, we have to connect the level shifter.
I already used that and I know I have to connect the Wemos on the low level side, so VCC (3.3V), GND and the signal pin.
But for the high level, we have the NET pin at 5V, the GND but where do you get the 5V VCC ?
Could you please clarify the connections you made ?
Thank you
Hi,
I'm trying to put this in to work , on my Hayward Pool Heater, but some doubts are present
I use as MQTT broker, my Home Assistant with IP 192.168.0.106 and it needs MQTT authentication (USER and PASS). How can I add it on *.ino ?
Thanks
Hi there,
I have similar issue as Nicolas during the compilation of the code:
E:\Arduino\hayward-poolheater-mqtt\hayward-poolheater-mqtt.ino:5:23: warning: extra tokens at end of #include directive
5 | #include "my_config.h";
| ^
E:\Arduino\hayward-poolheater-mqtt\hayward-poolheater-mqtt.ino: In function 'char* modeToString(byte)':
E:\Arduino\hayward-poolheater-mqtt\hayward-poolheater-mqtt.ino:65:16: warning: ISO C++ forbids converting a string constant to 'char*' [-Wwrite-strings]
65 | return "HEAT";
| ^~~~~~
E:\Arduino\hayward-poolheater-mqtt\hayward-poolheater-mqtt.ino:69:16: warning: ISO C++ forbids converting a string constant to 'char*' [-Wwrite-strings]
69 | return "COOL";
| ^~~~~~
E:\Arduino\hayward-poolheater-mqtt\hayward-poolheater-mqtt.ino:73:16: warning: ISO C++ forbids converting a string constant to 'char*' [-Wwrite-strings]
73 | return "AUTO";
| ^~~~~~
E:\Arduino\hayward-poolheater-mqtt\hayward-poolheater-mqtt.ino:75:12: warning: ISO C++ forbids converting a string constant to 'char*' [-Wwrite-strings]
75 | return "unknown_mode";
| ^~~~~~~~~~~~~~
E:\Arduino\hayward-poolheater-mqtt\hayward-poolheater-mqtt.ino: In function 'boolean mqttMsgReceivedCallBack(char*, byte*, unsigned int)':
E:\Arduino\hayward-poolheater-mqtt\hayward-poolheater-mqtt.ino:141:23: warning: comparison of integer expressions of different signedness: 'int' and 'unsigned int' [-Wsign-compare]
141 | for (int i = 0; i < length; i++)
| ~~^~~~~~~~
E:\Arduino\hayward-poolheater-mqtt\hayward-poolheater-mqtt.ino:237:21: error: control reaches end of non-void function [-Werror=return-type]
237 | isProcessingCmd = false;
| ~~~~~~~~~~~~~~~~^~~~~~~
cc1plus.exe: some warnings being treated as errors
exit status 1
Compilation error: control reaches end of non-void function [-Werror=return-type]
I understand I need to install the Arduino Core. But I think I am lost with that part. Is this the ESP8266 package from the board manager menu that I need to install? Or any other Library/package needed? Also, is there any specific version to use?
I am also newbie with this and I am trying to learn!
Regards,
MJ
Bonjour,
total newbie, j'essaie de réaliser ce projet
Je ne connais rien au code et je n'ai jamais manipulé d'ESP8632
J'ai fait le harware (Wemos)
j'ai une erreur de compilation.
J'utilise Arduino IDE Version: 2.3.1
Une aide possible ?
C:\Users\capel\Downloads\hayward-poolheater-mqtt\hayward-poolheater-mqtt.ino:5:23: warning: extra tokens at end of #include directive
5 | #include "my_config.h";
| ^
C:\Users\capel\Downloads\hayward-poolheater-mqtt\hayward-poolheater-mqtt.ino: In function 'char* modeToString(byte)':
C:\Users\capel\Downloads\hayward-poolheater-mqtt\hayward-poolheater-mqtt.ino:65:16: warning: ISO C++ forbids converting a string constant to 'char*' [-Wwrite-strings]
65 | return "HEAT";
| ^~~~~~
C:\Users\capel\Downloads\hayward-poolheater-mqtt\hayward-poolheater-mqtt.ino:69:16: warning: ISO C++ forbids converting a string constant to 'char*' [-Wwrite-strings]
69 | return "COOL";
| ^~~~~~
C:\Users\capel\Downloads\hayward-poolheater-mqtt\hayward-poolheater-mqtt.ino:73:16: warning: ISO C++ forbids converting a string constant to 'char*' [-Wwrite-strings]
73 | return "AUTO";
| ^~~~~~
C:\Users\capel\Downloads\hayward-poolheater-mqtt\hayward-poolheater-mqtt.ino:75:12: warning: ISO C++ forbids converting a string constant to 'char*' [-Wwrite-strings]
75 | return "unknown_mode";
| ^~~~~~~~~~~~~~
C:\Users\capel\Downloads\hayward-poolheater-mqtt\hayward-poolheater-mqtt.ino: In function 'boolean mqttMsgReceivedCallBack(char*, byte*, unsigned int)':
C:\Users\capel\Downloads\hayward-poolheater-mqtt\hayward-poolheater-mqtt.ino:237:21: error: control reaches end of non-void function [-Werror=return-type]
237 | isProcessingCmd = false;
| ~~~~~~~~~~~~~~~~^~~~~~~
cc1plus.exe: some warnings being treated as errors
exit status 1
Compilation error: control reaches end of non-void function [-Werror=return-type]
Hi,
Anyone adapted this project to ESP32?
From what I see, it should be a matter of renaming included libraries to their ESP32 counterpart and updating the pin variable with ESP32 equivalent of D5 wemos pin.
Do you think Iam missing something?
Thank You
Bonjour,
Le contrôleur (LCD) de ma pompe (Powerline 81521, carte PC1000 selon la doc) venant de griller (corrosion), je suis tombé par hasard sur ce projet.
Ayant un Arduino pour tester, j'ai modifié ton programme (suppression wifi et mqtt), et j'ai relié l'Arduino à la place du contrôleur.
Je reçoit bien les paramètres de la pompe, mais elle est en mode "Cool".
Je peux changer la température de consigne correctement, mais si j'essaye d'envoyer les commandes pour changer le mode ou éteindre la pompe, cela ne change rien.
Cela pourrait-il venir du fait que j'utilise un Arduino et pas un ESP ?
hello
congratulations for this work, do you think this type of project is compatible with smart temp invent?
do you know if there is an mqtt project that directly fetches APIs from Hayward servers?
I have what appears to be the same board in my pool heater, so I am keen to give this a go.
Are you able to please provide a wiring diagram of how it should all be connected? Im a little confused as to what goes where!
Thanks!
Hi, I looked at your project and I find incredible what you have done. On the other hand, I was wondering if the conversion to a YAML version on ESPHome for home assistant would be possible?
Is it possible to capture the error states of the pump ?
Eg this morning i turned my heat pump on, and the returned state was on pool/power
was 1, however it didnt turn on due to an E03 code, which means no water flow.
Turns out my chlorinator had thrown a low water level error (i think because the pump had an air pocket and didnt start up quick enough), which was overrding the junction box command for water from the heat pump.
Hello
Can you add the mqtt flow for node red please
Marc
Hello @njanik,
I just got an old heat pump from LeBonCoin ;).
It's a Mono 20P. looks pretty similar to a PC1000 board.
I ported the code for esp32-c3 and got only invalid frames, with irregular values.
I plugged my logic analyzer to NET and there are some significant differences with the protocol you describe in that Arduino Forum.
Then end of frame however is different from what you describe
Par contre, chaque fin de frame est suivit d'un silence à l'état HIGH de 125 ms ou de 1s.
Le silence est suivi d'un LOW de 9ms.
Here we have 5 repetitive 3ms (might be 00000) and a steady HIGH (link is pulled up).
Few frames I decoded give:
New frame: 01001011011010000001010010110100111000001011000000001010001111101101001011100000
New frame: 10111011000101000001010000101000000000001100100000000000000000001110111011100000
New frame: 01001011011010000001010010110100111000001011000000001010001111101101001011100000
New frame: 10111011000101000001010000101000000000001100100000000000000000001110111011100000
New frame: 01001011011010000001010010110100111000001011000000001010001111101101001011100000
New frame: 10111011000101000001010000101000000000001100100000000000000000001110111011100000
New frame: 01001011011010000001010010110100111000001011000000001010001111101101001011100000
in HEX
0x4b6814b4e0b00a3ed2e0
0xbb14142800c80000eee0
0x4b6814b4e0b00a3ed2e0
0xbb14142800c80000eee0
0x4b6814b4e0b00a3ed2e0
0xbb14142800c80000eee0
0x4b6814b4e0b00a3ed2e0
I'll keep digging but I was wondering if you had an idea...
Merci d'avance! :)
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.