THZ Tecalor (LWZ Stiebel Eltron) module support and code improvement.

Begonnen von immi, 02 Februar 2015, 11:42:16

Vorheriges Thema - Nächstes Thema

LeJoke

sGlobal additonal / alternate values

I think further readings in sGlobal relate to the values listed below (LWZ 304  Integral SW 5.09). Not sure if this has any practical use ... no need to change code from my side:




[" dewPoint: ",          82, 4, "hex2int", 10], # RelHumidity HK2 (when Bedienteil associated with HC2)

## LeJoke trial additons +++++++++++++++++++
        [" x44b2: ",          44, 1, "bit2", 1], # 0 / 1 - 1 when Pumpe HC is on (heat or no heat; 0 when DHW heating)
        [" x46b3: ",          46, 1, "bit3", 1], # would follow booster 3 - 2 - 1 -> solar active ? # have no Sol Model ...
        [" x47b0: ",          47, 1, "bit0", 1], # ?? Kondensatpumpe X18-3 oder ??? defrost end ?? 2020-05-18_18:12:58 on for approx 1 hour during maintainance
        [" x47b1: ",          47, 1, "bit1", 1], # ?? Lüftung Nacht X18-2 ??? # Signal out ? -> Starts w/ "Windows open" signal when additonally "Passivkühlung Fortluft" is set (mainventilator is on w/o compressor)
        [" x118: ",         118, 4, "hex2int", 10], # Öffnung ExV - Analyse - values 0 when no compressor approx. 20% - 40% // 100% when defrost ?
        [" x122: ",         122, 4, "raw", 1], # sometimes 300000000  ...
        [" x126: ",         126, 4, "hex2int", 10], # board xx sensor B12 - WP return
        [" x130: ",         130, 4, "hex2int", 10], # board xx sensor B11 WP flow ?
        [" x134: ",         134, 4, "hex2int", 10], # ? board xx sensor Bxx - !Prozesswerte - Kühlungstemperatur
        [" x138: ",         138, 4, "hex2int", 10], # board xx sensor B08 Wärmepumpe - Verdampferausgang ?
        [" x142: ",         142, 4, "hex2int", 10], # ?? board xx sensor B14 - Condensor out ?
        [" x146: ",         146, 4, "raw", 1], # always 0 for me
        [" x150: ",         150, 4, "raw", 1], #board X4-10 sensor S4 Float switch, bottom panel- Schwimmer Bodenblech = 1



LeJoke

additional commands. Perhaps usable for someone





command          Description                                                                                example response
0A   05   7C   Ofen / Kamin (0=Aus ... 4= Öffner - Überwachung)   
0A   05   7D   LLWT_MaxTimeDefrost (min)                                         
0A   05   7E   LLWT_Abtaubeginnschwelle                                              
0A   05   7F   LLWT_DrehzahlFilter (%)                                                   
F6                   unkown & Man Vent stage (3)  & RemainTime of manvent (8 min)   00001000030008



derhobbit

Register P80 "Freigabe Solar" - I think I found the register.

Pretty sure, it is register 0A03C1

It took me a while to figure out how to read large numbers of registers ... but finally I understood some pearl  :)
Would be cool if you could implement it eventually, immi
Regards


immi

thanks LeJoke and DerHobbit for your hints.

I coded the following and committed v 0.191 (as always available tomorrow)

+  "p80EnableSolar"              => {cmd2=>"0A03C1", argMin =>  "0",  argMax =>   "1",    type =>"1clean",  unit =>""},

let me know if you see further improvements
@LeJOke 0A057C- 0A057F were already implemented

willybauss

Hi immi,

bug or feature?:

set attr interval_sFan
isn't available in pull down menu, so I can't set it to frequent update.

sFirmware  version: 04.19
THZ module VERSION 0.190
FHEM auf Raspberry Pi B und 2B; THZ (THZ-303SOL), CUL_HM, TCM-EnOcean, SamsungTV, JSONMETER, SYSMON, OBIS, STATISTICS

derhobbit


immi

Zitat von: willybauss am 29 November 2020, 23:28:10
set attr interval_sFan
isn't available in pull down menu, so I can't set it to frequent update.
hi willy
implemented an uploaded in 0.192

I also implemented a small delay at startup untill fhem init is finished
if I did it correctly you should not notice :)

willybauss

FHEM auf Raspberry Pi B und 2B; THZ (THZ-303SOL), CUL_HM, TCM-EnOcean, SamsungTV, JSONMETER, SYSMON, OBIS, STATISTICS

