Hop til indhold
  • 0

openHAB2 IHC binding


Pauli Anttila
 Share

Spørgsmål

Update 12.3.2019:

Binding has been merged to openHAB main repository and will available in 2.5 version. Before that, new version can be found from official openHAB snapshot builds.

Before official add-on documentation page is updated, binding documentation can found here.

 

NOTE. If you have used older beta versions of the binding, beware that there has been some breaking changes lately:

  • Controller address parameter is not anymore ip, but hostname
  • "-channel" suffix is removed from channel types. E.g. switch-channel is just switch.

 

###########################################################################################################################

 

Even openHAB 1 IHC binding has been rock solid for many years, I finally decided to port the binding to support openHAB 2 features.

Latest version: https://openhab.jfrog.io/openhab/libs-pullrequest-local/org/openhab/binding/org.openhab.binding.ihc/2.4.0-SNAPSHOT/

Documentation link

Some improvements / features:

  • By default, binding create channels automatically from project file (currently all dataline_inputs, dataline_outputs, airlink_inputs, airlink_outputs and resource_temperature).
  • Auto creation can be disabled, and channels can be created manually (then all resource id's are supported).
  • Support both Paper UI and thing files configuration.
  • Channels for basic controller information (state, SW and HW version, controller uptime, etc).
  • Trigger channels support (button short press, long press and extra long press).
  • Support multiple controllers (those who have e.g. two controllers environment).

 5b000b95160a8_ScreenShot2018-05-19at14_32_14.thumb.png.4093d93247a17cd4fc3d66307c895976.png

5b000ba2cc62b_ScreenShot2018-05-19at14_33_06.thumb.png.648edf0e40855577f58e973c448514b6.png

 

Link til kommentar
Del på andre sites

Recommended Posts

  • 0
15 timer siden, Pauli Anttila skrev:

That's a openHAB (more specifically in Eclipse SmartHome) framework limitation/issue. Same applies to all bindings (things id's or channel id's). Most probably special character aren't supported, but then e.g. PaperUI or Visual Code Studio via Language Server Protocol service in openHAB should give a warning. You could create issue on eclipse SmartHome about this.

Okay. I can live with that.. It´s just that it gave me an conflict error, (404 i think it was) which in my opinion is a bit confusing. 

Btw.. Can you show me an example of how to use the channel parameter "inverted". Can I use it in items defintion or does it have to be the actual channel? 
I have some alarm PIR´s I would like to invert. 

Link til kommentar
Del på andre sites

  • 0
10 hours ago, Kandersen said:

Btw.. Can you show me an example of how to use the channel parameter "inverted". Can I use it in items defintion or does it have to be the actual channel? 
I have some alarm PIR´s I would like to invert. 

From PaperUI (add channel manually)

1382833892_Screenshot2019-01-04at21_57_28.thumb.png.51ce3e66f0a02e8ea5bfc3bb12489600.png

Contact example in thing file:

Type contact-channel : myContact  "My Contact"  [ resourceId=3988827, inverted=true ]

Did you read the documentation? I'm just wondering if the documentation isn't clear enough?

Link til kommentar
Del på andre sites

  • 0
16 timer siden, Pauli Anttila skrev:

Did you read the documentation? I'm just wondering if the documentation isn't clear enough?

Thank you for the example.. 
I did read the doc´s several times.. I just wasn´t sure how to add these channel parameters in a channel thing file.
Regarding the docs. An option could be to use more examples, (like the above). In fact, you cant´ really make to many examples, in my opinion.. Reading the rest of the Doc while seeing examples makes things much more easier to understand and get the picture. But thats for any docs in general, not just IHC binding. I know this may seem like lots of unnecessary writing. But in my opinion, examples are the best way to understand the structure. I wouldn´t mind helping with the doc if you need it, but I´ll have to understand first as well :)
 

Link til kommentar
Del på andre sites

  • 0
4 hours ago, Kandersen said:

I wouldn´t mind helping with the doc if you need it, but I´ll have to understand first as well :)
 

 

I wrote following in page 2 ;)

On 5/28/2018 at 9:10 PM, Pauli Anttila said:

I really appreciate all help in documentation side (more detailed descriptions and examples, etc) as I don't need any documentation myself, so it's purely for your purposes :)

Link til kommentar
Del på andre sites

  • 0

I'm getting this error 5 min. after installing...  Status: OFFLINE - COMMUNICATION_ERROR javax.net.ssl.SSLProtocolException: Read timed out ... it now switchs from online to this all the time. I used the 2.4.0 Snapshot and have also tryed org.openhab.binding.ihc_2.4.0.201812182121 with same results. Any ideas why this is?? I also run home-assistent.io without problems so it seems a be strange...  

 
Link til kommentar
Del på andre sites

  • 0

@Gert Kjerslev, @veng, @Nicki Z. I updated apache http client. Could one of you run ones again following version with default 5000ms timeout (with IHC binding trace level debugs)?

https://www.dropbox.com/s/kaebm8nve8y84c7/org.openhab.binding.ihc_2.4.0.201901091843.jar?dl=0

If you still meet timeout problem, please enable http client debugs by following command from karaf console and run test again.

log:set DEBUG org.apache.http

You can disable http client debugs by 

log:set DEFAULT org.apache.http

Please, send me the log as well.

Link til kommentar
Del på andre sites

  • 0
1 time siden, Pauli Anttila skrev:

@Gert Kjerslev, @veng, @Nicki Z. I updated apache http client. Could one of you run ones again following version with default 5000ms timeout (with IHC binding trace level debugs)?

https://www.dropbox.com/s/kaebm8nve8y84c7/org.openhab.binding.ihc_2.4.0.201901091843.jar?dl=0

If you still meet timeout problem, please enable http client debugs by following command from karaf console and run test again.


log:set DEBUG org.apache.http

You can disable http client debugs by 


log:set DEFAULT org.apache.http

Please, send me the log as well.

Hi,

Same error as before, timeout = 5000ms. Logs attached

openhab.log

Link til kommentar
Del på andre sites

  • 0
På 10/1/2019 at 17:58 , Pauli Anttila skrev:

@veng, could you run with apache http debugs? Library logging has been improved since the library version which I used before. We should hopefully see what is the timeout used by the library. Please enable IHC binding logging level to trace as well.

