New Binding for Caddx alarm panels [NX584, NX8e, ...]

Lol.

@Jo0p Here you are: binding [Totally untested, I will test later today]

There is a new configuration on the bridge: “Ignore Zone Status Transitions”. This should be set to true/enabled on your case.

:slight_smile: Wow, thanks for this on demand solution

De new switch is available. I think this version has some testing to do:
(also after restarting)

22:08:02.335 [DEBUG] [ddx.internal.handler.ThingHandlerZone] - handleCommand(): Command Received - caddx:zone:afdba8a490:zone30:zone_faulted REFRESH.
22:08:02.555 [DEBUG] [ding.caddx.internal.CaddxCommunicator] - ->: Zone Status Request [Zone: 30]
22:08:02.557 [DEBUG] [ding.caddx.internal.CaddxCommunicator] - ->: 7E 02 24 1D 43 6B
22:08:02.608 [DEBUG] [ding.caddx.internal.CaddxCommunicator] - <-: Zone Status Message [Zone: 30]
22:08:02.609 [DEBUG] [ding.caddx.internal.CaddxCommunicator] - <-: 7E 08 04 1D 01 58 13 F0 00 02 88 15
22:08:02.615 [DEBUG] [ding.caddx.internal.CaddxCommunicator] - ->: Zone Name Request
22:08:02.617 [DEBUG] [ding.caddx.internal.CaddxCommunicator] - ->: 7E 02 23 1D 42 69
22:08:02.619 [INFO ] [hab.event.ThingStatusInfoChangedEvent] - Thing 'caddx:zone:afdba8a490:zone30' changed from OFFLINE to ONLINE
22:08:02.899 [DEBUG] [ding.caddx.internal.CaddxCommunicator] - <-: Zone Name Message
22:08:02.901 [DEBUG] [ding.caddx.internal.CaddxCommunicator] - <-: 7E 12 03 1D 50 49 52 20 6B 61 6E 74 6F 6F 72 20 20 20 20 20 DF A7
22:08:13.113 [DEBUG] [ding.caddx.internal.CaddxCommunicator] - <-: Zone Status Message [Zone: 6]
22:08:13.114 [DEBUG] [ding.caddx.internal.CaddxCommunicator] - <-: 7E 08 84 05 01 01 05 C4 00 00 5D FC
22:08:13.116 [DEBUG] [x.internal.handler.CaddxBridgeHandler] - Zone 6 Transition ignored.
22:08:13.118 [DEBUG] [ding.caddx.internal.CaddxCommunicator] - ->: Positive Acknowledge
22:08:13.119 [DEBUG] [ding.caddx.internal.CaddxCommunicator] - ->: 7E 01 1D 1E 1F
22:08:13.154 [DEBUG] [ding.caddx.internal.CaddxCommunicator] - <-: Zones Snapshot Message
22:08:13.155 [DEBUG] [ding.caddx.internal.CaddxCommunicator] - <-: 7E 0A 85 01 00 10 08 00 00 00 10 00 B8 6F
22:08:13.171 [DEBUG] [ding.caddx.internal.CaddxCommunicator] - ->: Positive Acknowledge
22:08:13.173 [DEBUG] [ding.caddx.internal.CaddxCommunicator] - ->: 7E 01 1D 1E 1F
22:08:16.912 [DEBUG] [ding.caddx.internal.CaddxCommunicator] - <-: Zone Status Message [Zone: 6]
22:08:16.913 [DEBUG] [ding.caddx.internal.CaddxCommunicator] - <-: 7E 08 84 05 01 01 05 C4 00 00 5D FC
22:08:16.915 [DEBUG] [x.internal.handler.CaddxBridgeHandler] - Zone 6 Transition ignored.
22:08:16.916 [DEBUG] [ding.caddx.internal.CaddxCommunicator] - ->: Positive Acknowledge
22:08:16.918 [DEBUG] [ding.caddx.internal.CaddxCommunicator] - ->: 7E 01 1D 1E 1F
22:08:16.953 [DEBUG] [ding.caddx.internal.CaddxCommunicator] - <-: Zones Snapshot Message
22:08:16.955 [DEBUG] [ding.caddx.internal.CaddxCommunicator] - <-: 7E 0A 85 01 00 10 08 00 00 00 00 00 A8 4F
22:08:16.973 [DEBUG] [ding.caddx.internal.CaddxCommunicator] - ->: Positive Acknowledge
22:08:16.975 [DEBUG] [ding.caddx.internal.CaddxCommunicator] - ->: 7E 01 1D 1E 1F

Hi @Jo0p, @Mark_VG,