LeJoke

hi,

I recently upgraded my hardware from AVM7170 to Raspberry PI 4 (and at the same time upgraded 00_THZ.pm from v 0.180 to v0.190/192)
I just now noticed, that since the upgrade I am "loosing" approx. 20% of the sGlobal FB responses.

firmware is set to 5.39. I saw in the code something like adding an additional delay for 4.39, so I set simpleReadTimeout to 2, but no visible improvement ...

Any idea or suggestion what else I could change (non-blocking ... ?)

fhem log shows:

2020.12.01 12:04:53 3: Opening Mythz device /dev/ttyUSB1
2020.12.01 12:04:53 3: Setting Mythz serial parameters to 115200,8,N,1
2020.12.01 12:04:53 3: Mythz device opened
..-
2020.12.01 12:04:54 0: Featurelevel: 6
2020.12.01 12:04:54 0: Server started with 27 defined entities (fhem.pl:23205/2020-11-21 perl:5.028001 os:linux user:fhem pid:8434)
...
2020.12.01 13:40:04 3: THZ_Get: Error msg2:  THZ_ReadAnswer: Interface max repeat limited to 60  THZ_Get_Com: error found at step2 -- FB -> 0100F3FBFDA80058014E011C02C101C9FDA80102000E01396008310190019002580011001A001100560000018E01A8055F45CA630E3FFAD0E606250083011A000001180154006C005301
2020.12.01 13:40:04 1: PERL WARNING: Use of uninitialized value $err in concatenation (.) or string at ./FHEM/00_THZ.pm line 1090.
2020.12.01 13:40:04 1: PERL WARNING: Use of uninitialized value in concatenation (.) or string at ./FHEM/00_THZ.pm line 1090.
2020.12.01 13:40:04 3: Mythz/RAW: 2F000000000D2C1003 -  -
2020.12.01 13:55:04 3: THZ_Get: Error msg2:  THZ_ReadAnswer: Interface max repeat limited to 60  THZ_Get_Com: error found at step2 -- FB -> 010087FBFDA800590158012702B801CBFDA80102001301436008310190019002580012001A001100560000018A01B4058845C672444001062506590083011D00000124015C00430029013C0000
2020.12.01 13:55:04 3: Mythz/RAW: 2F000000000D2C100300000CAE1003 -  -
2020.12.01 14:15:05 3: THZ_Get: Error msg2:  THZ_ReadAnswer: Interface max repeat limited to 60  THZ_Get_Com: error found at step2 -- FB -> 010005FBFDA8005B015D012C02B801CBFDA80102001501486008310190019002580011001A001100580000018901B6059945D074274001F3B7068D0083011D0000012801610047002B1801
2020.12.01 14:15:05 3: Mythz/RAW: 2F000000000D2C100300000CAE100341000000000C501003 -  -

Apprx. 80% of readings are successfull and look like this
(i added -already in 7170- for trial some parsing definitions):

sGlobal
outsideTemp: 9.1 flowTemp: 34.9 returnTemp: 30.2 hotGasTemp: 69.8 dhwTemp: 45.9 flowTempHC2: -60 evaporatorTemp: 2.1 condenserTemp: 32.9 mixerOpen: 0 mixerClosed: 0 heatPipeValve: 0 diverterValve: 0 dhwPump: 0 heatingCircuitPump: 1 solarPump: 0 compressor: 1 boosterStage3: 0 boosterStage2: 0 boosterStage1: 0 highPressureSensor: 0 lowPressureSensor: 1 evaporatorIceMonitor: 0 signalAnode: 0 evuRelease: 1 ovenFireplace: 1 STB: 0 outputVentilatorPower: 40 inputVentilatorPower: 40 mainVentilatorPower: 60 outputVentilatorSpeed: 18 inputVentilatorSpeed: 26 mainVentilatorSpeed: 17 outside_tempFiltered: 8.8 relHumidity: 0 dewPoint: 39.2 P_Nd: 4.4 P_Hd: 14.36 actualPower_Qc: 6553.492 actualPower_Pel: 2.038 collectorTemp: -60 insideTemp: 25.8 x44b2: 1 x46b3: 0 x47b0: 0 x47b1: 0 windowOpen: 0 quickAirVentTrig: 0 flowRate: 16.77 p_HCw: 1.31 x118: 28.4 x122: 0000 x126: 29.8 x130: 35.4 x134: 7.1 x138: 4.3 x142: 32.2 x146: 0000 x150: 0000 humidityAirOut: 31.21


thanks ...
   

immi

