Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Atlantic Calypso VM vs Split Inverter #67

Open
BmdOnline opened this issue Jan 27, 2025 · 32 comments
Open

Atlantic Calypso VM vs Split Inverter #67

BmdOnline opened this issue Jan 27, 2025 · 32 comments
Labels
enhancement New feature or request

Comments

@BmdOnline
Copy link
Contributor

Hi,

We are discussing about Calypso compatibility in this french thread.

We are 4 users with these configurations :

ESP32 Heatpump Version Status
Official Arduino Calypso VR E/F Failed
ESP32S3 clone Calypso VR E/F Failed
Official Arduino Calypso Split Inverter F/G Working
ESP32S3 clone Calypso Split Inverter F/G Working

After several tried, no data received, neither msgCRCKO ones.
AquaDebug grab no data either.
We are stuck !

Do you think changing port configuration may help ?
8N2 ? Baud rate ?

Do you have any leads ?

@tspopp
Copy link
Owner

tspopp commented Jan 27, 2025

Well, no data is indeed strange. One of these wires must be a data line and you should be able to read something. Have these heatpumps three or four wires? Maybe the data is passed on the fourth wire? Are you are sure the gpio ports in the configuration file are correct?

Initially I used this logic analyzer to see what is going on: https://www.az-delivery.de/en/products/saleae-logic-analyzer together with Logic 2 to get the first idea of how the protocol is working. Maybe you are right, and the split inverter is using some kind of different protocol. But still I would expect, that the Arduino will read something on serial data line, even if it is garbage.

Edit: If you are careful you can also directly connect the Arduino to the data line and share the same GND with the heatpump . You should be able to read the data line with AquaDebug. This will isolate any solder issues in case the board is not soldered correctly. As far as I remember the ESP should be okay with this, even if the signal is 5V. Shouldn't cause any damage.

@BmdOnline
Copy link
Contributor Author

Both heat-pumps uses 3 wires.
One of the members is using the same ESP32S3 as me, with the same GPIO configuration.

I have used the same analyzer for debug during my firsts attempts.
But I dont think others members have this. I don't know what to advise them.

@tspopp
Copy link
Owner

tspopp commented Jan 27, 2025

Strange. Mh, few more thoughts:

  • Make sure Arduino and heatpump share the same GND, if GND is not connected you might read nothing as well
  • Make sure the communication between HMI and Controller is good (HMI gets temps from controller, HMI is able to select modes, e.g. BOOST)
  • Try tapping the data line (see above) while HMI and Controller are communicating.
flowchart LR

subgraph Controller
GND_CTRL
DATA_CTRL
+5V_CTRL
end

GND
DATA

subgraph HMI
GND_HMI
DATA_HMI
+5V_HMI
end

subgraph Arduino
GPIO_RX_2
GND_ARDUINO
end


GND_HMI --> GND --> GND_CTRL
DATA_HMI --> DATA -->DATA_CTRL
+5V_HMI --> +5V_CTRL

GPIO_RX_2 --> DATA
GND_ARDUINO --> GND


Loading

@tspopp
Copy link
Owner

tspopp commented Jan 27, 2025

Ah, it seems officially the esp32 is officially not 5V tolerant, so it is risky to do this. Forget my comment 😬

I think I used an Arduino Uno back then when I started the first PoC, which uses an 5V logic level.

@sebcaps
Copy link

sebcaps commented Jan 27, 2025

Hello,
One of the guy having trouble with reading data. I confirm you that when aquamqtt is plugged hmi is ok ( data shown on the screen) but did not try to send command (eg boost)
I'll have a look to logic analyser. Don't have one yet but why not give a try 😉

@BmdOnline
Copy link
Contributor Author

@tspopp,
What do you think about using an USB-FTDI adapter instead of Arduino, but without connecting VCC.
Connecting only GND and RX pins, and check if data are received ?

@tspopp
Copy link
Owner

tspopp commented Jan 28, 2025

This should work as well. But if you need to debug the serial protocol (baud rate, etc) the logic analyzer is very helpful.

@BmdOnline
Copy link
Contributor Author

the logic analyzer is very helpful.

@sebcaps, y'a plus qu'à * 😉

* Let's do it

@sebcaps
Copy link

sebcaps commented Feb 1, 2025

