I have successfully installed 5 Heiman ZigBee HS1SA-E smoke detectors thanks to @Mariano_Colmenarejo Edge driver. I believe from previous post back in 2021 when IDE was still available that you cannot link devices in Smartthings. I am not sure if this has changed in the intervening years?
However I would like to make an announcement on Echo devices when a smoke detector activates. I’ve looked at the routines tab for the device and one option is to “Notify Someone” however “Play a Message on a Speaker” is greyed out. Is that because I don’t have the correct Alexa voice integration enabled?
Alternatively can I set up a virtual switch which would then trigger an announcement. I have installed @TAustin 's Virtual Device driver and created 5 virtual AlexaSwitches one for each detector and added the virtual AlexaSwitch under the “Then” section of the device routine. However I am now stuck on where to go next to create an announcement. Is there further configuration in Smartthings App or should I do this in the Alexa app?
Many thanks
In Alexa try something like:
IF (When) virtual AlexaSwitch ON
THEN (Alexa Will) Say “Smoke Detected” via Living Room Echo Dot
You do it in an Alexa routine (not a SmartThings routine) .
Details in the community FAQ:
FAQ: Can I trigger an Echo Action without Speaking to It?
Here is an example of using an Alexa routine to speak a custom announcement from two echo devices. We could also have chosen all of our echo devices or any individual ones.
These screenshots are from the Alexa app where you create Alexa routines.
.
Thank you @JKnight and @JDRoberts I have followed your instructions but its not working. When you test the routine in Smartthings it is OK and the routine set up in Alexa app runs and makes an announcement but the two dont work together
Here is my Routine for a smoke detector
and a screenshot of the IF action
Here is my Alexa routine
and the condition eg “when contact closed”
I’ve activated the detector with some smoke and get a warning via the Smartthings app but nothing from Alexa.
Any suggestions what I have missed or done wrong?
Many thanks for your help
For the screenshot above in Alexa, I believe you may have the virtual AlexaSwitch set wrong. You want it to trigger the announcement whenever the switch is is on or opens, not off or closes. In your SmartThings routine you have the virtual switch set to turn on or open when smoke is detected, so it needs to match in Alexa.
Thanks @JKnight ill try that.
OK so I’ve made progress. I am not sure if the Virtual switch just toggles between states on activations. Changing to “opens” in Alexa app did not work. I therefore went back to the virtual switch and there is a third option Turn On or Off
This sort of works but is inconsistent. I am currently using the test button on the detector and the first press gives a message “Smoke is back to Normal” or similar and a second press “Smoke Detected”. Sometimes this triggers alexa but other times it does not.
I am wondering if I should use any of the advanced settings “Stay at this status for how long” as below
Or should there be no time set at all
When he has a moment perhaps @TAustin can shed some light on the variables of his virtual switch?
Did you check if the vEdge Alexa Switch 4 is ‘ON’ in smartthings?
I previously had some consistency issues with a few of my virtual switches working with Alexa and switched them over to @TAustin’s Alexa Multi-Trigger instead and haven’t had issues since. Perhaps it may resolve your issue as well:
Thanks @Subramanian_Swaminat Excellent suggestion and something I should have thought of when troubleshooting . I think this is the issue.
When pressing the test button to simulate a fire, the AlexaSwitch changes state but it toggles rather than momentary. This is ok in the ST routine as there is an option for “turn On or Off” however as @JKnight pointed out the Alexa routine has to match this, but there is only an On or Off option in Alexa. This means the alarm will trigger every third press as the switch is in the wrong state until the next press. There doesn’t appear to be an “And” “Or” logic option in Alexa conditions.
Thanks @JKnight I did read Tod’s article about a multitrigger device when trying to find out more about his Virtual AlexaSwitch but thought I would first persevere with the latter. I don’t know how the Multi Trigger works and if this would overcome my particular problem in that I think I need a “momentary switch”? Will Multitrigger provide this functionality?
As an aside how do you use it. Do I need to remove all the existing (5 ) Alexa Switches, then subscribe to the channel and install Multitrigger or can they coexist on the hub without interfering with each other?
OK I think I have found the solution. There is an Auto Revert function in the Alexa Switch I had not seen before and found in the thread here This changes the state of the switch after a set delay which effectively make it a momentary switch.
Ill try this and report back
You could try this also,
- Create a virtual Alexa switch ‘VS - AlexaSwitch’ and a routine to turn this on when the smoke is detected
- In the alexa routine, you can check if the VS - AlexaSwitch is on, make it say the sentence you want and then turn off the VS - AlexaSwitch
The Multi-Trigger device can coexist, but I think it is only necessary if you are having trouble with the virtual AlexaSwitch. As I mentioned, I had a few (I think 2 of 20 virtual switches) virtual switches that just wouldn’t play nice with Alexa, and the Multi-Trigger resolved the issues with those 2. If the virtual AlexaSwitch is working, stick with that.
Another way I use to simulate a momentary switch in a SmartThings routine is:
IF virtual switch is on for 2 seconds
THEN turn virtual switch off
This likely will require you to add another SmartThings routine, but if all goes well, this momentary on and off should be reflected in Alexa, with it triggering the announcement whenever the switch is on momentarily.
Would agree with you there, but I should say that I changed all my Alexa switches (40+) to Multi Trigger last year after Alexa caused problems with the older virtual switch and they’ve run perfectly ever since. Much more difficult to keep track of though…need to keep some form of inventory.
OK I am tearing my hair out trying to get this to work. I am obviously doing something wrong or missing a step.
I set it up initially using AlexaSwitch and that did sort of work but only intermittently. Initially I thought it was triggering every other time as the switch toggles by default so was in a different state next time the smoke detector operated. However I am not sure that’s the problem.
I tried the Auto-Revert after 2 seconds option in settings so that the switch reverted to off, but that hasn’t made a difference to reliability.
I therefore installed Multi trigger. Named the first available trigger Smoke Switch and set up the routine. Alexa immediately found and added Smoke Switch and I was able to use this in the Alexa routine. However this does not trigger the Alexa routine at all and you can’t see if the multitrigger is working, unlike the alexa Switch that changes state in the app. Perhaps I am using it incorrectly?
I thought I would try another detector and echo device in case it was a faulty detector or setting on the speaker, so set up the routine again but now I can only select Multi Trigger and not the individual trigger I named Smoke Switch.
I thought I might have had duplicate Multi Triggers, as depending on how I access it sometimes I can see Smoke Switch for trigger 2 but other times an unnamed trigger 2. So deleted Multi-Trigger and scanned for new devices again to reinstall. However now the app can no longer find Muti Trigger!!!
Do I have to uninstall it from the hub and then reinstall it for the app to find it again?
Also is there a tutorial other than Tods description on how to set up and use Multi trigger. It seems to have fixed a lot of users Alexa routines but i’ve not got out of the starting gate yet. Perhaps it is a limitation of the Smoke Detector Edge driver created by @Mariano_Colmenarejo??
If I understand correctly, using Alexa Multi-Trigger, you created the virtual Smoke Switch… something wasn’t working right so you subsequently deleted the virtual Smoke Switch and the Alexa Multi-Trigger in SmartThings.
After you rediscovered the Alexa Multi-Trigger, you should have also recreated the virtual Smoke Switch via Create New Device at the top of the Alexa Multi-Trigger controls page.
Once you have done that, ask Alexa to discover new devices. If Alexa sucessfully finds the Smoke Switch, try toggling it in SmartThings and see if it correctly matches the toggle state in Alexa.
If that all works, add it to your routine(s). If something isn’t working after adding it to your routine(s), it is likely an issue with the routine(s) themselves, and not the virtual Smoke Switch device.
Keep us posted so we can help troubleshoot any routine(s) issues.
Hi @JKnight Firstly thank you again for your continued help on this. You are partly correct with your response. I deleted Alexa Multitrigger but when I scanned again for new devices, the app would not find it. I tried to uninstall the Multi Trigger app from the hub but it would not uninstall as it complained it was in use but have now succeeded. Even though the parent Multitrigger had disappeared the Smoke Switch I had created was still visible as attached to the hub. Once I deleted the Smoke Switch trigger I could uninstall Multitrigger within Tod’s Beta driver channel.
However SUCCESS!!! I have now got it working. I re-read all of the posts written by Tod and he recommends the use of a Contact Device for triggering Alexa. In the AlexSwitch settings there is an option to create a seperate “Contact Device”. Using this in the routine It now works successfully every time. there is a slight lag but suspec this is because Alexa is cloud based and not local. When I have time I will write up the whole procedure and post on the Wiki so that anyone who wants to follow the steps you go through has access to the full procedure.
Thank you again
Glad you got it sorted!
Amazon only allows specific types of devices to be used as triggers in Alexa routines, primarily motion sensors, contact sensors, and locks. This is true whether the devices are physical or virtual.
There are some specific models of other device classes that can be used: some doorbells, Flic buttons, some Ring security states, some switches and buttons when connected via a Hue bridge, and some Matter plugs and switches when connected to an Echo device via Matter.
But most switches do not work as triggers.
From 2018 through 2022, you could use a virtual device that had both the switch capability and the sensor capability, but in 2023 that stopped working reliably. So that’s when Todd added additional options to VEdge Creator. One of these options gave you two synchronized virtual devices: one switch, and one sensor, instead of having one virtual device for both capabilities. Then you could use the sensor to trigger Alexa routines while being able to change its state by turning the associated switch on and off. So that is the current recommended option.