Zitat von: LeJoke am 01 Dezember 2020, 15:07:07
firmware is set to 5.39. I saw in the code something like adding an additional delay for 4.39, so I set simpleReadTimeout to 2, but no visible improvement ...
Hi LeJoke
exactly the opposite:  raspi4 is faster than expected
can you change line 1546 of 00_THZ.pm? (remember to restart after the change)
from
$count =1; $countmax = 60;
to
$count =1; $countmax = 120;

please tell me, if this fixed your issue
immi

willybauss

Zitat von: immi am 30 November 2020, 23:58:15
hi willy
implemented an uploaded in 0.192

I also implemented a small delay at startup untill fhem init is finished
if I did it correctly you should not notice :)
Works as expected, thanks!
FHEM auf Raspberry Pi B und 2B; THZ (THZ-303SOL), CUL_HM, TCM-EnOcean, SamsungTV, JSONMETER, SYSMON, OBIS, STATISTICS

LeJoke

Zitat von: immi am 01 Dezember 2020, 15:42:17
Hi LeJoke
exactly the opposite:  raspi4 is faster than expected
can you change line 1546 of 00_THZ.pm? (remember to restart after the change)
from
$count =1; $countmax = 60;
to
$count =1; $countmax = 120;

please tell me, if this fixed your issue
immi

hi,
fixed.
code change implemented as suggested (and attrib "simpleReadTimeout" removed)
=> raspi 4 is now running smooth for 20+h without the error "Interface max repeat limited ..." showing up again.

Thanks,
Claus

immi


masl

Hallo.

Ich hoffe es kann irgendjemand weiterhelfen.
Die LWZ 303 habe ich versucht nach der Anleitung aus dem Wiki über den 3-poligen-Stecker anzubinden.
Ich habe mich an diese Anleitung https://robert.penz.name/heat-pump-lwz/ bezüglich dem Stecker gehalten.
So wie ich das dort verstehe wurde der RX und TX getauscht. Schlussendlich dann so: oben: GND / mitte: TX / unten: RX.
Der Stecker hängt an einem USB RS232 Converter (wurde aber auch schon gegen einen anderen getauscht, um ein Hardwarefehler auszuschließen).
Per Ser2Net geht es an den FHEM-Raspberry unter folgenden Einstellungen:

2003:raw:500:/dev/ttyUSB0:115200 NONE 1STOPBIT 8DATABITS


Im FHEM Raspi wurde dann folgendes definiert:
define Mythz THZ 192.168.0.111:2003
    attr Mythz interval_sGlobal 300
    attr Mythz interval_sHistory 28800
    attr Mythz interval_sLast10errors 120


Das Modul geht auch auf "opened". Allerdings kommt es dann zur Fehlermeldung:
z_Last_fhem_err THZ_Get: Error msg2: THZ_ReadAnswer: InterfaceNotRespondig. Maybe too slow THZ_Get_Com: error found at step0 -- 0A1D52 ->
Auch das Log schreibt nicht viel...
2021.02.03 23:21:08 3: Opening Mythz device 192.168.0.111:2003
2021.02.03 23:21:08 3: Mythz device opened
2021.02.03 23:21:08 5: thzversion = 0.193
2021.02.03 23:22:13 5: THZ_Get: Try to get 'programFan_Fr_2'
2021.02.03 23:22:13 5: THZ_Get_Comunication: Check if port is open. State = '(opened)'
2021.02.03 23:22:13 5: Mythz sending 02
2021.02.03 23:22:13 5: SW: 02
2021.02.03 23:22:13 5: Mythz start Function THZ_ReadAnswer
2021.02.03 23:22:15 3: THZ_Get: Error msg2:  THZ_ReadAnswer: InterfaceNotRespondig. Maybe too slow THZ_Get_Com: error found at step0  -- 0A1$
2


Es wurde schon versucht mit der Bautrade auf 9600 zu gehen, aber ohne Erfolg.
Auch ein attr Mythz simpleReadTimeout 2 bzw attr Mythz simpleReadTimeout 1 half nicht.

Woran könnten das Problem liegen. Der Fehler kommt bei 2 verschiedenen Converter und bei einem usr tcp232-302.
Muss die Wärmepumpe irgendwie freigeschaltet werden?
oder ist es auch möglich die WP mit dem USB irgendwie an den Raspi zu bekommen (5 Meter Kabel Länge)...



LeJoke

Bei mir sitzt die Buchse kopfüber ... d.h. schwarzes Kabel oben ( bei Roberts Bild ist gelb oben )