OTGW stops when burner starts

This Forum is about the Opentherm gateway (OTGW) from Schelte

Moderator: hvxl

thunderbird
Starting Member
Starting Member
Posts: 10
Joined: Sat Sep 12, 2020 8:09 pm

OTGW stops when burner starts

Post by thunderbird »

I have a OTGW module from Nodosho with a USR-TCP232-T2. I noticed that the module stops sending serial messages when my central heating device starts the burner for hot water. The heating device is an Intergas HR 28/24. I read the serial messages via a telnet session on the TCP module.

Typical output:

Code: Select all

R00000000
BC0000000
R00110000
BC0110000
R001B0000
B601B0000
R801C0000
BC01C2900
R900E6400
B500E6400
R00000000
B40000004
R00000000
B40000004
R80190000
BC0192A00
R10010A00
BD0010A00
R80380000
B40383C00
R00390000
B40393200
R00000000
BC0000000
R00000000
BC0000000
R00000000
BC0000000
R80190000
BC0192A00
R10010A00
BD0010A00

I tried several power supplies without luck (24v, 2.5A). The OTGW unit is used standalone, so without thermostat.
The TCP module is communicating fine all the way. A parallel ping shows no communication problem or outages. When I connect the reset jumper on the board, the OTGW starts sending messages again. This happens in the same telnet session.

So my conclusion is that the problem is in the OTGW module. When no hot water is used, the serial messages are ok for hours (tries a whole night).

Any ideas what the problem could be and/or how can I debug this?
hvxl
Senior Member
Senior Member
Posts: 1965
Joined: Sat Jun 05, 2010 11:59 am
Contact:

Re: OTGW stops when burner starts

Post by hvxl »

The OTGW doesn't do anything special based on the DHW mode flag. So if it consistently hangs at that moment, something else must also be changing. Some people reported that their boiler was unable to produce a good Opentherm signal when the flame was on for central heating. Maybe your boiler exhibits a similar problem with hot water. However, if this is the case, I expect that you would get error messages. The OTGW should not get into such a state that a reset is needed.

You can debug this by running test #3 of the diagnostic firmware and then generating a hot water request (iow open the hot water tap). This test requires an Opentherm thermostat to be connected to the OTGW. I hope you have one.
Schelte
thunderbird
Starting Member
Starting Member
Posts: 10
Joined: Sat Sep 12, 2020 8:09 pm

Re: OTGW stops when burner starts

Post by thunderbird »

Thank you for the reply. I do not have an Opentherm thermostat. I looked better at the timings, it is a little bit different.

When I start using hot water, the OTGW reports ok. But then when I stop using water, the boiler has a 3 in the service display. As soon as the 3 disappears, OTGW stops. After a minute, OTGW comes up again.

I have measured the voltage on the Opentherm connectors.
When OTGW is:
  • not connected: 42V (before and after hot water tap)
  • connected and running: 13V
  • 'crashed' after the hot water tap: 37V
Direct after a hot water tap when OTGW is 'crashed', I tried the following:
  • disconnect and connect the Opentherm connector: OTGW keeps silent
  • power off and on OTGW: OTGW immediately started sending reports
I will try to get an Opentherm thermostat...
hvxl
Senior Member
Senior Member
Posts: 1965
Joined: Sat Jun 05, 2010 11:59 am
Contact:

Re: OTGW stops when burner starts

Post by hvxl »

There seems to be a hardware fault in your OTGW. You should never have 37V on connector X2. The voltage is limited by D10, Q1 and either D5 & D8, or D6 & D7, So you can only have a maximum of 15V + 3 p-n junctions, which amounts to something between 17.0 and 17.5 volts. No amount of bugs in the firmware can alter that.

42V from the boiler is very high, although allowed by the Opentherm specification. But it exceeds the maximum allowed Vceo of a BC558. So it is possible that Q1 was blown. If that's the case, you may want to replace it with a BC557 or BC556. I appreciate replacing Q1 may be difficult on an OTGW from Nodoshop because they used SMD components.
Schelte
thunderbird
Starting Member
Starting Member
Posts: 10
Joined: Sat Sep 12, 2020 8:09 pm

Re: OTGW stops when burner starts

Post by thunderbird »

Hmmm, I made a mistake. My multimeter was on AC while measuring voltage. Now the DC voltages:
  • Disconnected: 19.5V, steady before, while and after hot water tap. My multimeter doesn't measure any spikes or drops.
  • Connected: 6-7V
  • Connected and after hot water tap: 17-17.5V
