Closed thesebastianf closed 6 years ago
cool. are you planning full oh2 support?
and merge to openhab that it can installed via paperui etc?
Right now OH2 is supported in 1.x compatibility mode. About pure OH2 support? I will think about it when stable OH2 version will be released.
Yea installation via paper ui is cool thing. No doubt. And installation without it is a bit of pain, till you find where to copy configuration... But since my last binding pull request passed 11 month till someone began review. So yes installation through paperui is cool, but here is the most recent version.
As 2.x is released, do you still have plans to work on paperui installation support!
I had it in plan but now I do not have time for it. And as I know there is already S7 binding in review for PaperUI (https://github.com/openhab/openhab2-addons/pull/1606). So there would be no reason to build new one if this one would be merged.
Hi, I get communications error if want to read or write to Area above 304. Simatic S7 1215C, openHab 2.2/2.3
2018-01-18 11:23:08.172 [ERROR] [.binding.simatic.internal.SimaticTCP] - isoTCP:192.168.1.30 - Read data area error (Area=DB19.DBB208-DB19.DBB374, Return code=0xffffff80, Error=Unexpected function code in answer)
any solution for this
Hi, I tested it with PLC 1212C in datablock address area 0-1023 and all values are read. So there should not be problem. I see you read large area (DBB208-DBB374). Probably there is problem. Are you need all bytes in this area? Quick solution could be compress (put together) all readed data (there is optimization to read data at once if there is gap between then less or equal than 32 bytes). Or another solution is split data into more datablocks or areas with 32bytes gap.
Hi,
thanks for Your help, Yes I need all bytes in this area (my project is really big) temporary I have set optional "O" for all Data above 304 and communications work OK but in this state I cannot write data to PLC abowe this memory area. { simatic="plc:DB19.DBD318:float:O" }. 1215C is little different and have much more memory as 1212C. It will be nice if this bindings can be extended to support more memory area.
Bottom tail from my Items:
Group PrzedpokojMalyTemp "Przedpokój mały" [ "Thermostat" ] Number PLC_PrzedpokojMalyTempA "Przedpokój mały"
(PrzedpokojMalyTemp) [ "CurrentTemperature" ] { simatic="plc:DB28.DBD2:float" } Number PLC_PrzedpokojMalyTempZ "Przedpokój mały" (PrzedpokojMalyTemp) [ "TargetTemperature" ] { simatic="plc:DB19.DBD220:float" } String PLC_PrzedpokojMalyTempTryb "Przedpokój mały" (PrzedpokojMalyTemp) [ "homekit:HeatingCoolingMode" ]
Number PLC_PrzedpokojMalyTermostatStan "Przedpokój mały"{ simatic="plc:DB19.DBB219:byte" } Group PrzedpokojDuzyTemp "Przedpokój duży" [ "Thermostat" ] Number PLC_PrzedpokojDuzyTempA "Przedpokój duży"
(PrzedpokojDuzyTemp) [ "CurrentTemperature" ] { simatic="plc:DB28.DBD6:float" } Number PLC_PrzedpokojDuzyTempZ "Przedpokój duży" (PrzedpokojDuzyTemp) [ "TargetTemperature" ] { simatic="plc:DB19.DBD234:float" } String PLC_PrzedpokojDuzyTempTryb "Przedpokój duży" (PrzedpokojDuzyTemp) [ "homekit:HeatingCoolingMode" ] Number PLC_PrzedpokojDuzyTermostatStan "Przedpokój duży" { simatic="plc:DB19.DBB233:byte" } Group PokojParterTemp "Pokój parter" [ "Thermostat" ] Number PLC_PokojParterTempA "Pokój parter"
(PokojParterTemp) [ "CurrentTemperature" ] { simatic="plc:DB28.DBD10:float" } Number PLC_PokojParterTempZ "Pokój parter" (PokojParterTemp) [ "TargetTemperature" ] { simatic="plc:DB19.DBD248:float" } String PLC_PokojParterTempTryb "Pokoj parter" (PokojParterTemp) [ "homekit:HeatingCoolingMode" ] Number PLC_PokojParterTermostatStan "Pokoj parter" { simatic="plc:DB19.DBB247:byte" } Group SalonTemp "Salon" [ "Thermostat" ] Number PLC_SalonTempA "Salon"
(SalonTemp) [ "CurrentTemperature" ] { simatic="plc:DB28.DBD14:float" } Number PLC_SalonTempZ "Salon" (SalonTemp) [ "TargetTemperature" ] { simatic="plc:DB19.DBD262:float" } String PLC_SalonTempTryb "Salon" (SalonTemp) [ "homekit:HeatingCoolingMode" ] Number PLC_SalonTermostatStan "Salon" { simatic="plc:DB19.DBB261:byte" } Group JadalniaTemp "Jadalnia" [ "Thermostat" ] Number PLC_JadalniaTempA "Jadalnia"
(JadalniaTemp) [ "CurrentTemperature" ] { simatic="plc:DB28.DBD14:float" } Number PLC_JadalniaTempZ "Jadalnia" (JadalniaTemp) [ "TargetTemperature" ] { simatic="plc:DB19.DBD276:float" } String PLC_JadalniaTempTryb "Jadalnia" (JadalniaTemp) [ "homekit:HeatingCoolingMode" ] Number PLC_JadalniaTermostatStan "Jadalnia" { simatic="plc:DB19.DBB261:byte" } Group KuchniaTemp "Kuchnia" [ "Thermostat" ] Number PLC_KuchniaTempA "Kuchnia"
(KuchniaTemp) [ "CurrentTemperature" ] { simatic="plc:DB28.DBD18:float" } Number PLC_KuchniaTempZ "Kuchnia" (KuchniaTemp) [ "TargetTemperature" ] { simatic="plc:DB19.DBD290:float" } String PLC_KuchniaTempTryb "Kuchnia" (KuchniaTemp) [ "homekit:HeatingCoolingMode" ] Number PLC_KuchniaTermostatStan "Kuchnia" { simatic="plc:DB19.DBB289:byte" } Group LazienkaParterTemp "Łazienka parter" [ "Thermostat" ] Number PLC_LazienkaParterTempA "Łazienka parter"
(LazienkaParterTemp) [ "CurrentTemperature" ] { simatic="plc:DB28.DBD22:float" } Number PLC_LazienkaParterTempZ "Łazienka parter" (LazienkaParterTemp) [ "TargetTemperature" ] { simatic="plc:DB19.DBD304:float" } String PLC_LazienkaParterTempTryb "Łazienka parter" (LazienkaParterTemp) [ "homekit:HeatingCoolingMode" ] Number PLC_LazienkaParterTermostatStan "Łazienka parter" { simatic="plc:DB19.DBB303:byte" } Group GarderobaTemp "Garderoba" [ "Thermostat" ] Number PLC_GarderobaTempA "Garderoba"
(GarderobaTemp) [ "CurrentTemperature" ] { simatic="plc:DB28.DBD26:float" } Number PLC_GarderobaTempZ "Garderoba" (GarderobaTemp) [ "TargetTemperature" ] { simatic="plc:DB19.DBD318:float:O" } String PLC_GarderobaTempTryb "Garderoba" (GarderobaTemp) [ "homekit:HeatingCoolingMode" ] Number PLC_GarderobaTermostatStan "Garderoba" { simatic="plc:DB19.DBB317:byte:O" } Group BiuroTemp "Biuro" [ "Thermostat" ] Number PLC_BiuroTempA "Biuro"
(BiuroTemp) [ "CurrentTemperature" ] { simatic="plc:DB28.DBD30:float" } Number PLC_BiuroTempZ "Biuro" (BiuroTemp) [ "TargetTemperature" ] { simatic="plc:DB19.DBD332:float:O" } String PLC_BiuroTempTryb "Biuro" (BiuroTemp) [ "homekit:HeatingCoolingMode" ] Number PLC_BiuroTermostatStan "Biuro" { simatic="plc:DB19.DBB331:byte:O" } Group KamilaTemp "Kamila" [ "Thermostat" ] Number PLC_KamilaTempA "Kamila"
(KamilaTemp) [ "CurrentTemperature" ] { simatic="plc:DB28.DBD34:float" } Number PLC_KamilaTempZ "Kamila" (KamilaTemp) [ "TargetTemperature" ] { simatic="plc:DB19.DBD346:float:O" } String PLC_KamilaTempTryb "Kamila" (KamilaTemp) [ "homekit:HeatingCoolingMode" ] Number PLC_KamilaTermostatStan "Kamila" { simatic="plc:DB19.DBB345:byte:O" } Group SypialniaTemp "Sypialnia" [ "Thermostat" ] Number PLC_SypialniaTempA "Sypialnia"
(SypialniaTemp) [ "CurrentTemperature" ] { simatic="plc:DB28.DBD38:float" } Number PLC_SypialniaTempZ "Sypialnia" (SypialniaTemp) [ "TargetTemperature" ] { simatic="plc:DB19.DBD360:float:O" } String PLC_SypialniaTempTryb "Sypialnia" (SypialniaTemp) [ "homekit:HeatingCoolingMode" ] Number PLC_SypialniaTermostatStan "Sypialnia" { simatic="plc:DB19.DBB359:byte:O" } Group LazienkaPietroTemp "Łazienka piętro" [ "Thermostat" ] Number PLC_LazienkaPietroTempA "Łazienka piętro"
(LazienkaPietroTemp) [ "CurrentTemperature" ] { simatic="plc:DB28.DBD42:float" } Number PLC_LazienkaPietroTempZ "Łazienka piętro" (LazienkaPietroTemp) [ "TargetTemperature" ] { simatic="plc:DB19.DBD374:float:O" } String PLC_LazienkaPietroTempTryb "Łazienka piętro" (LazienkaPietroTemp) [ "homekit:HeatingCoolingMode" ] Number PLC_LazienkaPietroTermostatStan "Łazienka piętro" { simatic="plc:DB19.DBB373:byte:O" }
Thanks
Just tested your config and whole area is read:
12:47:30.808 [DEBUG] [.b.simatic.internal.SimaticTCP:127 ] - isoTCP:192.168.254.99 - open() - connecting 12:47:31.315 [INFO ] [.b.simatic.internal.SimaticTCP:166 ] - isoTCP:192.168.254.99 - connected 12:47:31.316 [DEBUG] [.b.simatic.internal.SimaticTCP:337 ] - isoTCP:192.168.254.99 - checkNewData() is called 12:47:31.318 [DEBUG] [.b.simatic.internal.SimaticTCP:348 ] - Locking 12:47:31.571 [DEBUG] [.b.simatic.internal.SimaticTCP:395 ] - isoTCP:192.168.254.99 - Reading finished. Area=M0-M1 12:47:31.572 [DEBUG] [.b.simatic.internal.SimaticTCP:402 ] - isoTCP:192.168.254.99 - PostValue for item=S71212MB0 (Device=plc1212 MemAddress=MB0/MB0 DataType=BYTE Direction=0) 12:47:31.576 [DEBUG] [o.o.b.s.i.SimaticGenericDevice:550 ] - isoTCP:192.168.254.99 - Incoming data - item:S71212MB0/state:127 12:47:31.830 [DEBUG] [.b.simatic.internal.SimaticTCP:395 ] - isoTCP:192.168.254.99 - Reading finished. Area=DB19.DBB219-DB19.DBB378 12:47:31.831 [DEBUG] [.b.simatic.internal.SimaticTCP:402 ] - isoTCP:192.168.254.99 - PostValue for item=PLC_PrzedpokojMalyTermostatStan (Device=plc1212 MemAddress=DB19.DBB219/DB19.DBB219 DataType=BYTE Direction=0) 12:47:31.834 [DEBUG] [o.o.b.s.i.SimaticGenericDevice:550 ] - isoTCP:192.168.254.99 - Incoming data - item:PLC_PrzedpokojMalyTermostatStan/state:127 12:47:31.836 [DEBUG] [.b.simatic.internal.SimaticTCP:402 ] - isoTCP:192.168.254.99 - PostValue for item=PLC_PrzedpokojMalyTempZ (Device=plc1212 MemAddress=DB19.DBD220/DB19.DBD220 DataType=FLOAT Direction=0) 12:47:31.841 [DEBUG] [o.o.b.s.i.SimaticGenericDevice:550 ] - isoTCP:192.168.254.99 - Incoming data - item:PLC_PrzedpokojMalyTempZ/state:0 12:47:31.844 [DEBUG] [.b.simatic.internal.SimaticTCP:402 ] - isoTCP:192.168.254.99 - PostValue for item=PLC_PrzedpokojDuzyTermostatStan (Device=plc1212 MemAddress=DB19.DBB233/DB19.DBB233 DataType=BYTE Direction=0) 12:47:31.849 [DEBUG] [o.o.b.s.i.SimaticGenericDevice:550 ] - isoTCP:192.168.254.99 - Incoming data - item:PLC_PrzedpokojDuzyTermostatStan/state:0 12:47:31.851 [DEBUG] [.b.simatic.internal.SimaticTCP:402 ] - isoTCP:192.168.254.99 - PostValue for item=PLC_PrzedpokojDuzyTempZ (Device=plc1212 MemAddress=DB19.DBD234/DB19.DBD234 DataType=FLOAT Direction=0) 12:47:31.855 [DEBUG] [o.o.b.s.i.SimaticGenericDevice:550 ] - isoTCP:192.168.254.99 - Incoming data - item:PLC_PrzedpokojDuzyTempZ/state:0 12:47:31.859 [DEBUG] [.b.simatic.internal.SimaticTCP:402 ] - isoTCP:192.168.254.99 - PostValue for item=PLC_PokojParterTermostatStan (Device=plc1212 MemAddress=DB19.DBB247/DB19.DBB247 DataType=BYTE Direction=0) 12:47:31.864 [DEBUG] [o.o.b.s.i.SimaticGenericDevice:550 ] - isoTCP:192.168.254.99 - Incoming data - item:PLC_PokojParterTermostatStan/state:0 12:47:31.866 [DEBUG] [.b.simatic.internal.SimaticTCP:402 ] - isoTCP:192.168.254.99 - PostValue for item=PLC_PokojParterTempZ (Device=plc1212 MemAddress=DB19.DBD248/DB19.DBD248 DataType=FLOAT Direction=0) 12:47:31.871 [DEBUG] [o.o.b.s.i.SimaticGenericDevice:550 ] - isoTCP:192.168.254.99 - Incoming data - item:PLC_PokojParterTempZ/state:0 12:47:31.876 [DEBUG] [.b.simatic.internal.SimaticTCP:402 ] - isoTCP:192.168.254.99 - PostValue for item=PLC_JadalniaTermostatStan (Device=plc1212 MemAddress=DB19.DBB261/DB19.DBB261 DataType=BYTE Direction=0) 12:47:31.879 [DEBUG] [o.o.b.s.i.SimaticGenericDevice:550 ] - isoTCP:192.168.254.99 - Incoming data - item:PLC_JadalniaTermostatStan/state:0 12:47:31.883 [DEBUG] [.b.simatic.internal.SimaticTCP:402 ] - isoTCP:192.168.254.99 - PostValue for item=PLC_SalonTermostatStan (Device=plc1212 MemAddress=DB19.DBB261/DB19.DBB261 DataType=BYTE Direction=0) 12:47:31.886 [DEBUG] [o.o.b.s.i.SimaticGenericDevice:550 ] - isoTCP:192.168.254.99 - Incoming data - item:PLC_SalonTermostatStan/state:0 12:47:31.891 [DEBUG] [.b.simatic.internal.SimaticTCP:402 ] - isoTCP:192.168.254.99 - PostValue for item=PLC_SalonTempZ (Device=plc1212 MemAddress=DB19.DBD262/DB19.DBD262 DataType=FLOAT Direction=0) 12:47:31.896 [DEBUG] [o.o.b.s.i.SimaticGenericDevice:550 ] - isoTCP:192.168.254.99 - Incoming data - item:PLC_SalonTempZ/state:0 12:47:31.898 [DEBUG] [.b.simatic.internal.SimaticTCP:402 ] - isoTCP:192.168.254.99 - PostValue for item=PLC_JadalniaTempZ (Device=plc1212 MemAddress=DB19.DBD276/DB19.DBD276 DataType=FLOAT Direction=0) 12:47:31.902 [DEBUG] [o.o.b.s.i.SimaticGenericDevice:550 ] - isoTCP:192.168.254.99 - Incoming data - item:PLC_JadalniaTempZ/state:0 12:47:31.906 [DEBUG] [.b.simatic.internal.SimaticTCP:402 ] - isoTCP:192.168.254.99 - PostValue for item=PLC_KuchniaTermostatStan (Device=plc1212 MemAddress=DB19.DBB289/DB19.DBB289 DataType=BYTE Direction=0) 12:47:31.910 [DEBUG] [o.o.b.s.i.SimaticGenericDevice:550 ] - isoTCP:192.168.254.99 - Incoming data - item:PLC_KuchniaTermostatStan/state:0 12:47:31.912 [DEBUG] [.b.simatic.internal.SimaticTCP:402 ] - isoTCP:192.168.254.99 - PostValue for item=PLC_KuchniaTempZ (Device=plc1212 MemAddress=DB19.DBD290/DB19.DBD290 DataType=FLOAT Direction=0) 12:47:31.918 [DEBUG] [o.o.b.s.i.SimaticGenericDevice:550 ] - isoTCP:192.168.254.99 - Incoming data - item:PLC_KuchniaTempZ/state:0 12:47:31.920 [DEBUG] [.b.simatic.internal.SimaticTCP:402 ] - isoTCP:192.168.254.99 - PostValue for item=S71212DB300 (Device=plc1212 MemAddress=DB19.DBB300/DB19.DBB300 DataType=BYTE Direction=0) 12:47:31.926 [DEBUG] [o.o.b.s.i.SimaticGenericDevice:550 ] - isoTCP:192.168.254.99 - Incoming data - item:S71212DB300/state:0 12:47:31.928 [DEBUG] [.b.simatic.internal.SimaticTCP:402 ] - isoTCP:192.168.254.99 - PostValue for item=S71212DB301 (Device=plc1212 MemAddress=DB19.DBB301/DB19.DBB301 DataType=BYTE Direction=0) 12:47:31.933 [DEBUG] [o.o.b.s.i.SimaticGenericDevice:550 ] - isoTCP:192.168.254.99 - Incoming data - item:S71212DB301/state:0 12:47:31.935 [DEBUG] [.b.simatic.internal.SimaticTCP:402 ] - isoTCP:192.168.254.99 - PostValue for item=S71212DB302 (Device=plc1212 MemAddress=DB19.DBB302/DB19.DBB302 DataType=BYTE Direction=0) 12:47:31.940 [DEBUG] [o.o.b.s.i.SimaticGenericDevice:550 ] - isoTCP:192.168.254.99 - Incoming data - item:S71212DB302/state:0 12:47:31.944 [DEBUG] [.b.simatic.internal.SimaticTCP:402 ] - isoTCP:192.168.254.99 - PostValue for item=PLC_LazienkaParterTermostatStan (Device=plc1212 MemAddress=DB19.DBB303/DB19.DBB303 DataType=BYTE Direction=0) 12:47:31.947 [DEBUG] [o.o.b.s.i.SimaticGenericDevice:550 ] - isoTCP:192.168.254.99 - Incoming data - item:PLC_LazienkaParterTermostatStan/state:0 12:47:31.950 [DEBUG] [.b.simatic.internal.SimaticTCP:402 ] - isoTCP:192.168.254.99 - PostValue for item=S71212DB303 (Device=plc1212 MemAddress=DB19.DBB303/DB19.DBB303 DataType=BYTE Direction=0) 12:47:31.956 [DEBUG] [o.o.b.s.i.SimaticGenericDevice:550 ] - isoTCP:192.168.254.99 - Incoming data - item:S71212DB303/state:0 12:47:31.958 [DEBUG] [.b.simatic.internal.SimaticTCP:402 ] - isoTCP:192.168.254.99 - PostValue for item=S71212DB304 (Device=plc1212 MemAddress=DB19.DBB304/DB19.DBB304 DataType=BYTE Direction=0) 12:47:31.963 [DEBUG] [o.o.b.s.i.SimaticGenericDevice:550 ] - isoTCP:192.168.254.99 - Incoming data - item:S71212DB304/state:0 12:47:31.966 [DEBUG] [.b.simatic.internal.SimaticTCP:402 ] - isoTCP:192.168.254.99 - PostValue for item=PLC_LazienkaParterTempZ (Device=plc1212 MemAddress=DB19.DBD304/DB19.DBD304 DataType=FLOAT Direction=0) 12:47:31.968 [DEBUG] [o.o.b.s.i.SimaticGenericDevice:550 ] - isoTCP:192.168.254.99 - Incoming data - item:PLC_LazienkaParterTempZ/state:0 12:47:31.974 [DEBUG] [.b.simatic.internal.SimaticTCP:402 ] - isoTCP:192.168.254.99 - PostValue for item=S71212DB305 (Device=plc1212 MemAddress=DB19.DBB305/DB19.DBB305 DataType=BYTE Direction=0) 12:47:31.977 [DEBUG] [o.o.b.s.i.SimaticGenericDevice:550 ] - isoTCP:192.168.254.99 - Incoming data - item:S71212DB305/state:0 12:47:31.981 [DEBUG] [.b.simatic.internal.SimaticTCP:402 ] - isoTCP:192.168.254.99 - PostValue for item=S71212DB306 (Device=plc1212 MemAddress=DB19.DBB306/DB19.DBB306 DataType=BYTE Direction=0) 12:47:31.986 [DEBUG] [o.o.b.s.i.SimaticGenericDevice:550 ] - isoTCP:192.168.254.99 - Incoming data - item:S71212DB306/state:0 12:47:31.989 [DEBUG] [.b.simatic.internal.SimaticTCP:402 ] - isoTCP:192.168.254.99 - PostValue for item=PLC_GarderobaTermostatStan (Device=plc1212 MemAddress=DB19.DBB317/DB19.DBB317 DataType=BYTE Direction=0) 12:47:31.993 [DEBUG] [o.o.b.s.i.SimaticGenericDevice:550 ] - isoTCP:192.168.254.99 - Incoming data - item:PLC_GarderobaTermostatStan/state:0 12:47:31.996 [DEBUG] [.b.simatic.internal.SimaticTCP:402 ] - isoTCP:192.168.254.99 - PostValue for item=PLC_GarderobaTempZ (Device=plc1212 MemAddress=DB19.DBD318/DB19.DBD318 DataType=FLOAT Direction=0) 12:47:31.999 [DEBUG] [o.o.b.s.i.SimaticGenericDevice:550 ] - isoTCP:192.168.254.99 - Incoming data - item:PLC_GarderobaTempZ/state:0 12:47:32.006 [DEBUG] [.b.simatic.internal.SimaticTCP:402 ] - isoTCP:192.168.254.99 - PostValue for item=PLC_BiuroTermostatStan (Device=plc1212 MemAddress=DB19.DBB331/DB19.DBB331 DataType=BYTE Direction=0) 12:47:32.011 [DEBUG] [o.o.b.s.i.SimaticGenericDevice:550 ] - isoTCP:192.168.254.99 - Incoming data - item:PLC_BiuroTermostatStan/state:0 12:47:32.013 [DEBUG] [.b.simatic.internal.SimaticTCP:402 ] - isoTCP:192.168.254.99 - PostValue for item=PLC_BiuroTempZ (Device=plc1212 MemAddress=DB19.DBD332/DB19.DBD332 DataType=FLOAT Direction=0) 12:47:32.018 [DEBUG] [o.o.b.s.i.SimaticGenericDevice:550 ] - isoTCP:192.168.254.99 - Incoming data - item:PLC_BiuroTempZ/state:0 12:47:32.021 [DEBUG] [.b.simatic.internal.SimaticTCP:402 ] - isoTCP:192.168.254.99 - PostValue for item=PLC_KamilaTermostatStan (Device=plc1212 MemAddress=DB19.DBB345/DB19.DBB345 DataType=BYTE Direction=0) 12:47:32.024 [DEBUG] [o.o.b.s.i.SimaticGenericDevice:550 ] - isoTCP:192.168.254.99 - Incoming data - item:PLC_KamilaTermostatStan/state:0 12:47:32.028 [DEBUG] [.b.simatic.internal.SimaticTCP:402 ] - isoTCP:192.168.254.99 - PostValue for item=PLC_KamilaTempZ (Device=plc1212 MemAddress=DB19.DBD346/DB19.DBD346 DataType=FLOAT Direction=0) 12:47:32.031 [DEBUG] [o.o.b.s.i.SimaticGenericDevice:550 ] - isoTCP:192.168.254.99 - Incoming data - item:PLC_KamilaTempZ/state:0 12:47:32.036 [DEBUG] [.b.simatic.internal.SimaticTCP:402 ] - isoTCP:192.168.254.99 - PostValue for item=PLC_SypialniaTermostatStan (Device=plc1212 MemAddress=DB19.DBB359/DB19.DBB359 DataType=BYTE Direction=0) 12:47:32.043 [DEBUG] [o.o.b.s.i.SimaticGenericDevice:550 ] - isoTCP:192.168.254.99 - Incoming data - item:PLC_SypialniaTermostatStan/state:0 12:47:32.045 [DEBUG] [.b.simatic.internal.SimaticTCP:402 ] - isoTCP:192.168.254.99 - PostValue for item=PLC_SypialniaTempZ (Device=plc1212 MemAddress=DB19.DBD360/DB19.DBD360 DataType=FLOAT Direction=0) 12:47:32.049 [DEBUG] [o.o.b.s.i.SimaticGenericDevice:550 ] - isoTCP:192.168.254.99 - Incoming data - item:PLC_SypialniaTempZ/state:0 12:47:32.052 [DEBUG] [.b.simatic.internal.SimaticTCP:402 ] - isoTCP:192.168.254.99 - PostValue for item=PLC_LazienkaPietroTermostatStan (Device=plc1212 MemAddress=DB19.DBB373/DB19.DBB373 DataType=BYTE Direction=0) 12:47:32.056 [DEBUG] [o.o.b.s.i.SimaticGenericDevice:550 ] - isoTCP:192.168.254.99 - Incoming data - item:PLC_LazienkaPietroTermostatStan/state:0 12:47:32.060 [DEBUG] [.b.simatic.internal.SimaticTCP:402 ] - isoTCP:192.168.254.99 - PostValue for item=PLC_LazienkaPietroTempZ (Device=plc1212 MemAddress=DB19.DBD374/DB19.DBD374 DataType=FLOAT Direction=0) 12:47:32.063 [DEBUG] [o.o.b.s.i.SimaticGenericDevice:550 ] - isoTCP:192.168.254.99 - Incoming data - item:PLC_LazienkaPietroTempZ/state:0
Hi,
just please remove "O" from all PLC adres or use "IO" and then test again. With read (incoming data) is all OK, problem is if I want to write data to PLC above address 304.
thanks
I had taken "O". Write data give me error. Data are written into PLC but PLC return unexpected message. This message is unknown for used libnodave library. To fix this PLC answer must be implemented into this library
If I look also on the error from PLC, write data areas error is( DBB208-DBB374) however this is not true because I use DBD data (Real).
2018-01-18 11:23:08.172 [ERROR] [.binding.simatic.internal.SimaticTCP] - isoTCP:192.168.1.30 - Read data area error (Area=DB19.DBB208-DB19.DBB374, Return code=0xffffff80, Error=Unexpected function code in answer)
Hi, I have again strange error with connection to s7, any help?
2018-01-30 05:50:16.202 [ERROR] [.binding.simatic.internal.SimaticTCP] - isoTCP:192.168.1.30 - Read data area error (Area=DB24.DBB0-DB24.DBB4, Return code=0xffffff7e, Error=Buffer size insufficient while readBytes)
Hi @grzegorz914, can you test this build please: https://github.com/docbender/openHAB-Simatic/releases/download/1.1.3/org.openhab.binding.simatic-1.9.0-SNAPSHOT.jar I looked at library socket operations and did some improvements. It looks better for me now.
Hi @docbender , many thanks for the update, with this release no any error witch communication looks like all is OK, one other problem some data from DB6 is not read, nothing in openHAB log, if value changed on PLC site.
This is read correct and data is changed in openHAB log:
Switch PLC_TermostatyTrybRecznyAuto "Tryb pracy ogrzewania" <switch > (gTermostaty) { simatic="plc:DB6.DBX12.0:byte" }
2018-02-01 16:14:55.020 [vent.ItemStateChangedEvent] - PLC_TermostatyTrybRecznyAuto changed from ON to OFF
2018-02-01 16:15:28.691 [vent.ItemStateChangedEvent] - PLC_TermostatyTrybRecznyAuto changed from OFF to ON
This all are not read, if value on PLC site changed then nothing changed in openHAB log.
Number PLC_PrzedpokojMalyTermostatStan "Przedpokój mały" <radiator> { simatic="plc:DB6.DBB23:byte" }
Number PLC_PrzedpokojDuzyTermostatStan "Przedpokój duży" <radiator> { simatic="plc:DB6.DBB37:byte" }
Number PLC_PokojParterTermostatStan "Pokój parter" <radiator> { simatic="plc:DB6.DBB51:byte" }
Number PLC_SalonTermostatStan "Salon" <light> { simatic="plc:DB6.DBB65:byte" }
Number PLC_JadalniaTermostatStan "Jadalnia" <radiator> { simatic="plc:DB6.DBB79:byte" }
Number PLC_KuchniaTermostatStan "Kuchnia" <radiator> { simatic="plc:DB6.DBB93:byte" }
Number PLC_LazienkaParterTermostatStan "Łazienka parter" <radiator> { simatic="plc:DB6.DBB107:byte" }
Number PLC_GarderobaTermostatStan "Garderoba" <radiator> { simatic="plc:DB6.DBB121:byte" }
Number PLC_BiuroTermostatStan "Biuro" <radiator> { simatic="plc:DB6.DBB135:byte" }
Number PLC_KamilaTermostatStan "Kamila" <radiator> { simatic="plc:DB6.DBB149:byte" }
Number PLC_SypialniaTermostatStan "Sypialnia" <radiator> { simatic="plc:DB6.DBB163:byte" }
Number PLC_LazienkaPietroTermostatStan "Łazienka piętro" <radiator> { simatic="plc:DB6.DBB177:byte" }`
very strange.
All other DB and I,Q,M area are read correct.
Can you collect trace log data from simatic binding? Maybe there will be some usefull information.
Here file from wireshark:
Thanks for traffic log. I'm interested also in how binding reacts to your configuration. If db6 is in readareas and if it reads db6 and read data are resolved To enable trace log type
log:set TRACE org.openhab.binding.simatic
2018-02-02 12:32:55.563 [TRACE] [.binding.simatic.internal.SimaticTCP] - isoTCP:192.168.1.30 - PostValue for item=PLC_TermostatyTrybRecznyAuto (Device=plc MemAddress=DB6.DBX12.0/DB6.DBX12.0 DataType=BYTE Direction=0)
2018-02-02 12:32:55.568 [TRACE] [.binding.simatic.internal.SimaticTCP] - isoTCP:192.168.1.30 - PostValue for item=PLC_PrzedpokojMalyTermostatStan (Device=plc MemAddress=DB6.DBB23/DB6.DBB23 DataType=BYTE Direction=0)
2018-02-02 12:32:55.574 [TRACE] [.binding.simatic.internal.SimaticTCP] - isoTCP:192.168.1.30 - PostValue for item=PLC_PrzedpokojMalyTempZ (Device=plc MemAddress=DB6.DBD24/DB6.DBD24 DataType=FLOAT Direction=0)
2018-02-02 12:32:55.580 [TRACE] [.binding.simatic.internal.SimaticTCP] - isoTCP:192.168.1.30 - PostValue for item=PLC_PrzedpokojDuzyTermostatStan (Device=plc MemAddress=DB6.DBB37/DB6.DBB37 DataType=BYTE Direction=0)
2018-02-02 12:32:55.585 [TRACE] [.binding.simatic.internal.SimaticTCP] - isoTCP:192.168.1.30 - PostValue for item=PLC_PrzedpokojDuzyTempZ (Device=plc MemAddress=DB6.DBD38/DB6.DBD38 DataType=FLOAT Direction=0)
2018-02-02 12:32:55.591 [TRACE] [.binding.simatic.internal.SimaticTCP] - isoTCP:192.168.1.30 - PostValue for item=PLC_PokojParterTermostatStan (Device=plc MemAddress=DB6.DBB51/DB6.DBB51 DataType=BYTE Direction=0)
2018-02-02 12:32:55.597 [TRACE] [.binding.simatic.internal.SimaticTCP] - isoTCP:192.168.1.30 - PostValue for item=PLC_PokojParterTempZ (Device=plc MemAddress=DB6.DBD52/DB6.DBD52 DataType=FLOAT Direction=0)
2018-02-02 12:32:55.602 [TRACE] [.binding.simatic.internal.SimaticTCP] - isoTCP:192.168.1.30 - PostValue for item=PLC_SalonTermostatStan (Device=plc MemAddress=DB6.DBB65/DB6.DBB65 DataType=BYTE Direction=0)
2018-02-02 12:32:55.607 [TRACE] [.binding.simatic.internal.SimaticTCP] - isoTCP:192.168.1.30 - PostValue for item=PLC_SalonTempZ (Device=plc MemAddress=DB6.DBD66/DB6.DBD66 DataType=FLOAT Direction=0)
2018-02-02 12:32:55.614 [TRACE] [.binding.simatic.internal.SimaticTCP] - isoTCP:192.168.1.30 - PostValue for item=PLC_JadalniaTermostatStan (Device=plc MemAddress=DB6.DBB79/DB6.DBB79 DataType=BYTE Direction=0)
2018-02-02 12:32:55.621 [TRACE] [.binding.simatic.internal.SimaticTCP] - isoTCP:192.168.1.30 - PostValue for item=PLC_JadalniaTempZ (Device=plc MemAddress=DB6.DBD80/DB6.DBD80 DataType=FLOAT Direction=0)
2018-02-02 12:32:55.628 [TRACE] [.binding.simatic.internal.SimaticTCP] - isoTCP:192.168.1.30 - PostValue for item=PLC_KuchniaTermostatStan (Device=plc MemAddress=DB6.DBB93/DB6.DBB93 DataType=BYTE Direction=0)
2018-02-02 12:32:55.636 [TRACE] [.binding.simatic.internal.SimaticTCP] - isoTCP:192.168.1.30 - PostValue for item=PLC_KuchniaTempZ (Device=plc MemAddress=DB6.DBD94/DB6.DBD94 DataType=FLOAT Direction=0)
2018-02-02 12:32:55.643 [TRACE] [.binding.simatic.internal.SimaticTCP] - isoTCP:192.168.1.30 - PostValue for item=PLC_LazienkaParterTermostatStan (Device=plc MemAddress=DB6.DBB107/DB6.DBB107 DataType=BYTE Direction=0)
2018-02-02 12:32:55.650 [TRACE] [.binding.simatic.internal.SimaticTCP] - isoTCP:192.168.1.30 - PostValue for item=PLC_LazienkaParterTempZ (Device=plc MemAddress=DB6.DBD108/DB6.DBD108 DataType=FLOAT Direction=0)
2018-02-02 12:32:55.656 [TRACE] [.binding.simatic.internal.SimaticTCP] - isoTCP:192.168.1.30 - PostValue for item=PLC_GarderobaTermostatStan (Device=plc MemAddress=DB6.DBB121/DB6.DBB121 DataType=BYTE Direction=0)
2018-02-02 12:32:55.662 [TRACE] [.binding.simatic.internal.SimaticTCP] - isoTCP:192.168.1.30 - PostValue for item=PLC_GarderobaTempZ (Device=plc MemAddress=DB6.DBD122/DB6.DBD122 DataType=FLOAT Direction=0)
2018-02-02 12:32:55.671 [TRACE] [.binding.simatic.internal.SimaticTCP] - isoTCP:192.168.1.30 - PostValue for item=PLC_BiuroTermostatStan (Device=plc MemAddress=DB6.DBB135/DB6.DBB135 DataType=BYTE Direction=0)
2018-02-02 12:32:55.678 [TRACE] [.binding.simatic.internal.SimaticTCP] - isoTCP:192.168.1.30 - PostValue for item=PLC_BiuroTempZ (Device=plc MemAddress=DB6.DBD136/DB6.DBD136 DataType=FLOAT Direction=0)
2018-02-02 12:32:55.684 [TRACE] [.binding.simatic.internal.SimaticTCP] - isoTCP:192.168.1.30 - PostValue for item=PLC_KamilaTermostatStan (Device=plc MemAddress=DB6.DBB149/DB6.DBB149 DataType=BYTE Direction=0)
2018-02-02 12:32:55.693 [TRACE] [.binding.simatic.internal.SimaticTCP] - isoTCP:192.168.1.30 - PostValue for item=PLC_KamilaTempZ (Device=plc MemAddress=DB6.DBD150/DB6.DBD150 DataType=FLOAT Direction=0)
2018-02-02 12:32:55.701 [TRACE] [.binding.simatic.internal.SimaticTCP] - isoTCP:192.168.1.30 - PostValue for item=PLC_SypialniaTermostatStan (Device=plc MemAddress=DB6.DBB163/DB6.DBB163 DataType=BYTE Direction=0)
2018-02-02 12:32:55.708 [TRACE] [.binding.simatic.internal.SimaticTCP] - isoTCP:192.168.1.30 - PostValue for item=PLC_SypialniaTempZ (Device=plc MemAddress=DB6.DBD164/DB6.DBD164 DataType=FLOAT Direction=0)
2018-02-02 12:38:27.724 [TRACE] [.binding.simatic.internal.SimaticTCP] - isoTCP:192.168.1.30 - PostValue for item=PLC_LazienkaPietroTermostatStan (Device=plc MemAddress=DB6.DBB177/DB6.DBB177 DataType=BYTE Direction=0)
2018-02-02 12:38:27.725 [TRACE] [imatic.internal.SimaticGenericDevice] - isoTCP:192.168.1.30 - Incoming data - item:PLC_LazienkaPietroTermostatStan/state:0
2018-02-02 12:38:31.223 [TRACE] [.binding.simatic.internal.SimaticTCP] - isoTCP:192.168.1.30 - PostValue for item=PLC_TermostatyTrybRecznyAuto (Device=plc MemAddress=DB6.DBX12.0/DB6.DBX12.0 DataType=BYTE Direction=0)
2018-02-02 12:38:31.226 [TRACE] [imatic.internal.SimaticGenericDevice] - isoTCP:192.168.1.30 - Incoming data - item:PLC_TermostatyTrybRecznyAuto/state:OFF
2018-02-02 12:38:31.228 [TRACE] [.binding.simatic.internal.SimaticTCP] - isoTCP:192.168.1.30 - PostValue for item=PLC_PrzedpokojMalyTermostatStan (Device=plc MemAddress=DB6.DBB23/DB6.DBB23 DataType=BYTE Direction=0)
2018-02-02 12:38:31.230 [TRACE] [imatic.internal.SimaticGenericDevice] - isoTCP:192.168.1.30 - Incoming data - item:PLC_PrzedpokojMalyTermostatStan/state:0
2018-02-02 12:38:31.237 [TRACE] [.binding.simatic.internal.SimaticTCP] - isoTCP:192.168.1.30 - PostValue for item=PLC_PrzedpokojDuzyTermostatStan (Device=plc MemAddress=DB6.DBB37/DB6.DBB37 DataType=BYTE Direction=0)
2018-02-02 12:38:31.239 [TRACE] [imatic.internal.SimaticGenericDevice] - isoTCP:192.168.1.30 - Incoming data - item:PLC_PrzedpokojDuzyTermostatStan/state:0
2018-02-02 12:38:31.247 [TRACE] [.binding.simatic.internal.SimaticTCP] - isoTCP:192.168.1.30 - PostValue for item=PLC_PokojParterTermostatStan (Device=plc MemAddress=DB6.DBB51/DB6.DBB51 DataType=BYTE Direction=0)
2018-02-02 12:38:31.249 [TRACE] [imatic.internal.SimaticGenericDevice] - isoTCP:192.168.1.30 - Incoming data - item:PLC_PokojParterTermostatStan/state:0
2018-02-02 12:38:31.257 [TRACE] [.binding.simatic.internal.SimaticTCP] - isoTCP:192.168.1.30 - PostValue for item=PLC_SalonTermostatStan (Device=plc MemAddress=DB6.DBB65/DB6.DBB65 DataType=BYTE Direction=0)
2018-02-02 12:38:31.259 [TRACE] [imatic.internal.SimaticGenericDevice] - isoTCP:192.168.1.30 - Incoming data - item:PLC_SalonTermostatStan/state:0
2018-02-02 12:38:31.266 [TRACE] [.binding.simatic.internal.SimaticTCP] - isoTCP:192.168.1.30 - PostValue for item=PLC_JadalniaTermostatStan (Device=plc MemAddress=DB6.DBB79/DB6.DBB79 DataType=BYTE Direction=0)
2018-02-02 12:38:31.268 [TRACE] [imatic.internal.SimaticGenericDevice] - isoTCP:192.168.1.30 - Incoming data - item:PLC_JadalniaTermostatStan/state:0
2018-02-02 12:38:31.274 [TRACE] [.binding.simatic.internal.SimaticTCP] - isoTCP:192.168.1.30 - PostValue for item=PLC_KuchniaTermostatStan (Device=plc MemAddress=DB6.DBB93/DB6.DBB93 DataType=BYTE Direction=0)
2018-02-02 12:38:31.276 [TRACE] [imatic.internal.SimaticGenericDevice] - isoTCP:192.168.1.30 - Incoming data - item:PLC_KuchniaTermostatStan/state:0
2018-02-02 12:38:31.280 [TRACE] [.binding.simatic.internal.SimaticTCP] - isoTCP:192.168.1.30 - PostValue for item=PLC_LazienkaParterTermostatStan (Device=plc MemAddress=DB6.DBB107/DB6.DBB107 DataType=BYTE Direction=0)
2018-02-02 12:38:31.281 [TRACE] [imatic.internal.SimaticGenericDevice] - isoTCP:192.168.1.30 - Incoming data - item:PLC_LazienkaParterTermostatStan/state:0
2018-02-02 12:38:31.285 [TRACE] [.binding.simatic.internal.SimaticTCP] - isoTCP:192.168.1.30 - PostValue for item=PLC_GarderobaTermostatStan (Device=plc MemAddress=DB6.DBB121/DB6.DBB121 DataType=BYTE Direction=0)
2018-02-02 12:38:31.286 [TRACE] [imatic.internal.SimaticGenericDevice] - isoTCP:192.168.1.30 - Incoming data - item:PLC_GarderobaTermostatStan/state:0
2018-02-02 12:38:31.290 [TRACE] [.binding.simatic.internal.SimaticTCP] - isoTCP:192.168.1.30 - PostValue for item=PLC_BiuroTermostatStan (Device=plc MemAddress=DB6.DBB135/DB6.DBB135 DataType=BYTE Direction=0)
2018-02-02 12:38:31.291 [TRACE] [imatic.internal.SimaticGenericDevice] - isoTCP:192.168.1.30 - Incoming data - item:PLC_BiuroTermostatStan/state:0
2018-02-02 12:38:31.295 [TRACE] [.binding.simatic.internal.SimaticTCP] - isoTCP:192.168.1.30 - PostValue for item=PLC_KamilaTermostatStan (Device=plc MemAddress=DB6.DBB149/DB6.DBB149 DataType=B
This is not whole log. But from what i can see, data are read and posted into OH. Values are set to 0. This is not correct if I compare it with your network dump. I try to find why. It would be perfect if you post your whole item file for this PLC.
No problem, simatic.items
//Pogoda
Number PLC_PogodaTemp "Temperatura powietrza"
//Wjazd
Switch PLC_BramaTaster "Brama"
//Tastery_i_oswietlenie
Switch PLC_PrzedpokojMalyTaster "Przedpokój mały"
Switch PLC_StrychTaster "Strych"
Switch PLC_WjazdTaster "Wjazd"
Switch PLC_PrzedpokojMalySwiatlo "Przedpokój mały"
Switch PLC_StrychSwiatlo "Strych"
Switch PLC_WjazdSwiatlo "Wjazd"
//Termostaty_CO
Switch PLC_TermostatyTrybRecznyAuto "Tryb pracy ogrzewania"
Number PLC_PrzedpokojMalyTermostatStan "Przedpokój mały"
Number PLC_KotlowniaTempA "Kotłownia"
Group PrzedpokojMalyTemp "Przedpokój mały" [ "Thermostat" ]
Number PLC_PrzedpokojMalyTempA "Przedpokój mały"
Group PrzedpokojDuzyTemp "Przedpokój duży" [ "Thermostat" ]
Number PLC_PrzedpokojDuzyTempA "Przedpokój duży"
Group PokojParterTemp "Pokój parter" [ "Thermostat" ]
Number PLC_PokojParterTempA "Pokój parter"
Group SalonTemp "Salon" [ "Thermostat" ]
Number PLC_SalonTempA "Salon"
Group JadalniaTemp "Jadalnia" [ "Thermostat" ]
Number PLC_JadalniaTempA "Jadalnia"
Group KuchniaTemp "Kuchnia" [ "Thermostat" ]
Number PLC_KuchniaTempA "Kuchnia"
Group LazienkaParterTemp "Łazienka parter" [ "Thermostat" ]
Number PLC_LazienkaParterTempA "Łazienka parter"
Group GarderobaTemp "Garderoba" [ "Thermostat" ]
Number PLC_GarderobaTempA "Garderoba"
Group BiuroTemp "Biuro" [ "Thermostat" ]
Number PLC_BiuroTempA "Biuro"
Group KamilaTemp "Kamila" [ "Thermostat" ]
Number PLC_KamilaTempA "Kamila"
Group SypialniaTemp "Sypialnia" [ "Thermostat" ]
Number PLC_SypialniaTempA "Sypialnia"
Group LazienkaPietroTemp "Łazienka piętro" [ "Thermostat" ]
Number PLC_LazienkaPietroTempA "Łazienka piętro"
//CWU
Group CwuTemp "C.W.U." [ "Thermostat" ]
Number PLC_CwuTempA "C.W.U."
Number PLC_CwuTempZ "C.W.U."
//Piec_CO
Number PLC_PiecZasilanieCoTemp "Zasilanie C.O."
//Media
Number PLC_WodaCisnienie "Ciśnienie wody"
//PLC_stany_urzadzen
Number PLC_StanyBramka "Bramka stany"
//PLC_Alarmy
Number PLC_AlarmModbusBlad "Modbus błąd RTU"
//PLC_Powiadomienia
Number PLC_PowPiecZasypPaliwa "Piec w trybie serwisowym"
Here full somatic log file: openhab.log.6.zip
I added new release https://github.com/docbender/openHAB-Simatic/releases/tag/1.1.4 Please test it. I tested it with your configuration and DB6 is now read correctly on my system
Hello,
thanks for Your nice work, all is OK now.
Thanks for your testing.
Now binding is ready to use in OH2