WyzeCam interesting

Using the Wyzecam camera as a motion sensor in SmartThings

I’ve found a way to get some limited “integration” between a Wyzecam and SmartThings. This allows the Wyzecam to be used as a motion sensor in SmartThings. It does not allow SmartThings to get video from the camera or to control when the camera sends notifications.

It does allow SmartThings to know when the camera detects motion.

This is just a quick overview (without details or pictures) to give people an idea about what is possible.

To do this, I used Tasker and SharpTools (paid apps) running on my Android phone. The phone also has the Wyzecam app (required) installed on it. It also needs the Tasker plugin for SharpTools. It depends on your phone receiving notifications from Wyzecam and being able to send information to SmartThings (via SharpTools). The Wyzecam notifications contain text that looks like this: “Motion sensed on camera01. Check out the alert…”

You would not need to use a phone (or at least not the phone you carry around). Any Android device capable of running Wyzecam, Tasker, and SharpTools will work.

The three apps need to be installed following their normal procedures. SharpTools needs to be installed in SmartThings as well and the appropriate secure link set up.

The steps are:

  1. Add a “Simulated Motion Sensor” to SmartThings using the IDE to represent the motion detected by the camera.
  2. Add this sensor to the ones that SharpTools can share.
  3. In Tasker, on the Android device, create a profile to detect a notification from the Wyzecam and relay it to SmartThings.

These instructions should give you an idea about how to set things up, but they aren’t detailed enough on their own to get you through the complete setup unless you are already familiar with each of the tools. I wanted to get this out there so that people could see what can be done.

In more detail, the steps are:

  1. Add the “Simulated Motion Sensor” to SmartThings
    1a) Log in to the SmartThings IDE online.
    1b) Go to "My Devices."
    1c) Click on the green “+ New Device” button.
    1d) Fill in the following fields:
    “Name” : The name of the motion sensor that will show up in SmartThings. Mine is “Camera01 Motion”.
    “Device Network ID” : Give it a name that won’t conflict with any other names. Mine is “Cam1motion”.
    “Version” : Select “Published”.
    “Type” : Select “Simulated Motion Sensor” from the list.
    “Location” : Select the location associated with the camera.
    “Hub” : Select the SmartThings hub you want it associated with.
    1e) Click the “Create” button to add this device to SmartThings.

You now have a new motion sensor called “Camera01 Motion” (or whatever you name it) that can be used to trigger events (or do anything else) just like a normal hardware motion sensor.

  1. Add the new motion sensor to SharpTools.
    2a) Go to the SharpTools interface within SmartThings: “Automation” > “SmartApps” > “SharpTools”.
    2b) Under “Which motion sensors?”, select the new motion sensor that you added in step 1.
    2c) Click “Save” at the top of the SharpTools interface to save your settings.
    2d) Open the SharpTools app on your Android device and confirm that the new motion sensor is visible.

  2. Create a profile in Tasker to interface between the Wyzecam notifications and SmartThings.
    3a) Open the Tasker app.
    3b) On the “PROFILES” tab, click the “+” button to add a new profile. When the list of profile types appears, select “Event”. The select the “Event Category” “UI” and the “UI Event” “Notification”. You will have selected “Event”, then “UI”, and then “Notification”.
    3c) On the “Event Edit” form that comes up, click the symbol to the right of “Owner Application” and select “Wyze” from the application list.
    3d) Then, in the text field you will type information containing the name of the camera. You need to match the name of the camera as it appears in the Wyze motion notifications. For my camera, it shows up as “camera01”. In the text field, type the name of the camera (exactly how it appears in the notification) surrounded by asterisks ("*"). In my case, the text field contains “camera01” (do not include the quotes “”). This will match any notification containing “camera01”.
    3e) Click the left arrow to go back and add the task to be performed when motion is detected. Select “New Task +” when it pops up.
    3f) You can give it a name or just click the check mark to continue without a name.
    3g) Click the “+” button in the bottom right corner to add the first action. Select “Plugin” > “SharpTools” > “A Thing”. The “Action Edit” form for “A Thing” will appear.
    3h) Click the pencil button next to “Configure”. Choose “Simulated Motion Sensor” under “Select the device type you would like to control:”. Then select the name of your SmartThings motion sensor (mine is “Camera01 Motion”) under “Select the device you would like to control:”. Then, select “active” under “Select the command to send:”. Click “Apply” when you are finished.
    3i) This will return you to the “Action Edit” form. Click the left arrow to return to the “Task Edit” form.
    3j) Add a pause to the task (between motion active and inactive). Click the “+” button to add a new action and choose the following: “Task” > “Wait”. On the “Action Edit” form for “Wait”, change the “Seconds” entry to something non-zero. I use “2” but it may make more sense to be a larger value. This is the delay between when the sensor indicates motion and when it returns to the no-motion state. Then click the left arrow to return to the “Task Edit” form.
    3k) Then add another motion sensor event using the same process as steps 3g and 3h, but choose “inactive” instead of “active”. You selections will be “Simulated Motion Sensor”, motion sensor name (“Camera01 Motion”), and “inactive”.
    Click the left arrow to return to the Task form.
    3l) You can test the task by clicking the “play” arrow in the bottom left corner of the display. This should trigger a motion event in SmartThings. You can verify this using the SmartThings application.
    3m) If everything is working, click the left arrow in the upper left corner to return to the “Profiles” tab. You can control whether the new profile is active or not using the “on/off” switch to the right of the profile.

It looks like there are a lot of instructions, but it’s really very simple to set this up if you already have the applications running.

If you follow this procedure, you will need to add a Tasker profile for each camera and motion sensor that you add. It is possible to create a more intelligent Tasker profile that will look for the camera name in the Wyzecam notification and trigger the appropriate motion sensor in SmartThings. But if you only have a few cameras, this profile is a lot simpler.

13 Likes