Create your own SmartThings Routine with Generative AI


Objective

Learn how to create routines in SmartThings app using Generative AI.

Overview

SmartThings Routines is a feature provided by the SmartThings Platform aimed at enhancing user convenience. There are two types of routines in the SmartThings Platform: manually run routines and automatic routines. Manually run routines allow you to adjust the states of desired devices all at once in specific situations. For example, when preparing to watch a movie, instead of turning on each device like the TV or sound bar and adjusting the volume individually, simply activate the routine in your SmartThings app. Automatic routines in SmartThings let you discover and automate your routines. It provides preset routines based on different categories such as home security, energy savings, media experience, or home comfort. For instance, a routine can be set up so that when an alarm goes off in the morning, lights and music turn on automatically.

When combining multiple devices and functions, it may be challenging for beginners to create routines in SmartThings. With Generative AI feature, SmartThings Routines can be used for conveniently creating routines and making complex routines that can work seamlessly in everyday life.

Set up your environment

You will need the following:

  • Android device with the SmartThings application installed
  • SmartThings app with the following devices:
    • SmartThings Hub or SmartThings Station
    • Smart button
    • Smart bulb

Make your own automatic routine

  1. Open the SmartThings app on your mobile device and navigate to the Routines tab.

  1. Tap on the Add (+) button in the upper-right corner of the app.

  1. Under the If section, tap on the Add (+) button.

  1. Select the Device status and choose Smart Button.

  1. Select Pressed as the status of the smart button and select Done.

  1. Under the Then section, tap on the Add(+) button.

  1. Choose Control devices, and then pick Light.

  1. Set the state of the smart bulb to Turn On and select Done.

  1. Save your routine with your desired icon and title.

  1. In the Routines tab, tap on the Discover to access the preset automatic routines.

  1. Navigate to the Healthy sleep category and select the Turn off all the lights routine.

  1. SmartThings automatically creates a routine with your smart devices set to turn off the light. Next, save your routine with your desired icon and title.

Create a routine using Generative AI

  1. Tap on the floating Generative AI icon on the SmartThings app.

  1. Enter a prompt to turn on the smart bulb when the smart button is pressed twice.

  1. Wait for Generative AI to finish creating the sample routine. After it creates the routine, select Details to check if the routine is correct.

  1. Save your newly created routine with your desired icon and title.

You're done!

Congratulations! You've successfully completed the goal of this Code Lab topic. Now, you can manually create routines and even use the Generative AI feature to easily create routines.

To learn more about SmartThings, visit:
developer.samsung.com/smartthings