@Pauli Anttila hi, Sorry must have made a typo in the first test. I just run the test again. see attached log.

openhab.log

Link til kommentar
Del på andre sites

  • 0
På 9/1/2019 at 18:13 , Pauli Anttila skrev:

I updated apache http client. Could one of you run ones again following version with default 5000ms timeout (with IHC binding trace level debugs)?

https://www.dropbox.com/s/kaebm8nve8y84c7/org.openhab.binding.ihc_2.4.0.201901091843.jar?dl=0

I just installed this version of the binding and I got this error when the binding started. It works fine though:
 


 

2019-01-12 15:59:29.738 [hingStatusInfoChangedEvent] - 'ihc:controller:elko' changed from UNINITIALIZED (HANDLER_CONFIGURATION_PENDING) to INITIALIZING

2019-01-12 15:59:29.787 [me.event.ThingUpdatedEvent] - Thing 'ihc:controller:elko' has been updated.

==> /var/log/openhab2/openhab.log <==

2019-01-12 15:59:29.900 [INFO ] [org.openhab.binding.ihc ] - FrameworkEvent INFO - org.openhab.binding.ihc

java.io.IOException: Exception in opening zip file: /var/lib/openhab2/cache/org.eclipse.osgi/198/0/bundleFile

at org.eclipse.osgi.framework.util.SecureAction.getZipFile(SecureAction.java:321) ~[?:?]

at org.eclipse.osgi.storage.bundlefile.ZipBundleFile.basicOpen(ZipBundleFile.java:93) ~[?:?]

at org.eclipse.osgi.storage.bundlefile.ZipBundleFile.getZipFile(ZipBundleFile.java:106) ~[?:?]

at org.eclipse.osgi.storage.bundlefile.ZipBundleFile.checkedOpen(ZipBundleFile.java:65) ~[?:?]

at org.eclipse.osgi.storage.bundlefile.ZipBundleFile.getEntry(ZipBundleFile.java:240) ~[?:?]

at org.eclipse.osgi.internal.loader.classpath.ClasspathManager.findClassImpl(ClasspathManager.java:560) ~[?:?]

at org.eclipse.osgi.internal.loader.classpath.ClasspathManager.findLocalClassImpl(ClasspathManager.java:538) ~[?:?]

at org.eclipse.osgi.internal.loader.classpath.ClasspathManager.findLocalClass(ClasspathManager.java:525) ~[?:?]

at org.eclipse.osgi.internal.loader.ModuleClassLoader.findLocalClass(ModuleClassLoader.java:328) ~[?:?]

at org.eclipse.osgi.internal.loader.BundleLoader.findLocalClass(BundleLoader.java:368) ~[?:?]

at org.eclipse.osgi.internal.loader.BundleLoader.findClassInternal(BundleLoader.java:446) ~[?:?]

at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:395) ~[?:?]

at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:387) ~[?:?]

at org.eclipse.osgi.internal.loader.ModuleClassLoader.loadClass(ModuleClassLoader.java:150) ~[?:?]

at java.lang.ClassLoader.loadClass(ClassLoader.java:357) ~[?:?]

at java.lang.Class.forName0(Native Method) ~[?:?]

at java.lang.Class.forName(Class.java:348) ~[?:?]

at org.apache.commons.logging.impl.LogFactoryImpl.createLogFromClass(LogFactoryImpl.java:998) ~[?:?]

at org.apache.commons.logging.impl.LogFactoryImpl.discoverLogImplementation(LogFactoryImpl.java:844) ~[?:?]

at org.apache.commons.logging.impl.LogFactoryImpl.newInstance(LogFactoryImpl.java:541) ~[?:?]

at org.apache.commons.logging.impl.LogFactoryImpl.getInstance(LogFactoryImpl.java:292) ~[?:?]

at org.apache.commons.logging.impl.LogFactoryImpl.getInstance(LogFactoryImpl.java:269) ~[?:?]

at org.apache.commons.logging.LogFactory.getLog(LogFactory.java:655) ~[6:org.ops4j.pax.logging.pax-logging-api:1.10.1]

at org.apache.http.conn.ssl.AbstractVerifier.<init>(AbstractVerifier.java:61) ~[?:?]

at org.apache.http.conn.ssl.AllowAllHostnameVerifier.<init>(AllowAllHostnameVerifier.java:44) ~[?:?]

at org.apache.http.conn.ssl.AllowAllHostnameVerifier.<clinit>(AllowAllHostnameVerifier.java:46) ~[?:?]

at org.apache.http.conn.ssl.SSLConnectionSocketFactory.<clinit>(SSLConnectionSocketFactory.java:146) ~[?:?]

at org.openhab.binding.ihc.internal.ws.http.IhcConnectionPool.init(IhcConnectionPool.java:122) ~[?:?]

at org.openhab.binding.ihc.internal.ws.http.IhcConnectionPool.<init>(IhcConnectionPool.java:57) ~[?:?]

at org.openhab.binding.ihc.internal.ws.IhcClient.openConnection(IhcClient.java:168) ~[?:?]

at org.openhab.binding.ihc.internal.handler.IhcHandler.connect(IhcHandler.java:521) ~[?:?]

at org.openhab.binding.ihc.internal.handler.IhcHandler.reconnectCheck(IhcHandler.java:826) ~[?:?]

at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) ~[?:?]

at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:308) ~[?:?]

at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:180) ~[?:?]

at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:294) ~[?:?]

at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) ~[?:?]

at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) ~[?:?]

at java.lang.Thread.run(Thread.java:748) ~[?:?]

Caused by: java.io.FileNotFoundException: /var/lib/openhab2/cache/org.eclipse.osgi/198/0/bundleFile (No such file or directory)

at java.util.zip.ZipFile.open(Native Method) ~[?:?]

at java.util.zip.ZipFile.<init>(ZipFile.java:225) ~[?:?]

at java.util.zip.ZipFile.<init>(ZipFile.java:155) ~[?:?]

at java.util.zip.ZipFile.<init>(ZipFile.java:169) ~[?:?]

at org.eclipse.osgi.framework.util.SecureAction$16.run(SecureAction.java:308) ~[?:?]

at org.eclipse.osgi.framework.util.SecureAction$16.run(SecureAction.java:1) ~[?:?]