Today I saw several times - just before the 'crash' - an orange led blinks one time (RB3, pin 9). Normally RB4 blinks roughly every second. RB4 stops blinking when in 'crash' state.

It takes exact 60 seconds before OTGW 'resets' itself. Is there a fail safe mechanism which resets the PIC after 60 seconds?

I agree that the changing voltages couldn't be triggered from the software of OTGW as the boiler-OT schema is isolated. Main question is, how can the voltage changing (remember the voltage does not change when OTGW is not connected).

So bottom line the OTGW comes in a crash or freeze state. Reconnecting did not help, only a reset of OTGW. While in crash state the voltages goes from 6 to 13 and drops back to 6 after reset.
hvxl
Senior Member
Senior Member
Posts: 1965
Joined: Sat Jun 05, 2010 11:59 am
Contact:

Re: OTGW stops when burner starts

Post by hvxl »

Those voltages look much more like I would expect.

The LED connected to RB3 (pin 9) is normally referred to as LED A. Unless changed from the defaults, it indicates that the boiler's flame is on.

There is a fail safe mechanism that restarts the program when 64 messages have gone unanswered. That would be after about 64 seconds. But then you should still see LED B (RB4, pin 10) flashing until the reset, which you don't.

The voltage can change because the OTGW drives the opto-coupler OK1A. That's how the OTGW communicates to the boiler.


It would be interesting to see what the OTGW reports on the serial interface when it recovers on its own after the 60 seconds freeze. If it says "OpenTherm Gateway 4.2.5", then it rebooted. In that case the output of the PR=Q command indicates the reason for the reboot.

Another intriguing remark you made is that LED A flashes just before the problem starts. The fact that the boiler's flame is on is not immediately reported on the OT interface. It only becomes known when the OTGW requests the status (MsgID 0). So the initial suspicion that something changes on the boiler side when the flame is on sounds less likely. Because in that case the problem would start before the OTGW is aware that the flame is on.

The problem now seems to happen when the OTGW is informed that the flame is on. As you observed, that causes LED A to be switched on. If there is some short circuit in the device, or if the extra power consumption is a problem for the power supply, the LED turning on could actually be the trigger for the problem. You can easily check if this is the case by assigning a different function to LED A. There is no function Z, so by issuing the command LA=Z, the LED will never switch on. If the problem still occurs after that, we have at least ruled out a hardware issue.

However, the log you provided in your first post does not contain any status messages where the flame is on. So that does not match with the flashing of LED A before the problem. Or was your log not showing the last messages before a problem occurrence? When collecting a log in the future, can you please use the otmonitor program? That tags messages with a time stamp, and it translates the messages so I don't have to decode the hex numbers by hand.
Schelte
thunderbird
Starting Member
Starting Member
Posts: 10
Joined: Sat Sep 12, 2020 8:09 pm

Re: OTGW stops when burner starts

Post by thunderbird »

Disabling the LED A does not help. I don't see LED B flashing when OTGW is freezed. LED B stops flashing (visually) at the same time the serial output stops.
I also changed all LED's to B ('Boiler communication') and in another try to X ('Transmitting an Opentherm message to the thermostat or boiler'). All LED's are flashing happily, so power issue can be ruled out I think.

When I set LED A to X, B to B and C to R ('Receiving an Opentherm message from the thermostat or boiler'). All LED's stop blinking when OTGW freezes.

When OTGW comes up again, I see the "OpenTherm Gateway 4.2.5" line. A PR=Q command gives me: PR: Q=L. No idea what L means.
thunderbird
Starting Member
Starting Member
Posts: 10
Joined: Sat Sep 12, 2020 8:09 pm

Re: OTGW stops when burner starts

Post by thunderbird »

Please check otmonitor log. As we can see, there is a flame detected and communicated. The topic title is not correct. OTGW stops when the burner shuts off.
Everything is ok as long as the hot water is used (service code 6 is shown on the boiler, means DHW active). When hot water is stopped, the service display goes to 3 (ventilating) and after a few seconds the service display goes off. Just before / at the same time the 3 on the display disappears, OTGW freezes.

I also tried changing the reference voltage, 0.625, 1.042, 1.667 2.083 and 2.500v (VR=0, 2, 5, 7, 9). Without luck...
otlog-20200930.1.zip
(7.59 KiB) Downloaded 286 times
hvxl
Senior Member
Senior Member
Posts: 1965
Joined: Sat Jun 05, 2010 11:59 am
Contact:

Re: OTGW stops when burner starts

Post by hvxl »

