When you say in “ArduinoAlarmController,” you are referring to the setup in the SmartApp? Vs the Code.
I did use the same order and used the names as defined in the attribute definition from the SecurityAlarmPanel code. Should I mirror a different name from SecurityAlarmPanel? ie a display name.
Appreciate any guidance you can provide. I know this is difficult to troubleshoot remotely.
Interesting from Live Logging when I opened the front door and closed it. from the Arduino Alarm Controller. Seems it is trying to match up some sort of word Door. I didn’t call anything (that I am aware of “door”
d7dda88a-ff3b-40ff-93e8-e3fc7d7dc9ad 5:46:16 PM: error groovy.lang.GroovyRuntimeException: Ambiguous method overloading for method java.lang.Long#minus.
Cannot resolve which method to invoke for [null] due to overlapping prototypes between:
[class java.lang.Character]
[class java.lang.Number] @ line 283
d7dda88a-ff3b-40ff-93e8-e3fc7d7dc9ad 5:45:05 PM: debug couldn’t find device for zone Door
d7dda88a-ff3b-40ff-93e8-e3fc7d7dc9ad 5:45:05 PM: debug deviceName = zoneDoor
d7dda88a-ff3b-40ff-93e8-e3fc7d7dc9ad 5:45:05 PM: debug Front zone Door status=Closed
d7dda88a-ff3b-40ff-93e8-e3fc7d7dc9ad 5:45:05 PM: debug zonestatusChanged response Front Door Closed Open/Closed Sensor
d7dda88a-ff3b-40ff-93e8-e3fc7d7dc9ad 5:45:03 PM: debug zonestatusChanged response alarmStatus ready null
Thank you. Looks like I got over-zealous on naming/updating the code. That did the trick. I did have to open each contact sensor for it to reset and update (as you suggested earlier). All 8 zones are reporting for duty.
Thank you so much for your work on this and helping me!!!
Hopefully my perils can be avoided by others.
My updated code for the first zone. Many thanks.
// Process zone update
}
else if ( msg.substring(0, 2) == “ZN” ) {
if ( msg.substring(3, 9) == “609001” ){
stateToDisplay = "Open"
result = createEvent(name: “FrontDoor”, value: stateToDisplay)
sendEvent(name: “response”, value: “r 1 open”, type: “Open/Closed Sensor”)
}
else if ( msg.substring(3, 9) == “610001” ){
stateToDisplay = "Closed"
result = createEvent(name: “FrontDoor”, value: stateToDisplay)
sendEvent(name: “response”, value: “r 1 closed”, type: “Open/Closed Sensor”)
}
So this has been working since Nov '15. Recently (maybe a month or so ago??? It stopped registering closed. If I open a door, it says xxxx contact is open. When I close the door, it repeats saying xxxx contact is open. I had not made any changes to Smartthings or the arduino. Was there some sort of upgrade with Smartthings that requires a code change? I went it and republished and re flashed the Arduino with no luck.
When using the serial monitor, it shows Closed when the door is closed… so I think that part is working. For some reason the connection to Smartthings is not equating to that closed status anymore. Any suggestions? Many Thanks.
I figured it out. Check out this code for the Device Type
// Process zone update
}
else if ( msg.substring(0, 2) == “ZN” ) {
if ( msg.substring(3, 9) == “609001” ){
stateToDisplay = "Open"
result = createEvent(name: “FrontDoor”, value: stateToDisplay)
sendEvent(name: “response”, value: “r 1 open”, type: “Open/Closed Sensor”)
}
else if ( msg.substring(3, 9) == “610001” ){
stateToDisplay = "Closed"
result = createEvent(name: “FrontDoor”, value: stateToDisplay)
sendEvent(name: “response”, value: “r 1 open”, type: “Open/Closed Sensor”)
Do you see the issue? Closed - value r 1 open
What!? I have not been in here changing the code. However, EVERY one of the 8 sensors has open on the closed event! How crazy is that? I changed it back to closed and it is working now. This is a little disturbing that the code was changed - and I didn’t do it.
Here is the correct code.
// Process zone update
}
else if ( msg.substring(0, 2) == “ZN” ) {
if ( msg.substring(3, 9) == “609001” ){
stateToDisplay = "Open"
result = createEvent(name: “FrontDoor”, value: stateToDisplay)
sendEvent(name: “response”, value: “r 1 open”, type: “Open/Closed Sensor”)
}
else if ( msg.substring(3, 9) == “610001” ){
stateToDisplay = "Closed"
result = createEvent(name: “FrontDoor”, value: stateToDisplay)
sendEvent(name: “response”, value: “r 1 closed”, type: “Open/Closed Sensor”)
Since SmartThings have decided to retire SmartThing Shield to Arduino. I was looking for a solution using Raspberry Pi with my DSC IT-100 interface. I didn’t found any solution available to use it so I decided to create my own. Here is the link in case you are looking for something similar: https://github.com/Welasco/NodeAlarm.
I used this amazing project as reference and replace the Arduino with a Raspberry Pi 3 using USB to Serial cable and NodeJS with Rest API.
I’ve used this for many years after getting it working. But since I’ve added more zones via wireless. What do I need to change to get those zones into the smartthings as sensors.