at java.security.AccessController.doPrivileged(Native Method) ~[?:?]

at org.eclipse.osgi.framework.util.SecureAction.getZipFile(SecureAction.java:306) ~[?:?]

... 38 more

2019-01-12 15:59:30.012 [INFO ] [org.openhab.binding.ihc ] - FrameworkEvent INFO - org.openhab.binding.ihc

java.io.IOException: Exception in opening zip file: /var/lib/openhab2/cache/org.eclipse.osgi/198/0/.cp/lib/commons-logging-1.2.jar

at org.eclipse.osgi.framework.util.SecureAction.getZipFile(SecureAction.java:321) ~[?:?]

at org.eclipse.osgi.storage.bundlefile.ZipBundleFile.basicOpen(ZipBundleFile.java:93) ~[?:?]

at org.eclipse.osgi.storage.bundlefile.ZipBundleFile.getZipFile(ZipBundleFile.java:106) ~[?:?]

at org.eclipse.osgi.storage.bundlefile.ZipBundleFile.checkedOpen(ZipBundleFile.java:65) ~[?:?]

at org.eclipse.osgi.storage.bundlefile.ZipBundleFile.getEntry(ZipBundleFile.java:240) ~[?:?]

at org.eclipse.osgi.internal.loader.classpath.ClasspathManager.findClassImpl(ClasspathManager.java:560) ~[?:?]

at org.eclipse.osgi.internal.loader.classpath.ClasspathManager.findLocalClassImpl(ClasspathManager.java:538) ~[?:?]

at org.eclipse.osgi.internal.loader.classpath.ClasspathManager.findLocalClass(ClasspathManager.java:525) ~[?:?]

at org.eclipse.osgi.internal.loader.ModuleClassLoader.findLocalClass(ModuleClassLoader.java:328) ~[?:?]

at org.eclipse.osgi.internal.loader.BundleLoader.findLocalClass(BundleLoader.java:368) ~[?:?]

at org.eclipse.osgi.internal.loader.BundleLoader.findClassInternal(BundleLoader.java:446) ~[?:?]

at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:395) ~[?:?]

at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:387) ~[?:?]

at org.eclipse.osgi.internal.loader.ModuleClassLoader.loadClass(ModuleClassLoader.java:150) ~[?:?]

at java.lang.ClassLoader.loadClass(ClassLoader.java:357) ~[?:?]

at java.lang.Class.forName0(Native Method) ~[?:?]

at java.lang.Class.forName(Class.java:348) ~[?:?]

at org.apache.commons.logging.impl.LogFactoryImpl.createLogFromClass(LogFactoryImpl.java:998) ~[?:?]

at org.apache.commons.logging.impl.LogFactoryImpl.discoverLogImplementation(LogFactoryImpl.java:844) ~[?:?]

at org.apache.commons.logging.impl.LogFactoryImpl.newInstance(LogFactoryImpl.java:541) ~[?:?]

at org.apache.commons.logging.impl.LogFactoryImpl.getInstance(LogFactoryImpl.java:292) ~[?:?]

at org.apache.commons.logging.impl.LogFactoryImpl.getInstance(LogFactoryImpl.java:269) ~[?:?]

at org.apache.commons.logging.LogFactory.getLog(LogFactory.java:655) ~[6:org.ops4j.pax.logging.pax-logging-api:1.10.1]

at org.apache.http.conn.ssl.AbstractVerifier.<init>(AbstractVerifier.java:61) ~[?:?]

at org.apache.http.conn.ssl.AllowAllHostnameVerifier.<init>(AllowAllHostnameVerifier.java:44) ~[?:?]

at org.apache.http.conn.ssl.AllowAllHostnameVerifier.<clinit>(AllowAllHostnameVerifier.java:46) ~[?:?]

at org.apache.http.conn.ssl.SSLConnectionSocketFactory.<clinit>(SSLConnectionSocketFactory.java:146) ~[?:?]

at org.openhab.binding.ihc.internal.ws.http.IhcConnectionPool.init(IhcConnectionPool.java:122) ~[?:?]

at org.openhab.binding.ihc.internal.ws.http.IhcConnectionPool.<init>(IhcConnectionPool.java:57) ~[?:?]

at org.openhab.binding.ihc.internal.ws.IhcClient.openConnection(IhcClient.java:168) ~[?:?]

at org.openhab.binding.ihc.internal.handler.IhcHandler.connect(IhcHandler.java:521) ~[?:?]

at org.openhab.binding.ihc.internal.handler.IhcHandler.reconnectCheck(IhcHandler.java:826) ~[?:?]

at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) ~[?:?]

at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:308) ~[?:?]

at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:180) ~[?:?]

at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:294) ~[?:?]

at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) ~[?:?]

at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) ~[?:?]

at java.lang.Thread.run(Thread.java:748) ~[?:?]

Caused by: java.io.FileNotFoundException: /var/lib/openhab2/cache/org.eclipse.osgi/198/0/.cp/lib/commons-logging-1.2.jar (No such file or directory)

at java.util.zip.ZipFile.open(Native Method) ~[?:?]

at java.util.zip.ZipFile.<init>(ZipFile.java:225) ~[?:?]

at java.util.zip.ZipFile.<init>(ZipFile.java:155) ~[?:?]

at java.util.zip.ZipFile.<init>(ZipFile.java:169) ~[?:?]

at org.eclipse.osgi.framework.util.SecureAction$16.run(SecureAction.java:308) ~[?:?]

at org.eclipse.osgi.framework.util.SecureAction$16.run(SecureAction.java:1) ~[?:?]

at java.security.AccessController.doPrivileged(Native Method) ~[?:?]

at org.eclipse.osgi.framework.util.SecureAction.getZipFile(SecureAction.java:306) ~[?:?]

... 38 more

2019-01-12 15:59:30.059 [INFO ] [org.openhab.binding.ihc ] - FrameworkEvent INFO - org.openhab.binding.ihc

java.io.IOException: Exception in opening zip file: /var/lib/openhab2/cache/org.eclipse.osgi/198/0/.cp/lib/org.apache.httpcomponents.httpclient_4.4.1.jar

at org.eclipse.osgi.framework.util.SecureAction.getZipFile(SecureAction.java:321) ~[?:?]

at org.eclipse.osgi.storage.bundlefile.ZipBundleFile.basicOpen(ZipBundleFile.java:93) ~[?:?]

