Project in progress
Samsung SmartThings Arduino Switch

Samsung SmartThings Arduino Switch © Apache-2.0

With the recent loss of the Samsung SmartShield I have created a replacement solution using the Arduino Wireless Shield and an Xbee S2C.

  • 7,222 views
  • 8 comments
  • 25 respects

Components and supplies

About this project

With the recent discontinuation of the SmartShield attachment for the Arduino. The Samsung SmartThings community has been looking for a replacement for this shield. This project presents the start of a solution to this, using the Arduino wireless shield and a Xbee series 2C to create a simple switch. The switch can control the output of pin 13 as well as the on board LED. This can easily be changed to control whatever pin you like.

To start you must configure the Xbee. Assemble the Arduino, wireless shield and xbee together. This should look like the image below.

Next make sure the switch on the wireless shield is set to USB and import the code Arduino Xbee Setup (link below) to the Arduino IDE, compile and download to Arduino. Switch the wireless shield switch back to micro and reset the Arduino. The code should take about half a minute to run.

https://github.com/CR76/Ardunio_SmartThings/blob/master/Arudino_Xbee_Setup.ino

Next we need to upload the device handler to the SmartThings online IDE. log in and navigate to the device handlers. When there click Create New Device Handler, followed by from code. copy and paste the code from the link below. Once the code is pasted click save and publish for self.

https://github.com/CR76/Mbed-Development-Platform/blob/master/Mbed_Switch.groovy

Finally download the code below into the Arduino IDE. Set the wireless shield to USB and compile and download the code. Next go into the SmartThings app and in the my home tab select add new Thing. Set the wireless shield back to micro and hit the Arduino reset. After a few moments the device should appear in the Arduino app, rename it if want and you are done. See the video below for a view of the switch in action.

SmartThings Arduino switch demo

In the coming weeks I hope to add more functionality and create a library to make the code much more customisable.

Code

Arduino SmartThings Setup
Use this code to configure the Xbee to the correct settings to connect to the SmartThings hub.
Arduino SmartThings Switch
Download this code to create a switch controlled through Samsung SmartThings.
SmartThings Switch Device Handler
Device handler for arduino & SmartThings switch.

Comments

Similar projects you might like

SmartThings RC-Switch 315/433mhz Outlet Bridge

Project in progress by Keith Croshaw

  • 6,509 views
  • 2 comments
  • 7 respects

Paint Your Dimmer Switch on the Wall

Project tutorial by Brian Carbonette

  • 13,387 views
  • 0 comments
  • 40 respects

$20 Zigbee Door Chime

Project tutorial by BuddyC

  • 29,871 views
  • 10 comments
  • 54 respects

How to control your light switch from your smartphone?

Project in progress by Mahmoud Ahmed

  • 24,409 views
  • 3 comments
  • 15 respects

Build a smart "Clapper" with SmartThings and Arduino

Project tutorial by Andrew Mager

  • 3,349 views
  • 3 comments
  • 11 respects

Bluetooth Controlled Light Switch

Project showcase by The Instrumentation Crustaceans

  • 28,419 views
  • 5 comments
  • 28 respects
Add projectSign up / Login