Ecolink Door Sensor for Smoke Alarm - need help with DTH Modifications

Hi there,

I have attempted to follow the instructions from this thread to utilize my hardwired smoke and CO combination alarms to link to my Smartthings set up.

It was working and I got it to report when I pressed the test button but I realized that I may have wired the set up opposite from how the DTH was written. When I test the wires coming from my relay without any alarms happening they test as being a complete circuit (Normally Closed) but the DTH was written as if they would be Open when no alarm is ocurring and then a closed circuit when the alarm is going off. Thus, my ST appears as if the smoke alarm is constantly going off. Is there a way to modify the DTH to reverse the definition of Clear and Alarm states?

I want the Alarm state to be for when the Sensor reads as “open” and the Clear stat to be for when the Sensor reads as “closed” - how do I modify @vseven DTH to support this? Trying to learn Groovy and not finding much success so far. I have DTH pulled from his Github GitHub - vseven/SmartThings_VSeven: This is where I store my modifications and/or new Device Types for use with SmartThings

Thank you for your help!
Mike

I really wouldn’t modify the dth if possible, it’s a pretty straight copy from the generic one. Do you happen to be using a relay with a second output that’s normally open and closes on smoke or CO?

Thank you! So I am using the SM120X from Kidde. (https://www.shareddocs.com/hvac/docs/2001/Public/0A/SM120X_UserGuide_EN.pdf) I attached it to the Yellow wire (Normally Closed) and the Common wire (blue). Unfortunately, I apparently didn’t have much foresight and clipped the Orange wire (Normally Open) down to save space in the box. Looking back, that was a dumb move, because I clearly didn’t pay attention and attached the wrong wire.

So I’m looking for a software solution or some guidance on what to tweak, if it’s possible before having to go back in and make those changes. I’m totally willing to do that if you think it’s far easier than editing the DTH to reverse it’s definitions but wanted to see if it was as simple as changing two lines of code first.

Thanks for your help!

So the issue is you want the DTH to actually think the sensor is reporting the opposite, not just change the labels. Based on that, and this is a guess, you could switch line 170 to a 0 and line 172 to a 1. This is just a quick glance at the DTH but I’m guessing that’s where the sensor is telling the DTH if it’s open or closed.

If that doesn’t work you could put them back to what they were and probably swap lines 141 and 143.

1 Like

That worked! The swapping lines 170 and 172 did the trick and now when I have it hooked up to the system it reads as “clear” and when it is not connected or in alarm mode it reads as SMOKE. Thank you for your help, as always! Hope this will help some other silly wiring person in the future. :slight_smile:

2 Likes