at org.eclipse.osgi.storage.bundlefile.ZipBundleFile.getZipFile(ZipBundleFile.java:106) ~[?:?]

at org.eclipse.osgi.storage.bundlefile.ZipBundleFile.checkedOpen(ZipBundleFile.java:65) ~[?:?]

at org.eclipse.osgi.storage.bundlefile.ZipBundleFile.getEntry(ZipBundleFile.java:240) ~[?:?]

at org.eclipse.osgi.internal.loader.classpath.ClasspathManager.findClassImpl(ClasspathManager.java:560) ~[?:?]

at org.eclipse.osgi.internal.loader.classpath.ClasspathManager.findLocalClassImpl(ClasspathManager.java:538) ~[?:?]

at org.eclipse.osgi.internal.loader.classpath.ClasspathManager.findLocalClass(ClasspathManager.java:525) ~[?:?]

at org.eclipse.osgi.internal.loader.ModuleClassLoader.findLocalClass(ModuleClassLoader.java:328) ~[?:?]

at org.eclipse.osgi.internal.loader.BundleLoader.findLocalClass(BundleLoader.java:368) ~[?:?]

at org.eclipse.osgi.internal.loader.BundleLoader.findClassInternal(BundleLoader.java:446) ~[?:?]

at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:395) ~[?:?]

at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:387) ~[?:?]

at org.eclipse.osgi.internal.loader.ModuleClassLoader.loadClass(ModuleClassLoader.java:150) ~[?:?]

at java.lang.ClassLoader.loadClass(ClassLoader.java:357) ~[?:?]

at java.lang.Class.forName0(Native Method) ~[?:?]

at java.lang.Class.forName(Class.java:348) ~[?:?]

at org.apache.commons.logging.impl.LogFactoryImpl.createLogFromClass(LogFactoryImpl.java:998) ~[?:?]

at org.apache.commons.logging.impl.LogFactoryImpl.discoverLogImplementation(LogFactoryImpl.java:844) ~[?:?]

at org.apache.commons.logging.impl.LogFactoryImpl.newInstance(LogFactoryImpl.java:541) ~[?:?]

at org.apache.commons.logging.impl.LogFactoryImpl.getInstance(LogFactoryImpl.java:292) ~[?:?]

at org.apache.commons.logging.impl.LogFactoryImpl.getInstance(LogFactoryImpl.java:269) ~[?:?]

at org.apache.commons.logging.LogFactory.getLog(LogFactory.java:655) ~[6:org.ops4j.pax.logging.pax-logging-api:1.10.1]

at org.apache.http.conn.ssl.AbstractVerifier.<init>(AbstractVerifier.java:61) ~[?:?]

at org.apache.http.conn.ssl.AllowAllHostnameVerifier.<init>(AllowAllHostnameVerifier.java:44) ~[?:?]

at org.apache.http.conn.ssl.AllowAllHostnameVerifier.<clinit>(AllowAllHostnameVerifier.java:46) ~[?:?]

at org.apache.http.conn.ssl.SSLConnectionSocketFactory.<clinit>(SSLConnectionSocketFactory.java:146) ~[?:?]

at org.openhab.binding.ihc.internal.ws.http.IhcConnectionPool.init(IhcConnectionPool.java:122) ~[?:?]

at org.openhab.binding.ihc.internal.ws.http.IhcConnectionPool.<init>(IhcConnectionPool.java:57) ~[?:?]

at org.openhab.binding.ihc.internal.ws.IhcClient.openConnection(IhcClient.java:168) ~[?:?]

at org.openhab.binding.ihc.internal.handler.IhcHandler.connect(IhcHandler.java:521) ~[?:?]

at org.openhab.binding.ihc.internal.handler.IhcHandler.reconnectCheck(IhcHandler.java:826) ~[?:?]

at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) ~[?:?]

at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:308) ~[?:?]

at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:180) ~[?:?]

at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:294) ~[?:?]

at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) ~[?:?]

at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) ~[?:?]

at java.lang.Thread.run(Thread.java:748) ~[?:?]

Caused by: java.io.FileNotFoundException: /var/lib/openhab2/cache/org.eclipse.osgi/198/0/.cp/lib/org.apache.httpcomponents.httpclient_4.4.1.jar (No such file or directory)

at java.util.zip.ZipFile.open(Native Method) ~[?:?]

at java.util.zip.ZipFile.<init>(ZipFile.java:225) ~[?:?]

at java.util.zip.ZipFile.<init>(ZipFile.java:155) ~[?:?]

at java.util.zip.ZipFile.<init>(ZipFile.java:169) ~[?:?]

at org.eclipse.osgi.framework.util.SecureAction$16.run(SecureAction.java:308) ~[?:?]

at org.eclipse.osgi.framework.util.SecureAction$16.run(SecureAction.java:1) ~[?:?]

at java.security.AccessController.doPrivileged(Native Method) ~[?:?]

at org.eclipse.osgi.framework.util.SecureAction.getZipFile(SecureAction.java:306) ~[?:?]

... 38 more

2019-01-12 15:59:30.117 [INFO ] [org.openhab.binding.ihc ] - FrameworkEvent INFO - org.openhab.binding.ihc

java.io.IOException: Exception in opening zip file: /var/lib/openhab2/cache/org.eclipse.osgi/198/0/.cp/lib/org.apache.httpcomponents.httpcore_4.4.1.jar

at org.eclipse.osgi.framework.util.SecureAction.getZipFile(SecureAction.java:321) ~[?:?]

at org.eclipse.osgi.storage.bundlefile.ZipBundleFile.basicOpen(ZipBundleFile.java:93) ~[?:?]

at org.eclipse.osgi.storage.bundlefile.ZipBundleFile.getZipFile(ZipBundleFile.java:106) ~[?:?]

at org.eclipse.osgi.storage.bundlefile.ZipBundleFile.checkedOpen(ZipBundleFile.java:65) ~[?:?]

at org.eclipse.osgi.storage.bundlefile.ZipBundleFile.getEntry(ZipBundleFile.java:240) ~[?:?]

at org.eclipse.osgi.internal.loader.classpath.ClasspathManager.findClassImpl(ClasspathManager.java:560) ~[?:?]

