How to Create a Virtual Device
The following method was documented in the community forum FAQs by Matt J. Franks
Virtual / Simulated Device Types are functional "Things" but are not physical devices you have. Installing them allows you to control them via SmartApp's just as you would a physical smart device.
Creating Virtual Devices - On/Off Switches
There are many reasons you'd have the need for a virtual switch.
- You want one switch to control multiple other switches and/or commands. - You have a multi relay device and want to control the relays individually. (currently ST doesn't support this) - You could use virtual switches the same way you'd use Hello Home Actions, to take care of multiple actions or state changes with the change of your virtual switch state.
To create a Virtual Switch
- Login to the IDE @ https://graph.api.smartthings.com/
- Click "My Devices"
- Click the "New Device" Button
- Enter a "Name" for the device, this can be whatever you want.
- Enter a "Label" for the device, this is optional and can be whatever you want.
-Enter a "Device Network Id" This can be anything you want. I recommend short and sweet but it cannot duplicate other device ID's. Lets say it was a virtual switch for your living room lights, maybe call it LRVD01
- "Zigbee" Id should be left blank
- Select a "Type" from the dropdown, this should be Simulated Switch
- "Version" should be published
- "Location" should be your hub location, probably "Home"
- "Hub" should be your hub name.
- "Group" you won't be able to select when creating, but these are Groups you've created in the Things page in the SmartThings app.
- Click Create
Now you have a Virtual On/Off Switch in Things on your SmartThings App. You can use this Virtual Device just like any physical device.
The process is very similar for other Virtual Devices, instead of Simulated Switch you can choose from many other Simulated Device Types.
For questions and discussion see the community forum thread