i did add to the binding a few changes that Mark has asked for. (New channels on the panel thing regarding AC status, corrected thing status initialization).

Johan, had you any chance to test the binding?

Latest Binding (for now)
Latest Documentation (for now)

Thanks Georgios.

Would I have to delete the Panel Thing and rediscover?

I have still not managed to get any more information from Caddx about the Messages etc. What state did you leave that in the binding? (Regarding the syntax to use to send messages to panel?)

Could you confirm what you added?

Hi Georgios,

Some misunderstandig here!

I posted the results of your version directly. I’m sorry, but can’t debug this logfile any further. Do you have any idea what ik can check anymore?

(Just for your information, I tested again with the .jar you provided)

14:27:49.034 [DEBUG] [ding.caddx.internal.CaddxCommunicator] - ->: Zone Status Request [Zone: 30]
14:27:49.036 [DEBUG] [ding.caddx.internal.CaddxCommunicator] - ->: 7E 02 24 1D 43 6B
14:27:49.077 [DEBUG] [ding.caddx.internal.CaddxCommunicator] - <-: Zone Status Message [Zone: 30]
14:27:49.079 [DEBUG] [ding.caddx.internal.CaddxCommunicator] - <-: 7E 08 04 1D 01 58 13 F0 00 02 88 15
14:27:49.198 [INFO ] [hab.event.ThingStatusInfoChangedEvent] - Thing 'caddx:zone:afdba8a490:zone30' changed from OFFLINE to ONLINE
14:27:54.376 [DEBUG] [ding.caddx.internal.CaddxCommunicator] - <-: Zone Status Message [Zone: 6]
14:27:54.377 [DEBUG] [ding.caddx.internal.CaddxCommunicator] - <-: 7E 08 84 05 01 01 05 C4 00 00 5D FC
14:27:54.379 [DEBUG] [x.internal.handler.CaddxBridgeHandler] - Zone 6 Transition ignored.
14:27:54.380 [DEBUG] [ding.caddx.internal.CaddxCommunicator] - ->: Positive Acknowledge
14:27:54.382 [DEBUG] [ding.caddx.internal.CaddxCommunicator] - ->: 7E 01 1D 1E 1F
14:27:54.417 [DEBUG] [ding.caddx.internal.CaddxCommunicator] - <-: Zones Snapshot Message
14:27:54.418 [DEBUG] [ding.caddx.internal.CaddxCommunicator] - <-: 7E 0A 85 01 00 10 08 00 00 00 10 00 B8 6F
14:27:54.436 [DEBUG] [ding.caddx.internal.CaddxCommunicator] - ->: Positive Acknowledge
14:27:54.438 [DEBUG] [ding.caddx.internal.CaddxCommunicator] - ->: 7E 01 1D 1E 1F
14:27:56.527 [DEBUG] [ding.caddx.internal.CaddxCommunicator] - <-: Zone Status Message [Zone: 6]
14:27:56.528 [DEBUG] [ding.caddx.internal.CaddxCommunicator] - <-: 7E 08 84 05 01 01 05 C4 00 00 5D FC
14:27:56.530 [DEBUG] [x.internal.handler.CaddxBridgeHandler] - Zone 6 Transition ignored.
14:27:56.531 [DEBUG] [ding.caddx.internal.CaddxCommunicator] - ->: Positive Acknowledge
14:27:56.533 [DEBUG] [ding.caddx.internal.CaddxCommunicator] - ->: 7E 01 1D 1E 1F
14:27:56.568 [DEBUG] [ding.caddx.internal.CaddxCommunicator] - <-: Zones Snapshot Message
14:27:56.569 [DEBUG] [ding.caddx.internal.CaddxCommunicator] - <-: 7E 0A 85 01 00 10 08 00 00 00 00 00 A8 4F
14:27:56.588 [DEBUG] [ding.caddx.internal.CaddxCommunicator] - ->: Positive Acknowledge
14:27:56.590 [DEBUG] [ding.caddx.internal.CaddxCommunicator] - ->: 7E 01 1D 1E 1F

Hi Mark,

Yes

I did not incorporate the changes for displaying information on the keypad.
This part is like on the official binding.

Changes (On top of the official binding):

  • Support for ignoring Zone Status Transitions
  • Things should go ONLINE when they should.
  • Addition of the following three channels.
	<channel id="panel_ac_fail" typeId="panel_flag">
		<label>AC fail</label>
		<description>AC fail</description>
	</channel>
	<channel id="panel_ac_power_on" typeId="panel_flag">
		<label>AC Power On</label>
		<description>AC Power On</description>
	</channel>
	<channel id="panel_low_battery_memory" typeId="panel_flag">
		<label>Low Battery Memory</label>
		<description>Low Battery Memory</description>
	</channel>