at org.eclipse.osgi.internal.loader.classpath.ClasspathManager.findLocalClassImpl(ClasspathManager.java:538) ~[?:?]

at org.eclipse.osgi.internal.loader.classpath.ClasspathManager.findLocalClass(ClasspathManager.java:525) ~[?:?]

at org.eclipse.osgi.internal.loader.ModuleClassLoader.findLocalClass(ModuleClassLoader.java:328) ~[?:?]

at org.eclipse.osgi.internal.loader.BundleLoader.findLocalClass(BundleLoader.java:368) ~[?:?]

at org.eclipse.osgi.internal.loader.BundleLoader.findClassInternal(BundleLoader.java:446) ~[?:?]

at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:395) ~[?:?]

at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:387) ~[?:?]

at org.eclipse.osgi.internal.loader.ModuleClassLoader.loadClass(ModuleClassLoader.java:150) ~[?:?]

at java.lang.ClassLoader.loadClass(ClassLoader.java:357) ~[?:?]

at java.lang.Class.forName0(Native Method) ~[?:?]

at java.lang.Class.forName(Class.java:348) ~[?:?]

at org.apache.commons.logging.impl.LogFactoryImpl.createLogFromClass(LogFactoryImpl.java:998) ~[?:?]

at org.apache.commons.logging.impl.LogFactoryImpl.discoverLogImplementation(LogFactoryImpl.java:844) ~[?:?]

at org.apache.commons.logging.impl.LogFactoryImpl.newInstance(LogFactoryImpl.java:541) ~[?:?]

at org.apache.commons.logging.impl.LogFactoryImpl.getInstance(LogFactoryImpl.java:292) ~[?:?]

at org.apache.commons.logging.impl.LogFactoryImpl.getInstance(LogFactoryImpl.java:269) ~[?:?]

at org.apache.commons.logging.LogFactory.getLog(LogFactory.java:655) ~[6:org.ops4j.pax.logging.pax-logging-api:1.10.1]

at org.apache.http.conn.ssl.AbstractVerifier.<init>(AbstractVerifier.java:61) ~[?:?]

at org.apache.http.conn.ssl.AllowAllHostnameVerifier.<init>(AllowAllHostnameVerifier.java:44) ~[?:?]

at org.apache.http.conn.ssl.AllowAllHostnameVerifier.<clinit>(AllowAllHostnameVerifier.java:46) ~[?:?]

at org.apache.http.conn.ssl.SSLConnectionSocketFactory.<clinit>(SSLConnectionSocketFactory.java:146) ~[?:?]

at org.openhab.binding.ihc.internal.ws.http.IhcConnectionPool.init(IhcConnectionPool.java:122) ~[?:?]

at org.openhab.binding.ihc.internal.ws.http.IhcConnectionPool.<init>(IhcConnectionPool.java:57) ~[?:?]

at org.openhab.binding.ihc.internal.ws.IhcClient.openConnection(IhcClient.java:168) ~[?:?]

at org.openhab.binding.ihc.internal.handler.IhcHandler.connect(IhcHandler.java:521) ~[?:?]

at org.openhab.binding.ihc.internal.handler.IhcHandler.reconnectCheck(IhcHandler.java:826) ~[?:?]

at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) ~[?:?]

at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:308) ~[?:?]

at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:180) ~[?:?]

at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:294) ~[?:?]

at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) ~[?:?]

at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) ~[?:?]

at java.lang.Thread.run(Thread.java:748) ~[?:?]

Caused by: java.io.FileNotFoundException: /var/lib/openhab2/cache/org.eclipse.osgi/198/0/.cp/lib/org.apache.httpcomponents.httpcore_4.4.1.jar (No such file or directory)

at java.util.zip.ZipFile.open(Native Method) ~[?:?]

at java.util.zip.ZipFile.<init>(ZipFile.java:225) ~[?:?]

at java.util.zip.ZipFile.<init>(ZipFile.java:155) ~[?:?]

at java.util.zip.ZipFile.<init>(ZipFile.java:169) ~[?:?]

at org.eclipse.osgi.framework.util.SecureAction$16.run(SecureAction.java:308) ~[?:?]

at org.eclipse.osgi.framework.util.SecureAction$16.run(SecureAction.java:1) ~[?:?]

at java.security.AccessController.doPrivileged(Native Method) ~[?:?]

at org.eclipse.osgi.framework.util.SecureAction.getZipFile(SecureAction.java:306) ~[?:?]

... 38 more

==> /var/log/openhab2/events.log <==

2019-01-12 15:59:36.216 [hingStatusInfoChangedEvent] - 'ihc:controller:elko' changed from INITIALIZING to OFFLINE: Initializing communication to the IHC / ELKO controller

2019-01-12 15:59:36.567 [vent.ItemStateChangedEvent] - ControllerState changed from ready to Ready

2019-01-12 15:59:36.845 [vent.ItemStateChangedEvent] - ControllerUpTime changed from 1055107.986 to 1203224.861

2019-01-12 15:59:37.017 [vent.ItemStateChangedEvent] - ControllerDateTime changed from 2019-01-10T22:51:52.000+0100 to 2019-01-12T16:00:29.000+0100

2019-01-12 15:59:39.934 [me.event.ThingUpdatedEvent] - Thing 'ihc:controller:elko' has been updated.

2019-01-12 15:59:40.354 [me.event.ThingUpdatedEvent] - Thing 'ihc:controller:elko' has been updated.

2019-01-12 15:59:40.630 [vent.ItemStateChangedEvent] - ControllerUpTime changed from 1203224.861 to 1203228.756

2019-01-12 15:59:40.789 [vent.ItemStateChangedEvent] - ControllerDateTime changed from 2019-01-12T16:00:29.000+0100 to 2019-01-12T16:00:33.000+0100

2019-01-12 15:59:40.797 [hingStatusInfoChangedEvent] - 'ihc:controller:elko' changed from OFFLINE: Initializing communication to the IHC / ELKO controller to ONLINE

Link til kommentar
Del på andre sites

  • 0

@Pauli Anttila
This is a reboot of the Rpi with the latest IHC binding. It still runs fine though: 
 

2019-01-12 16:45:05.447 [WARN ] [.profiles.PushButtonToCommandProfile] - Parameter 'timeout' is not of type BigDecimal, using default value '10000'

