Hi @falkena,
yes, i did it, but how to change in OpenHab/BasicUI ? Setpoint can change only number. No time format. I can show it, but i can`t to change it.
Best Regards
Petr
i see. There are two solutions to get it run. Any solution need virtual items:
Create number item and configure it with Setpoint. Create a rule to recalculate Number values to DateTime values and change analog thing, configured as “time”.
Create number item and configure it with Setpoint. Create a raule to recalculate Number values to BCD-coded Number values and change analog thing, configured as “number”.
There is no simplier solution available, since Logo time/date values are BCD encoded. Additionally you need to do some bitmasking to map values to WORD’s properly. See PLCAnalogBlockHandler.java setData function for details.
Hi again,
i made new fresh install Raspbian on my RPI3, OH 2.1 via hasslefree scripts.
PLC Logo binding dont work. I put same and working configurations (cfg, things, items, sitemaps) I thing that every binding in /addons dont working…
So i restarted Logo! too.
LogoApp by Siemens in my mobilephone works good.
Any idea?
Petr
it’s really hard to get an idea without knowledge what’s going on your system setup. Is there any information in your log files? Did you delete tmp and cache folder before reinstall? Can you login to karaf console via ssh? What is the binding state? Is there some additional information in debug/trace log level?
Hi @falkena,
i made fresh new install on new SD card.
Now i see only warnings about transformation.
2017-07-02 14:47:05.094 [WARN ] [rm.AbstractFileTransformationService] - Could not transform '-' with the file 'logo.map' : Target value not found in map for '-'
Because every state is “-”
When i delete plclogo.things and put it again:
2017-07-02 15:20:32.101 [INFO ] [el.core.internal.ModelRepositoryImpl] - Loading model 'plclogo.things'
2017-07-02 15:20:32.112 [WARN ] [el.core.internal.ModelRepositoryImpl] - Configuration model 'plclogo.things' is either empty or cannot be parsed correctly!
2017-07-02 15:20:32.236 [INFO ] [el.core.internal.ModelRepositoryImpl] - Loading model 'plclogo.things'
My plclogo.things:
Bridge plclogo:device:Logo1 [ address="192.168.0.30", family="0BA8", localTSAP="0x0300", remoteTSAP="0x0200", refresh=500 ]
{
Thing analog AM_Hladina_NA [ block="AM1", type="number" ]
Thing analog AM_Hladina_KS [ block="AM2", type="number" ]
Thing analog AM_Hladina_VS [ block="AM3", type="number" ]
Thing analog VW_Nast_hladina_NA [ block="VW50", type="number" ]
Thing analog VW_Start_zavlah_1 [ block="VW24", type="time" ]
//Thing analog VW_Start_zavlah_2 [ block="VW26", type="time" ]
Thing analog VW_Interval_zavlah_1 [ block="VW14", type="number" ]
Thing analog VW_Interval_zavlah_2 [ block="VW16", type="number" ]
Thing analog VW_Interval_zavlah_3 [ block="VW18", type="number" ]
Thing analog VW_Interval_zavlah_4 [ block="VW20", type="number" ]
Thing analog VW_Interval_zavlah_K [ block="VW22", type="number" ]
Thing analog VW_Start_spin_zas_1 [ block="VW28", type="time" ]
Thing analog VW_Stop_spin_zas_1 [ block="VW30", type="time" ]
Thing analog VW_Start_spin_zas_2 [ block="VW32", type="time" ]
Thing analog VW_Stop_spin_zas_2 [ block="VW34", type="time" ]
Thing digital Q_PWM [ block="Q1" ]
Thing digital Q_Cerpadlo_KS [ block="Q2" ]
Thing digital Q_Cerpadlo_VS [ block="Q3" ]
Thing digital Q_Spinane_zasuvky [ block="Q4" ]
Thing digital Q_Kanalizacni_ventil [ block="Q5" ]
Thing digital Q_Zavlahy_1 [ block="Q8" ]
Thing digital Q_Zavlahy_2 [ block="Q9" ]
Thing digital Q_Zavlahy_3 [ block="Q10" ]
Thing digital Q_Zavlahy_4 [ block="Q11" ]
Thing digital Q_Zavlahy_K [ block="Q12" ]
Thing digital VB_Kanalizacni_ventil [ block="VB100.0" ]
Thing digital VB_Spinane_zasuvky [ block="VB108.0" ]
Thing digital VB_Casovac_spinanych_zasuvek [ block="VB105.0" ]
Thing digital VB_Casovac_zavlah [ block="VB110.0" ]
Thing digital VB_Cerpadlo_KS [ block="VB107.0" ]
Thing digital VB_Cerpadlo_VS [ block="VB109.0" ]
Thing digital VB_Start_zavlah [ block="VB103.0" ]
Thing digital VB_Start_zavlah_vetev_1 [ block="VB111.1" ]
Thing digital VB_Start_zavlah_vetev_2 [ block="VB111.2" ]
Thing digital VB_Start_zavlah_vetev_3 [ block="VB111.3" ]
Thing digital VB_Start_zavlah_vetev_4 [ block="VB111.4" ]
Thing digital VB_Start_zavlah_vetev_K [ block="VB111.5" ]
}
ok. If there is no Logo! binding load, than nothing will work. I rebuild binding for some days to 2.2 snapshot. Can you grab it from my binary repository and try? Be sure to delete 2.1 version before. Is binding load this time? If not, please set openhab log level to debug, stop openhab, delete log files and start openhab again. May be we can get some clue, what happens.
Kind regards,
Alexander.
PS: I’ve checked my installation again: it works fine on my test system.
I think that something is wrong with the jar that you donwloaded (size is smaller than what is available online)
Maybe you grabbed the blob, not the raw entry
i just published new Version of the binding with new pulse thing. New version can be download here. Additionally a lot of things are happend inside due to PR - Review.
I am glad there are so many others involved to this topic and there are now so many helpful informations.
I wanted to summarize this information into a “HowTo” and tried a totally new installation, but unfortunately, I don’t get it working again, so I am not able to do the “HowTo”
# plclogo:.host= IP address of the LOGO! PLC
Logo1.host=192.168.1.11
Logo2.host=192.168.1.12
# plclogo:.remoteTSAP= the TSAP (in hex) of the remote LOGO! PLC, as configured by LogoSoft Comfort. Common used value is 0x0200.
Logo1.remoteTSAP=0x0200
Logo2.remoteTSAP=0x0200
# plclogo::localTSAP= the TSAP (in hex) to be used by the local instance. Common used value is 0x0300.
Logo1.localTSAP=0x0100
Logo2.localTSAP=0x0100
# plclogo:refresh= polling interval in milliseconds to be used when querying the LOGO!. Default is 5000mS
refresh=1000
Logo1.model=0BA8
Logo2.model=0BA8
But I think this config file is not necessary anymore?
After that, I found the PLC Logo in the bindings and my two logos in the things.
So I changed the Local TSAP to 0x0100 and the remote TSAP to 0x0200 and set the LogoFamily to 0BA8.
there no need for plc.cfg. This file is need for the openhab1 version of binding. Please remove it. Then create logo.things file in things subdirectory:
rule "Switch Light through Logo_1"
when
Item ReadOutput01 changed or // light changed external
Item ruleSwitch01 received command // light changed internal
then
if(receivedCommand==ON ||receivedCommand==OFF) { // ensure there was a received command, so second item triggered rule
if (ReadOutput01.state != receivedCommand) { // only if state changed
invisibleSwitch01.sendCommand(ON) // send an ON
invisibleSwitch01.sendCommand(OFF) // send an OFF
}
}
else { // no trigger from proxy switch, so state changed externally
if (ReadOutput01.state != ruleSwitch01.state) { // if state changed really
ruleSwitch01.postUpdate(ReadOutput01.state) // update the state without triggering the rule
}
}
end
logo.things:
Bridge plclogo:device:Logo1 [ address="192.168.1.11", family="0BA8", localTSAP="0x0100", remoteTSAP="0x0200", refresh=100 ]
{
Thing digital VB200_2 [ block="VB200.2" ]
Thing digital VB201_2 [ block="VB201.2" ]
Thing digital Q1 [ block="Q1" ]
Thing digital Q9 [ block="Q9" ]
}
Good afternoon
is there anyone who’s using the PLC logo binding together with the latest unstable release of OH2 (at the moment 2.2.0-SNAPSHOT Build #1075).
PLC logo has worked well since last week, but now “PLC Logo” is listed as “installed” in Karaf consol, but when i try to start it, I’m getting the following error:
Error executing command: Error executing command on bundles:
Error starting bundle 15: Could not resolve module: org.openhab.binding.plclogo [15]
Unresolved requirement: Import-Package: org.apache.commons.net.util
Anyone with the same issue? Or even better: Does anyone have an advise how to resolve this issue?
Thanks!