Curious. PR: Q=L means that the OTGW is under the impression that the same message was transmitted 64 times (L=Loop). So it is still running its normal program, but for some reason doesn't actually send out any messages.

I will have to study the code again to see if I can imagine a scenario that could cause that to happen.
Schelte
hvxl
Senior Member
Senior Member
Posts: 1965
Joined: Sat Jun 05, 2010 11:59 am
Contact:

Re: OTGW stops when burner starts

Post by hvxl »

Because the OTGW starts operating correctly again after it reinitializes itself, it seems to me that the problem must be caused by some wrong data in RAM or an SFR. Two possibilities I could come up with are:
  • The OTGW switched to monitor mode
  • The A/D convertor was disabled
To check these hypotheses, you can dump some memory addresses during the one minute interval after the OTGW stops sending messages and before it resets itself:
DP=7E
DP=1F
If you have enough time, dump some more data that may be interesting if my theory proves to be wrong:
DP=5E
DP=61
DP=57
Repeat that last one a couple of times.
Schelte
thunderbird
Starting Member
Starting Member
Posts: 10
Joined: Sat Sep 12, 2020 8:09 pm

Re: OTGW stops when burner starts

Post by thunderbird »

I have dumped all the values in four rounds. Each value is dumped multiple times in the 'freeze' period. But during a freeze period the value is the same. And only address 57 shows different values over the tries.

7E -> 30,30,30,30
1F -> 41,41,41,41
5E -> 10,10,10,10 (when running ok, switches between 00 and 10)
61 -> 04,04,04,04
57 -> B2,B3,B1,B5 (when running ok, changes, keeps in last state before freeze when)
hvxl
Senior Member
Senior Member
Posts: 1965
Joined: Sat Jun 05, 2010 11:59 am
Contact:

Re: OTGW stops when burner starts

Post by hvxl »

That is interesting. The two possible causes I identified both have the correct values. So they are exonerated. But the fact that address 57 is stuck at one value during the freeze does indicate that the A/D converter isn't operating. Possibly it is not being started. A reason for that would be that TMR2 is running. You can confirm that by checking address 0x12 (DP=12) during a freeze. When there are no messages, that should show 00.

Assuming you'll find 04 instead, the next step is to find out why it is running. TMR2 is started when there is activity on either interface. So that is something the boiler can cause, which ties in with your observation of when the problem happens. But when that interface activity isn't a valid OpenTherm message, an error should be reported and TMR2 should be stopped again. A continuously changing input could restart TMR2 over and over. But then a reset of the PIC wouldn't be expected to clear that situation. So, there must be some input signal that causes a code path where TMR2 keeps running when it shouldn't. I will have to find that code path.

You can help focus my search by dumping some more data during a freeze:
DP=5C
DP=5D
DP=65
DP=8B
DP=8C
DP=8D
DP=38
Schelte
hvxl
Senior Member
Senior Member
Posts: 1965
Joined: Sat Jun 05, 2010 11:59 am
Contact:

Re: OTGW stops when burner starts

Post by hvxl »

Never mind. I think I have identified what causes the situation you describe: A high signal from the boiler that lasts longer than 2.5ms between OT messages.

I'm now looking for the best way to fix that.
Schelte
hvxl
Senior Member
Senior Member
Posts: 1965
Joined: Sat Jun 05, 2010 11:59 am
Contact:

Re: OTGW stops when burner starts

Post by hvxl »

Try this and let me know if it helps:
gateway-4.2.6.zip
Attempt to fix freeze in standalone mode
(9.2 KiB) Downloaded 274 times
With this firmware you should get an "Error 03" on the bad signal from the boiler. But after that I now expect the communication to continue as normal.
Schelte
thunderbird
Starting Member
Starting Member
Posts: 10
Joined: Sat Sep 12, 2020 8:09 pm

Re: OTGW stops when burner starts

Post by thunderbird »

Please see the attached files for the data. I tried 5 rounds, but not every round I could complete all memory addresses. 5C shows a lot of different values, I tested a number of times 1-3 times a second (as fast as a person could do ctrl+v + enter).
All other addresses are tested multiple times in one round. Only 8B shows 2 values, C1 and C5. But not always and C1 much more than C5.

Edit: I missed the above two posts. So I will try 4.2.6 tomorrow.
Attachments
data-otgw.xlsx
DataAsXlsx.png
(9.44 KiB) Downloaded 260 times
Last edited by thunderbird on Sat Nov 07, 2020 12:12 am, edited 1 time in total.
Post Reply

Return to “Opentherm Gateway Forum”