DSCAlarmSmartThings Guide?

If you’re receiving info about the sensor status, then the baud rate shouldn’t be the problem. Did you double check that you put your specific code into the Arduino file (several places in the version I have)? Maybe those are operations where the alarm is requesting your code but it is not sending the correct numbers.

I Triple checked @obycode :persevere:, the code is everywhere is needed.

BTW I already checked the password on the keypad, and it allow me to activate the alarm.

What can it be happening?

Thanks! I noticed where the problem was. The thing was that i made a bad connection while I was re-routing the RS232 Shield.

Thanks for the help!

p.s: @obycode your instructions have a little mistake or my arduino copy is mislabeled. You wrote "The Rx and Tx pins of the RS232 shield are bent, and wires are run to connect Rx to port 19 (Rx1) of the MEGA, and Tx to port 18 (Tx1). ", but in my case it was Rx to port 18 and Tx to port 19.

It’s my idea or with the code as it is, it’s impossible to disarm the alarm?

Hi, I don’t know which code you are using, but mine (which has been used by many others, and it’s derived from obycode originally) can arm & disarm without issues.

Please check your arduino code again to make sure that you inserted your ‘PIN’ correctly.

Also, as I said earlier, use the serial monitor if needed to do debugging.


i know this one is popular but it sure seems to require a lot of effort compared to the alarmserver python script. what advantages does it have?

Here are the advantages in a nutshell:

  • No need for an external server nor a python script which add as potential source of failure
  • Quick response times from the sensors
  • Communications are done locally vs. Envisalink requires to expose your alarm system to the internet for remote arm/disarm functions- some people are not really comfortable to do so.
  • The code allows you to expose your individual sensors as Motion Detector and Contact Sensor to ST
  • A lot of system status codes are returned to ST in case of any problems with your alarm system (such as power failure, low battery at wireless sensor, keybus fault, etc.)


ah i didnt realize the arduno got rid of the external server. with alarmserver though i can arm/disarm locally without going via the public internet now, and arm/disarm/sensors reply within 2 seconds. however the fact you don’t have to run a raspberry pi makes it pretty nice.

i might have to build one of these just to compare.

Just got the Smartthings v2 and deleted my old account and have started from scratch.
I’ve run into a issue when running the smartapp set-up. After the Wired Zone Setup page is completed, it goes to Wireless Zone Setup page, even though I left the field blank on page one. If I hit done on the top right corner I get a message returned of “An unexpected error has occurred”.

Any help would be appreciated


Don’t forget to create the required Motion & Open/Close sensors in the IDE as specified in the readme:

You can also use the smartapp ArduinoAlarmController to create individual sensors as child Devices. Prior to executing the smartapp, you need to create the Open/Close Sensor and Motion Detector device types within your own namespace by using the SmartThing code template within the IDE.

In order to do so,

a) Go to https://graph.api.smartthings.com/ide/devices
b) Click on new SmartDevice on the right
c) On the new SmartDevice page, click on the “From Template” tab
d) Scroll down to Motion Detector
e) Click “create” at the bottom of the page
f) Click Save and publish on the next page
g) Do the same for Open/Close Sensor
h) Click “create” at the bottom of the page
i) Click save and publish

If you still have issues after doing all the above steps, use live logging in the IDE to get more details on the issue at hand:


Good luck!

Thanks for all your help.
I’ve got everything working within Securityalarmpanel, arming/disarming, away and stay modes and all zones behaving as they should, open closed sensors and motion.

Issue I am have has to do with smartapp ArduinoAlarmController, the motion sensor is behaving as it should, but the open/close sensors just show open, even though in the securityalarmpanel the correct states are shown. What have I missed?

@pbhangle, just try to open and close the contacts…

Sometimes, the states are not in sync.

And, use Live logging to see the logs


The events list for your DSC alarm panel device should look like this when you open/close a contact:

2015-09-25 6:59:39.212 PM EDT
moments ago DEVICE alarmStatus notready Arduino DSC Alarm alarm status is notready
2015-09-25 6:59:39.186 PM EDT
moments ago DEVICE /Open/Closed Sensor response r 6 open Arduino DSC Alarm response is r 6 open
2015-09-25 6:59:39.135 PM EDT
moments ago DEVICE patioDoor PD open Arduino DSC Alarm patio door is PD open
2015-09-25 6:59:37.957 PM EDT
moments ago DEVICE /Open/Closed Sensor response r 6 closed Arduino DSC Alarm response is r 6 closed

Notice the response attribute which indicates the zone and the status (open, closed).

P.S. Make sure that your zones defined in the Arduino Alarm Controller match the ones defined
in SecurityAlarmPanel otherwise, it won’t work.

A simple solution that worked so well, once again thanks for all your help and everything you have done here, now I’m going to fix the dent where I was banging my head

I’m in the thick of implementing this with PC5401. However, I’m getting issues with communications over the RS232. Shown here is the arduino serial terminal.Since PC5401 does not have the command to change speed via software, I commented out the alarmSetBaudRate and set it to 19200 at the beginning. I matched the jumper on PC5401 to 19200. I’m getting som data but is become corrupted.

// setup IT-100 serial port

// setup debug port
// initialize variables
bufferIdx = 0;
readyStatus = true;
armed = ‘0’;
alarm = false;

// Now increase the baud rate


Terminal log:
processing cmd

unsupported message

processing cmd

Zone 001 closed

processing cmd

Zone 002 closed

processing cmd

Zone 003 closed

processing cmd

Zone 004 closed

processing cmd

Zone 005 closed

processing cmd

Zone 006 closed

processing cmd

Zone 007 closed

processing cmd

unsupported message


I’m sorry but I don’t see the issue here, as you seem to receive information about your zones (closed status)…

Not all the commands are supported hence the unsupported messages…


I’m not worried about the unsupported message. It’ just that the messages stop after zone 7 and then nothing else. I’m going to try increasing the BUFFER_SIZE and see if I get more mesages.BTW. can you tell me the deatils of the null-modem cable you use. I made my own and I am using all 7 wires. Maybe it’s a flow control issue?

On my side, If I remember it correctly (I need to physically look at my cable and I’m away from home),I bought a null serial modem with regular 2 male-to-male adapters…

Sorry, but I don’t have any suggestion on your issue at hand.

OK, it seems to be communication now. I think it was the switch on the Smartthings shield. Once I flipped the switch, it started working. I think everything is backing from overflow at the ST shield to the arduino and it stopped working. Now it’s flowing. I can see status. What device-type and smartapps is everyone using. I see like two versions floating around. Should I use obycode?

I’m still using that code and it works great! It is by far the most valuable part of SmartThings in my home, between all of the contact sensors and motion sensors and the arm/disarm functionality!

I believe others have also made some updates, but I haven’t followed them closely. Maybe they will also chime in here.

BTW. I’m using the PC5401. If anyone interested they are cheaper on ebay than IT-100. Only difference is the baud-rate is jumper set. It does not support the baud-rate change via the command.