Hello,
I gave a try to logic analyser and except on pin D5 I can't see anything.
With default serial settings value correspond to 0XC2.

Image

Other info : while Aquamqtt is plugged display is OK BUT any commands (boost, fan test) does not trigger anything (no bip for boost, no fan start / stop...)
If it may help the recorder SAL file(jsut remove txt extension)

SessionD5-Chan4 - Copie.sal.txt

@tspopp
Copy link
Owner

tspopp commented Feb 1, 2025

Other info : while Aquamqtt is plugged display is OK BUT any commands (boost, fan test) does not trigger anything (no bip for boost, no fan start / stop...)

Are you in Listener Mode? 🤔 In Listener Mode AquaMQTT should not affect the communication at all, as it is just sniffing the communication....

@sebcaps
Copy link

sebcaps commented Feb 2, 2025

Some (good) news; after a day by 5°:

  • I had a connectivity issue (using adapter to not cut wire) : I had a short between GND and data line in my connector : fixed (tackled connecting HMI & main board and sniffing data (ie no PCB no arduino)
    Sniffing result

Image

  • While using PCB (even in LISTENER MODE and J7 short) => no data,
  • Connecting 5V, GND and data line from main to Arduino and to HMI according to the following schema I got data (DroppedBytes only)

Image

  • Ran Debug and got Hex data . I 'll need to install debug tool . For the moment too cold to do so ;-)

Another user with the same model (Calypso E/F)) is also reporting issue reading data using transistor and level shifter. Ie no data, but OK when plugged directly....

@tspopp
Copy link
Owner

tspopp commented Feb 2, 2025

It is indeed strange that the logic-level-converter (LLC) does not work for those machines. Maybe these machines already provide 3.3V logic level? You might want to check with a multimeter? You may also check, if the cable which is expected to provide +5V, if that is really providing +5V or something else.... 🤔 🤷‍♂

Happy you have finally read something from the heatpump. If AquaMQTT is not able to parse the messages already, just drop a dump (dec or hex) from AquaDebug and we determine the cause.

@Arrnooo
Copy link

Arrnooo commented Feb 2, 2025

Hello,

I suspect that the serial link is very sensitive to impedance changes.
This would explain the communication issues as soon as a component with a pull-up resistor is connected to the link, whether in listening mode or MITM.

When directly connected, with the data wire attached to GPIO_MAIN_RX, all information is received. This rules out a software issue.

I took measurements with an oscilloscope. The voltage is indeed at 5V.

And with two logic buffers like the 74LVC2T45?

@tspopp
Copy link
Owner

tspopp commented Feb 3, 2025

Nice analysis! What is the path forward? Will you proof a new hardware design which resolves the issue for these heat pumps? I

I can help verifying if the new hw design will also work with my legacy heat pump. And of course I can incorporate changes with KiCad and put a rev.2 there.

@Arrnooo
Copy link

Arrnooo commented Feb 3, 2025

Image

I would like to test this version of the assembly.

However, the buffers are bidirectionally controlled.
High = A to B
Low = B to A

This requires adding a TX enable in the software, set to high only during the transmission phase.

Do you think this is possible for you?

@tspopp
Copy link
Owner

tspopp commented Feb 3, 2025

I put it on my branch here: https://github.com/tspopp/AquaMQTT/tree/t/hwpoc

You may adapt Configuration.h to set the correct ENABLE_TX_HMI and ENABLE_TX_MAIN GPIOs accordingly. Those GPIOs will be set to high whenever AquaMQTT is sending something on a dedicated channel. In Listener mode they are of course unused.

@Arrnooo
Copy link

Arrnooo commented Feb 3, 2025

Super!

I ordered the components. I'll engrave the PCB with my CNC in the meantime. As soon as everything is ready, I'll test it and give you feedback.

@BmdOnline
Copy link
Contributor Author

BmdOnline commented Feb 3, 2025

Hi,
what about 74LVC2T45 vs logic-level-converter currently in use ?
What are its advantages ?

If you're working on a rev.2, maybe you can add a way to disable the entire board (power and data) using a rocker switch.
I plan to adapt an intermediate board connected to HMI and Main ports J1 & J2, allowing to disable everything, remove ESP if needed, only using a rocker switch without powering off the heatpump.

@tspopp
Copy link
Owner

tspopp commented Feb 3, 2025