==> /var/log/openhab2/events.log <==

2019-01-12 16:45:07.097 [hingStatusInfoChangedEvent] - 'ihc:controller:elko' changed from INITIALIZING to OFFLINE: Initializing communication to the IHC / ELKO controller

==> /var/log/openhab2/openhab.log <==

2019-01-12 16:45:07.383 [WARN ] [ding.ihc.internal.handler.IhcHandler] - Controller uptime information fetch failed, reason:  Error occured during XML data parsing
2019-01-12 16:45:07.474 [WARN ] [ding.ihc.internal.handler.IhcHandler] - Controller state information fetch failed, reason:  Error occured during XML data parsing
2019-01-12 16:45:07.556 [WARN ] [ding.ihc.internal.handler.IhcHandler] - Controller uptime information fetch failed, reason:  Error occured during XML data parsing

==> /var/log/openhab2/events.log <==

2019-01-12 16:45:10.812 [me.event.ThingUpdatedEvent] - Thing 'ihc:controller:elko' has been updated.

==> /var/log/openhab2/openhab.log <==

2019-01-12 16:45:10.913 [WARN ] [ding.ihc.internal.handler.IhcHandler] - Controller information fetch failed, reason:  Error occured during XML data parsing
2019-01-12 16:45:11.026 [WARN ] [ding.ihc.internal.handler.IhcHandler] - Controller state information fetch failed, reason:  Error occured during XML data parsing
2019-01-12 16:45:11.150 [WARN ] [ding.ihc.internal.handler.IhcHandler] - Controller uptime information fetch failed, reason:  Error occured during XML data parsing
2019-01-12 16:45:11.291 [WARN ] [ding.ihc.internal.handler.IhcHandler] - Controller uptime information fetch failed, reason:  Error occured during XML data parsing

==> /var/log/openhab2/events.log <==

2019-01-12 16:45:11.317 [hingStatusInfoChangedEvent] - 'ihc:controller:elko' changed from OFFLINE: Initializing communication to the IHC / ELKO controller to ONLINE

==> /var/log/openhab2/openhab.log <==

2019-01-12 16:45:11.489 [ERROR] [ab.binding.ihc.internal.ws.IhcClient] - New controller state change notification wait failed...
org.openhab.binding.ihc.internal.ws.exeptions.IhcExecption: Error occured during XML data parsing
    at org.openhab.binding.ihc.internal.ws.datatypes.WSControllerState.parseXMLData(WSControllerState.java:59) ~[229:org.openhab.binding.ihc:2.4.0.201901091843]
    at org.openhab.binding.ihc.internal.ws.services.IhcControllerService.getControllerState(IhcControllerService.java:104) ~[229:org.openhab.binding.ihc:2.4.0.201901091843]
    at org.openhab.binding.ihc.internal.ws.IhcClient$IhcControllerStateListener.run(IhcClient.java:502) [229:org.openhab.binding.ihc:2.4.0.201901091843]
Caused by: org.openhab.binding.ihc.internal.ws.exeptions.IhcExecption: Encoding error, unsupported data
    at org.openhab.binding.ihc.internal.ws.datatypes.WSControllerState.parseXMLData(WSControllerState.java:55) ~[?:?]
    ... 2 more

2019-01-12 16:45:11.508 [WARN ] [ding.ihc.internal.handler.IhcHandler] - Error occurred on communication to IHC controller: Error occured during XML data parsing

==> /var/log/openhab2/events.log <==

2019-01-12 16:45:18.099 [hingStatusInfoChangedEvent] - 'ihc:controller:elko' changed from ONLINE to OFFLINE: Initializing communication to the IHC / ELKO controller
2019-01-12 16:45:19.539 [me.event.ThingUpdatedEvent] - Thing 'ihc:controller:elko' has been updated.
2019-01-12 16:45:20.427 [me.event.ThingUpdatedEvent] - Thing 'ihc:controller:elko' has been updated.
2019-01-12 16:45:20.529 [vent.ItemStateChangedEvent] - ControllerState changed from NULL to Ready
2019-01-12 16:45:20.768 [vent.ItemStateChangedEvent] - ControllerUpTime changed from NULL to 1205968.885
2019-01-12 16:45:20.952 [hingStatusInfoChangedEvent] - 'ihc:controller:elko' changed from OFFLINE: Initializing communication to the IHC / ELKO controller to ONLINE
2019-01-12 16:45:20.958 [vent.ItemStateChangedEvent] - ControllerDateTime changed from NULL to 2019-01-12T16:46:13.000+0100
Link til kommentar
Del på andre sites

  • 0

Hi

I have just set up openHAB2 on a Windows machine and it seems to work with IHC and HomeKit integration.
One question is how I set up dimmers correctly so that I can dim the lights from the Home app. Is this possible?

The normal switch "LysMathias" works just fine and turns on/off via the Home app.
The dimmers does not work (lights are not dimming when trying from the Home app), but I see that openHAB2 get the changes from HomeKit.
I tried using the IHC IDs both from the output and input without any luck.

My OpenHAB.log returns some errors, but I believe this could relate to the answer above. Correct me if I am wrong.

Using newest IHC binding (version 2.4.0.201812081313).

.items
Switch LysMathias "Loft Lys Mathias" <light> ["Lighting"] {ihc="77915"}
Dimmer Sofabord "Sofabord" <light> ["Lighting"] {ihc="7147282"}
Dimmer Spisebord "Spisebord" <light> ["Lighting"] {ihc="29020"}

events.log
2019-01-16 21:43:50.341 [ome.event.ItemCommandEvent] - Item 'Spisebord' received command OFF
2019-01-16 21:43:50.357 [vent.ItemStateChangedEvent] - Spisebord changed from 100 to 0
2019-01-16 21:43:51.185 [ome.event.ItemCommandEvent] - Item 'Spisebord' received command ON
2019-01-16 21:43:51.185 [ome.event.ItemCommandEvent] - Item 'Spisebord' received command 100
2019-01-16 21:43:51.653 [vent.ItemStateChangedEvent] - Spisebord changed from 0 to 100
2019-01-16 21:43:53.762 [ome.event.ItemCommandEvent] - Item 'Spisebord' received command ON
2019-01-16 21:43:53.762 [ome.event.ItemCommandEvent] - Item 'Spisebord' received command 48
2019-01-16 21:43:54.090 [vent.ItemStateChangedEvent] - Spisebord changed from 100 to 48
2019-01-16 21:43:56.059 [ome.event.ItemCommandEvent] - Item 'Spisebord' received command OFF
2019-01-16 21:43:56.074 [vent.ItemStateChangedEvent] - Spisebord changed from 48 to 0