Hi @Jo0p,

from the log, everything looks ok.
Did you make any addition on any of the openhab pages to display information from configured binding items?
If say, you added items for your motion sensors, you should see them switch on and off when you walk through the rooms.

mmm… This issue really drives me crazy, but it’s all about the odds :smiley:

Yes! Now it’s working! In the new version, with the fresh install, I did not created the ‘panel’ item. That was a indispensable part :slight_smile:
Thanks for your support!!

Johan.

Hi Georgios

Thanks so much.

Tested the AC Fail and AC Power ON. Both work perfectly. The is obviously a delay before AC Fail triggers, which coincides with when the panel sends a message to Alarm Company.

I also restarted OH on my Windows Machine and all the Caddx things came online without having to restart the Caddx Thing - which is GREAT!

I will try and schedule a test of the Low Battery Memory - though that is a lot more difficult as it could take a LONG time for my alarm batteries to deplete enough to trigger - will see what I can do though.

Thanks so much

Hi guys, has anyone setup the Caddx binding on openhab 3? could you kindle share a couple of the rules setup so I can mirror if you did?

Hi Georgios

I just upgraded to 3.1.0 STABLE and when I use the last provided caddx binding I get the following error:

08:53:32.338 [INFO ] [org.apache.felix.fileinstall         ] - Installing bundle org.openhab.binding.caddx / 3.1.0.202106061119
08:53:32.416 [WARN ] [org.apache.felix.fileinstall         ] - Error while starting bundle: file:/C:/openHAB/addons/org.openhab.binding.caddx-3.1.0-SNAPSHOT.jar
org.osgi.framework.BundleException: Could not resolve module: org.openhab.binding.caddx [270]
  Unresolved requirement: Import-Package: org.openhab.core.io.transport.serial

        at org.eclipse.osgi.container.Module.start(Module.java:463) ~[org.eclipse.osgi-3.16.200.jar:?]
        at org.eclipse.osgi.internal.framework.EquinoxBundle.start(EquinoxBundle.java:440) ~[org.eclipse.osgi-3.16.200.jar:?]
        at org.apache.felix.fileinstall.internal.DirectoryWatcher.startBundle(DirectoryWatcher.java:1260) [bundleFile:3.6.8]
        at org.apache.felix.fileinstall.internal.DirectoryWatcher.startBundles(DirectoryWatcher.java:1233) [bundleFile:3.6.8]
        at org.apache.felix.fileinstall.internal.DirectoryWatcher.doProcess(DirectoryWatcher.java:520) [bundleFile:3.6.8]
        at org.apache.felix.fileinstall.internal.DirectoryWatcher.process(DirectoryWatcher.java:365) [bundleFile:3.6.8]
        at org.apache.felix.fileinstall.internal.DirectoryWatcher.run(DirectoryWatcher.java:316) [bundleFile:3.6.8]

Do you have any suggestions? I presume I need to manually install the org.openhab.core.io.transport.serial package?

EDIT: Solved by manually installing -

feature:install openhab-transport-serial

Hi @Mark_VG,

Try the following:

Hi.

Solution was:
feature:install openhab-transport-serial

FYI.
I have opened a PR a week ago.
Once it gets reviewed and merged it will be part of the official install.

1 Like

Hi Georgios

Been a while.

Just tried to upgrade to the latest 3.4 SNAPSHOT and go the following error:

15:00:56.133 [ERROR] [rnal.common.AbstractInvocationHandler] - An error occurred while calling method 'ThingHandler.initialize()' on 'org.openhab.binding.caddx.internal.handler.CaddxBridgeHandler@162b5828': For input string: "15.0"
java.lang.NumberFormatException: For input string: "15.0"
        at java.lang.NumberFormatException.forInputString(NumberFormatException.java:65) ~[?:?]
        at java.lang.Integer.parseInt(Integer.java:652) ~[?:?]
        at java.lang.Integer.valueOf(Integer.java:957) ~[?:?]
        at java.lang.Integer.decode(Integer.java:1436) ~[?:?]
        at org.openhab.binding.caddx.internal.CaddxMessage.<init>(CaddxMessage.java:111) ~[?:?]
        at org.openhab.binding.caddx.internal.handler.CaddxBridgeHandler.sendCommand(CaddxBridgeHandler.java:258) ~[?:?]
        at org.openhab.binding.caddx.internal.handler.CaddxBridgeHandler.lambda$0(CaddxBridgeHandler.java:165) ~[?:?]
        at java.util.concurrent.ConcurrentHashMap.forEach(ConcurrentHashMap.java:1603) ~[?:?]
        at org.openhab.binding.caddx.internal.handler.CaddxBridgeHandler.initialize(CaddxBridgeHandler.java:165) ~[?:?]
        at jdk.internal.reflect.GeneratedMethodAccessor112.invoke(Unknown Source) ~[?:?]
        at jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:?]
        at java.lang.reflect.Method.invoke(Method.java:566) ~[?:?]
        at org.openhab.core.internal.common.AbstractInvocationHandler.invokeDirect(AbstractInvocationHandler.java:154) [bundleFile:?]
        at org.openhab.core.internal.common.Invocation.call(Invocation.java:52) [bundleFile:?]
        at java.util.concurrent.FutureTask.run(FutureTask.java:264) [?:?]
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128) [?:?]
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628) [?:?]
        at java.lang.Thread.run(Thread.java:829) [?:?]
15:00:56.483 [ERROR] [.core.thing.internal.ThingManagerImpl] - Exception occurred while initializing handler of thing 'caddx:bridge:e59e4935': For input string: "15.0"
java.lang.NumberFormatException: For input string: "15.0"
        at java.lang.NumberFormatException.forInputString(NumberFormatException.java:65) ~[?:?]
        at java.lang.Integer.parseInt(Integer.java:652) ~[?:?]
        at java.lang.Integer.valueOf(Integer.java:957) ~[?:?]
        at java.lang.Integer.decode(Integer.java:1436) ~[?:?]
        at org.openhab.binding.caddx.internal.CaddxMessage.<init>(CaddxMessage.java:111) ~[?:?]
        at org.openhab.binding.caddx.internal.handler.CaddxBridgeHandler.sendCommand(CaddxBridgeHandler.java:258) ~[?:?]
        at org.openhab.binding.caddx.internal.handler.CaddxBridgeHandler.lambda$0(CaddxBridgeHandler.java:165) ~[?:?]
        at java.util.concurrent.ConcurrentHashMap.forEach(ConcurrentHashMap.java:1603) ~[?:?]
        at org.openhab.binding.caddx.internal.handler.CaddxBridgeHandler.initialize(CaddxBridgeHandler.java:165) ~[?:?]
        at jdk.internal.reflect.GeneratedMethodAccessor112.invoke(Unknown Source) ~[?:?]
        at jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:?]
        at java.lang.reflect.Method.invoke(Method.java:566) ~[?:?]
        at org.openhab.core.internal.common.AbstractInvocationHandler.invokeDirect(AbstractInvocationHandler.java:154) [bundleFile:?]
        at org.openhab.core.internal.common.Invocation.call(Invocation.java:52) [bundleFile:?]
        at java.util.concurrent.FutureTask.run(FutureTask.java:264) [?:?]
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128) [?:?]
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628) [?:?]
        at java.lang.Thread.run(Thread.java:829) [?:?]

Any idea what the issue might be. (I have posted a topic and included this error as well as the upgrade also gave me a TRANSFORM error)
Thanks
Mark

EDIT: This went away aftre restarting the Bridge THING

@jossuar Hi Georgios

Hope you are still active on the community and can assist?

I have just upgraded my openHAB to 3.3.0 (STable).

It appears that the issue we had a while back with THINGS not coming online after an openHAB restart has come back.

The easiest way to get the THINGS back online (same as last time), is to restart the Bridge THING.

Is there any chnace you could have a look? I can send you TRACE logs etc if you would like?

Thanks
Mark

Hello, I’m all new to this. For 2 days I’m trying to get the Caddx bridge online. I have a NX-584. The best I get is this in the logings:


Seems there never comes an answer. Played with the NX-486 settings… I have two different RS232 adapters… I just don’t get the Bridge online:

Thanks in advance for the tips, Wim

Are you able to communicate with the panel using DL900?

Are you sure that the protocol is binary and not ascii?

What does openhab.log say when trying to initialize the bridge thing?

No, I do not get a connection. I get this error:
Schermafbeelding 2022-08-15 082948
When I change (in DL900) the protocol to ASCII (on the NX584 the protocol is Binary), I get the same error, but then 0…1047 and 0…83.
I do get communication with PYNX584…:


I have no idee why I cannot get a connection with dl900

OK, I’m one step further. I got connection with dl900 as the Download Access Code was changed by the installer.
But I get another problem now:


When I want to change something on the Automation Modul (72 = NX584) I get the above error…