As far as I understood it mainly resolves the need for the LLC board and the transitors. So we replace five parts by two. Moreover it resolves the issue with those heatpumps, where we are not able to read the serial bus due to impedance changes (due to the LLC).

@sebcaps
Copy link

sebcaps commented Feb 4, 2025

Happy you have finally read something from the heatpump. If AquaMQTT is not able to parse the messages already, just drop a dump (dec or hex) from AquaDebug and we determine the cause.

Hello, here the messages I get with ArduinoESP32 in between HMI and Main. (using aquadebug & debug.py)

aquadbg_debug_hex.csv
aquadbg_debug_dec.csv

Hope it's a step forward to support this model / version

@Arrnooo
Copy link

Arrnooo commented Feb 4, 2025

Ok.
If I analyze this correctly, these are the messages sent by the main board.
Since the connection is disrupted, the HMI receives nothing and therefore does not respond. As a result, the main board keeps sending the same three messages in a loop.

This supports my hypothesis of a connection disrupted by the addition of an element that listens to the communication.

@tspopp
Copy link
Owner

tspopp commented Feb 4, 2025

Hm, something is wrong in those traces, since it is an endless combination of message identifiers without data:

It is always the same pattern 194 67 193 which is repeated. Usually after each message identifier, there is a message length field and some data. In this case there is nothing, so there is no data in those traces. I am wondering what went wrong here... 🤷‍♂

@tspopp
Copy link
Owner

tspopp commented Feb 6, 2025

@Arrnooo let me know if the new design actually works. In the meantime I prepared a new PCB. This time we should be able to order it pre-assembled by JLCPCB and it provides the RAST adapter designed by @tukutt as well.

Image

@BmdOnline
Copy link
Contributor Author

Hi,
Are you sure about DIP format for U1 and U2 ?
According to SN74LVC2T45 datasheet, it is only provided as surface mount component.

@tspopp
Copy link
Owner

tspopp commented Feb 7, 2025

You are right, this is an early draft. I've been just too excited yesterday. Will finish this as soon as there is feedback if that actually works.

@BmdOnline
Copy link
Contributor Author

BmdOnline commented Feb 7, 2025

@Arrnooo,
is there an alternative to SN74LVC2T45, but in DIP format ?
It might be interesting to avoid surface mount soldering.

@Arrnooo
Copy link

Arrnooo commented Feb 7, 2025

The ordered components are surface-mount components. However, my CNC is not precise enough to engrave such small traces. So I also ordered adapters for this type of DIP footprint. A choice will have to be made for the final PCB.

I will receive the components this week and engrave the PCB this weekend. Expect an update in a week if time permits.

@tspopp tspopp added the enhancement New feature or request label Feb 9, 2025
@Arrnooo
Copy link

Arrnooo commented Feb 12, 2025

I made a mistake reading the datasheet. The component is far too small for me (0.5mm pitch instead of 0.65mm).

I finally found an equivalent in a through-hole component (SN74LS245). I'm going to test it with just one. Do you think this will cause errors?

It's on order. I'll keep you updated.

Image

@tspopp
Copy link
Owner

tspopp commented Feb 13, 2025

I don't think this will work: In MITM Mode, there are two individual serial sessions going on. In case the controller session wants to read and the hmi session wants to write, you are in big trouble and you will loose packets🤔

If we get the board manufactured and pre-soldered, we don't really have an issue with using the small components, right?

@Arrnooo
Copy link

Arrnooo commented Feb 23, 2025

It’s working with the SN74LS245 in listening mode. I took measurements with the oscilloscope, and everything looks good. So, I believe the solution with the two 74LVC2T45 should work as well.

If you have the PCBs manufactured and the components soldered, it should be feasible.

@sebcaps
Copy link

sebcaps commented Feb 23, 2025

Thx @Arrnooo for your work and feedback
@tspopp do you think you'll manage to setup a new PCB design based on Arrnooo schematic (for an arduino) ? I could give a try but not a pcb designer expert :-). Definitely I don't uderstand the component change nor H1 /H4 purpose (both are tied to the same net). SN74LS245 exist in through hole, so in my opinion a good 'alternative'

@tspopp
Copy link
Owner

tspopp commented Feb 23, 2025

Yeah, I will take care 👍 Love to get a few things optimized such as RAST and pre-soldered through jlpcb.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

4 participants