openhab.log
2019-01-17 08:03:14.536 [ERROR] [lfe.hap.impl.http.impl.BinaryHandler] - Exception in binary handler
java.io.IOException: En eksisterende forbindelse blev tvangsafbrudt af en ekstern vært
    at sun.nio.ch.SocketDispatcher.read0(Native Method) ~[?:?]
    at sun.nio.ch.SocketDispatcher.read(SocketDispatcher.java:43) ~[?:?]
    at sun.nio.ch.IOUtil.readIntoNativeBuffer(IOUtil.java:223) ~[?:?]
    at sun.nio.ch.IOUtil.read(IOUtil.java:192) ~[?:?]
    at sun.nio.ch.SocketChannelImpl.read(SocketChannelImpl.java:380) ~[?:?]
    at io.netty.buffer.UnpooledUnsafeDirectByteBuf.setBytes(UnpooledUnsafeDirectByteBuf.java:447) ~[226:org.openhab.io.homekit:2.4.0]
    at io.netty.buffer.AbstractByteBuf.writeBytes(AbstractByteBuf.java:880) ~[226:org.openhab.io.homekit:2.4.0]
    at io.netty.channel.socket.nio.NioSocketChannel.doReadBytes(NioSocketChannel.java:242) ~[226:org.openhab.io.homekit:2.4.0]
    at io.netty.channel.nio.AbstractNioByteChannel$NioByteUnsafe.read(AbstractNioByteChannel.java:119) [226:org.openhab.io.homekit:2.4.0]
    at io.netty.channel.nio.NioEventLoop.processSelectedKey(NioEventLoop.java:511) [226:org.openhab.io.homekit:2.4.0]
    at io.netty.channel.nio.NioEventLoop.processSelectedKeysOptimized(NioEventLoop.java:468) [226:org.openhab.io.homekit:2.4.0]
    at io.netty.channel.nio.NioEventLoop.processSelectedKeys(NioEventLoop.java:382) [226:org.openhab.io.homekit:2.4.0]
    at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:354) [226:org.openhab.io.homekit:2.4.0]
    at io.netty.util.concurrent.SingleThreadEventExecutor$2.run(SingleThreadEventExecutor.java:112) [226:org.openhab.io.homekit:2.4.0]
    at io.netty.util.concurrent.DefaultThreadFactory$DefaultRunnableDecorator.run(DefaultThreadFactory.java:137) [226:org.openhab.io.homekit:2.4.0]
    at java.lang.Thread.run(Thread.java:748) [?:?]
2019-01-17 08:03:14.536 [ERROR] [.hap.impl.http.impl.AccessoryHandler] - Exception caught in web handler
java.io.IOException: En eksisterende forbindelse blev tvangsafbrudt af en ekstern vært
    at sun.nio.ch.SocketDispatcher.read0(Native Method) ~[?:?]
    at sun.nio.ch.SocketDispatcher.read(SocketDispatcher.java:43) ~[?:?]
    at sun.nio.ch.IOUtil.readIntoNativeBuffer(IOUtil.java:223) ~[?:?]
    at sun.nio.ch.IOUtil.read(IOUtil.java:192) ~[?:?]
    at sun.nio.ch.SocketChannelImpl.read(SocketChannelImpl.java:380) ~[?:?]
    at io.netty.buffer.UnpooledUnsafeDirectByteBuf.setBytes(UnpooledUnsafeDirectByteBuf.java:447) ~[226:org.openhab.io.homekit:2.4.0]
    at io.netty.buffer.AbstractByteBuf.writeBytes(AbstractByteBuf.java:880) ~[226:org.openhab.io.homekit:2.4.0]
    at io.netty.channel.socket.nio.NioSocketChannel.doReadBytes(NioSocketChannel.java:242) ~[226:org.openhab.io.homekit:2.4.0]
    at io.netty.channel.nio.AbstractNioByteChannel$NioByteUnsafe.read(AbstractNioByteChannel.java:119) ~[226:org.openhab.io.homekit:2.4.0]
    at io.netty.channel.nio.NioEventLoop.processSelectedKey(NioEventLoop.java:511) ~[226:org.openhab.io.homekit:2.4.0]
    at io.netty.channel.nio.NioEventLoop.processSelectedKeysOptimized(NioEventLoop.java:468) ~[226:org.openhab.io.homekit:2.4.0]
    at io.netty.channel.nio.NioEventLoop.processSelectedKeys(NioEventLoop.java:382) ~[226:org.openhab.io.homekit:2.4.0]
    at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:354) ~[226:org.openhab.io.homekit:2.4.0]
    at io.netty.util.concurrent.SingleThreadEventExecutor$2.run(SingleThreadEventExecutor.java:112) [226:org.openhab.io.homekit:2.4.0]
    at io.netty.util.concurrent.DefaultThreadFactory$DefaultRunnableDecorator.run(DefaultThreadFactory.java:137) [226:org.openhab.io.homekit:2.4.0]
    at java.lang.Thread.run(Thread.java:748) [?:?]

Link til kommentar
Del på andre sites

  • 0

Hi 

Found the answer: https://github.com/openhab/openhab2-addons/issues/2782
Check out weakfl's post:

your.items example

Dimmer KitchenCeilingLight                      "Deckenlampe" <light> (gKitchen, gLights) { channel="zigbee:device:XYZ_1_switch_level" }
Dimmer KitchenCeilingLightHomeKit               "Deckenlampe" <light> (gKitchen) [ "Lighting" ]

your.rules example:

// Kitchen Ceiling Light

rule "KitchenCeilingLightHomeKit"

when

    Item KitchenCeilingLightHomeKit received command

then

    if (receivedCommand != ON && receivedCommand != OFF) {

       KitchenCeilingLight.sendCommand(receivedCommand)

    } else if (receivedCommand == OFF) {

       KitchenCeilingLight.sendCommand(0)

    }

end

 

rule "KitchenCeilingLight"

when

    Item KitchenCeilingLight received update

then

    val level = KitchenCeilingLight.state as Number

   KitchenCeilingLightHomeKit.postUpdate(level)

end

Link til kommentar
Del på andre sites

  • 0
På 6.6.2018 at 20:33 , Pauli Anttila skrev:

Just updated the link to latest binding version. I have made many breaking changes to the binding. I removed pulse output channel as now every channel can send pulse if pulseWidth parameter is defined. Every channel also have now commandToReact parameter which can be used to filter commands. 

So following should be now possible


Type switch-channel  : ihcoutput  "IHC output"   [ resourceId=1736539, direction="ReadOnly" ]
Type switch-channel  : ihcinput1  "IHC input 1"  [ resourceId=2448474, direction="WriteOnly", pulseWidth=1000, commandToReact="ON" ]
Type switch-channel  : ihcinput2  "IHC input 2"  [ resourceId=2448218, direction="WriteOnly", pulseWidth=1000, commandToReact="OFF" ]

I have not test new version very well, so there could be bugs.

Hi @Pauli Anttila I assume you refere to the above (from page 3)?
And then @EjvindHald example (from page 2):
 

item:
Switch    IHC2Spisebord "Spisebord"      {channel="ihc:controller:haldIHC:ihcoutput", channel="ihc:controller:haldIHC:ihcinput1", channel="ihc:controller:haldIHC:ihcinput2"}

things:
Type switch-channel               : ihcoutput   "IHC output"    [resourceId=3932434, direction="ReadOnly"]  //output
Type pulse-output-channel    : ihcinput1    "IHC input1"    [resourceId=3931665, direction="WriteOnly", pulseLength=1000, trigger="ON"]    //input1
Type pulse-output-channel    : ihcinput2    "IHC input2"    [resourceId=3931921, direction="WriteOnly", pulseLength=1000, trigger="OFF"]    //input2

First of all - Does it require to do both channels manually for each switch (pushbutton)? (Maybe @EjvindHald can answer this) or is it possible to set read/write direction in the item settings?

I really fail to understand how come standard IHC operations like kip and pulse has to be done manually at channel level in the 2.4 binding.. Perhaps this is what I´m misunderstanding here? 

Second - The above looks like it´s an example using two different buttons? (one button for ON and one button for OFF)?
I use single button for the kip (toggle) and dimming (wired dimmers) operations.( In my example from 1.13 binding, you´ll notice I use the same resourceID for both ON and OFF). is it possible to define the same resourceID to two difference channels, like this:

Type pulse-output-channel    : ihcinput1    "IHC input1"    [resourceId=3931665, direction="WriteOnly", pulseLength=1000, trigger="ON"]    //input1
Type pulse-output-channel    : ihcinput2    "IHC input2"    [resourceId=3931665, direction="WriteOnly", pulseLength=1000, trigger="OFF"]    //input2

It doesnt look right, or?

Link til kommentar
Del på andre sites

  • 0

 You don’t need to introduce two channels, because you control only one resource id fron ihc controller.

Type pulse-output-channel    : ihcinput    "IHC input"    [resourceId=3931665, direction="WriteOnly", pulseLength=1000] 

this will generate on/off “pulse” (pulse width 1000ms) to resourceId 3931665 and channel will not follow the resourceId 3931665 state as direction is set to write only mode. So binding will set input ON, wait 1000ms and then set input back OFF. Trigger parameter, nowadays commandToReact is used if you just want to send pulse when channel/item receive certain command (like ON or e.g. for dimmer type INCRESE).

Link til kommentar
Del på andre sites

  • 0

I cant get it to work.. This is my channel:

Type pulse-output-channel   : my_test_trigger "My Test Trigger"         [ resourceId=30298, direction="WriteOnly", pulseLength=300 ]

And this is the error I get:
 

2019-03-07 17:36:00.317 [WARN ] [el.core.internal.ModelRepositoryImpl] - Configuration model 'ihc.things' has errors, therefore ignoring it: [3,25]: mismatched input '' expecting ':'
[3,26]: missing '}' at 'l'
[3,33]: no viable alternative at input 'my_test_trigger'
[3,77]: no viable alternative at input 'resourceId'
[3,88]: no viable alternative at input '30298'
[3,95]: no viable alternative at input 'direction'
[3,118]: no viable alternative at input 'pulseLength'
[3,130]: no viable alternative at input '300'

Just tried with a fresh file .things file
 

ihc:controller:elko [ ip="10.4.28.6:777", username="admin", password="password", timeout=8000, loadProjectFile=true, createChannelsAutomatically=true ] {
    Channels:

       Type pulse-output-channel      : my_test_trigger   "My Test Trigger"   [ resourceId=20058, direction="WriteOnly", pulseLength=1000 ]
}

Gave this error:
 

2019-03-07 17:45:19.161 [INFO ] [el.core.internal.ModelRepositoryImpl] - Refreshing model 'ihc.things'
2019-03-07 17:45:19.184 [ERROR] [.thing.internal.GenericThingProvider] - Channel type ihc:pulse-output-channel could not be resolved.

 

Link til kommentar
Del på andre sites

  • 0
4 minutter siden, Pauli Anttila skrev:

Your thing file have an error somewhere. Could your post whole file content?

Just did (edited). But here it is again:
 

ihc:controller:elko [ ip="10.4.28.6:777", username="admin", password="password", timeout=8000, loadProjectFile=true, createChannelsAutomatically=true ] {
    Channels:

       Type pulse-output-channel      : my_test_trigger   "My Test Trigger"   [ resourceId=20058, direction="WriteOnly", pulseLength=1000 ]
}

Btw I dont see pulse-output-channel type mentioned in the Doc.. Is it new?

Link til kommentar
Del på andre sites

  • 0

Sorry @Kandersen, that's old staff. There is no anymore dedicated pulse output channel as you can define pulse width in every channel type. So,

Type switch-channel      : my_test_trigger   "My Test Trigger"   [ resourceId=20058, direction="WriteOnly", pulseWidth=1000 ]

should work (not tested)...edited pulseLenght -> pulseWidth nowadays

 

Link til kommentar
Del på andre sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Gæst
Svar på dette spørgsmål

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loader...
 Share

×
×
  • Tilføj...

Important Information

Privatlivspolitik og We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.

1200x630bb.png

ok