Handling an overloaded Circuit Breaker with Home Automation - Part II
The last entry was written before actually trying much in real life, very much just to work through the ideas I had in my head.
Now that I have tried a number of things, I can provide an update on what is possible, and my thoughts.
Firstly, I have an Amazon "smart speaker" device, which I bought solely to act as a doorbell extension. I linked my SwitchBot account to my Amazon account, and the devices all showed up on the "smart home" screen of the Amazon device. The "scenes" did not show up though, and those were all I wanted to use.
Through looking around, I found that you could use add a switchbot "skill" to allow the use of scenes from the smart speaker. There were numerous problems with this, not the lease of which is that if I have a device named "air conditioner" and a scene named "Air conditioner on, other off", it will always prefer the device to the scene. I want to enforce using the scenes and not the devices, so if anything, I explicitly want to block the devices, not prefer them! This issue can be solvd by renaming the devices to "AC" instead of "Air Conditioner", etc. Another issue is that even though these work as voice commands, they still don't show up on the smart home screen.
I don't ever use the smart speaker for anything other than a doorbell, so ideally it would show the scenes on the "smart home" screen, and I could be able to add them as icons or widgets to the main screen for easy access - but it seems there is no way to do this. An Android tablet would have worked a lot better.
Amazon Alexa also has something similar to scenes, but slightly more sophisticated. You can add a delay between steps, and you can run scenes as steps in the "action". What this means is that I could make an action called "Coffee maker", which runs the "coffee maker" scene, turning off the AC and everything else, waits 30 minutes, and then runs the "Air Conditioner" scene. This is great because it means not only am I making sure that only one high power device is in use at any single time, I am also returning things back to the "default" state after a set maximum amount of time.
Well, it sounds great. The actions also have the issue that the conflict with the scenes! So if i have an action named "Aid Conditioner on", it will interpret it as the scene "air conditioner" and the command "on" - and run it as the basic scene without the additional steps. Scenes can't be turned off, but even so "Air conditioner off" will be interpreted as the scene "air conditioner", followed by the command "off", which is not allowed, so I will get an error message - even though there was an action called "air conditioner off".
Worse yet, I am convinced that Alexa is a bit retarded. I know it's not nice to make fun of the mentally ill, but it is seriously annoying in a smart speaker. For example, to avoid conflicts, I made cute phrases to link to the actions. For example, I made a phrase "I want to wash the dishes" to urn the dish washer action, which will run the dish washer scene, wait 45 mins, and then run the basement AC scene. Great, right? but the results can be random.
Here is an example:
Me: Alexa, I want to wash the dishes
Alexa: In order to wash the dishes, you should first get some soap...
So it did understand what I said, but decided to ignore the registered action and give me some BS answer from the internet instead. In fact, I would like to disable that feature entirely. I am never, ever going to ask Alexa to look up random stuff on the internet. I have a computer for that. A one sentence summary is rarely useful, I don't want to listen to an entire wikipedia page.
So Alexa has the ability to run multiple scenes, with timers, but is so annoying to use for me that it is out of the question.
I wish that Switchbot scenes had the same generic option for a delay step, but alas they do not currently have such an option. Some devices to have a delayed execution option, though. Alexa's delays are presumably implemented by a timer on the alexa device, or somewhere in "the cloud" (i.e. an Amazon server). The delays that switchbot does support right now appear to be supported in the hardware of the devices themselves.
For example, the Plug Mini has a "delayed on" and "delayed off" feature.
So for example, I can modify the dishwasher scene to look like the following
1. Turn off AC (via IR)
2. Turn off Coffee Maker (plug)
3. Turn off microwave
4. Turn on Dishwasher (plug mini)
5. Turn off Dishwasher (plug mini) - 45 mins from now
The scene will run and complete immediately, but I believe the 45 mins timer is stored in the plug mini itself. This is great, because I can ensure that the dishwasher will be turned off within 45 minutes.
The problem is that I really want to add a step like this to the end:
6. Turn on AC (via IR) - 46 mins from now
Since the IR commands don't support this delay, and there is no generic delay option, this seems impossible.
Actually, there is a way, but it comes with come caveats.
The plug mini (but not the older plug) can be used as a scene trigger.
This means you can set it up such that turning the pliug on or off will activate a scene.
I wondered if this automatic scene activation would work even if the on/off action was activated by another scene (since this could allow the creation of infinate loops) - surprisingly, it will!
So I can use steps 1-5 from the manual scene above, and then make an automatic scene that goes something like this:
WHEN Mini Plug "Dishwasher" is turned OFF
THEN Turn On Basement AC (IR)
This works!
The problem is that, whenever the dishwasher is turned off, this will execute - so for example turning off the dishwasher is part of the coffee machine script, and will thus turn the AC on. (and the coffee machine script also says to turn the AC off - so which one would win?, and is it even consistant?)
Still, I have discovered two useful things:
1. I can set a device to turn on immediately, and then turn itself off later on. This is useful to ensure a maximum period of activity.
2. I can set the results of one plug to execute a scene, which could (for example) turn other plugs off when i tis turned on).
Ideally, everyone is executing the scenes and never touching the raw devices - but this would make it possible for people to manually activate devices in the app or using the button on the smart plug - and automatically turn off everything else. In fact, using the buttons on the smart plugs is a good way of turning things on and off without having to use the app! The problem is that the power switch trigger only works for the newer Smart Plug Mini.
3. It is possible wih the Plug Mini to not only trigger based on the on/off state, but also the wattage being drawn. This means you can set a backup rule to say "If the dish washer is drawing over 100 watts, then turn off the AC and coffee maker". You can also set it to run a scene if the device attached to a Plug Mini is drawing less than a certain amount. This seems less useful, as many devies will draw varying amounts of power. This again only works with the newer Plug Mini.
What this means in practice, is that the Mini should be attached to things where you want to track the usage, or when they are turned on or not, and the older plugs should be used for things you simply want to control. So for example, I might use a Plug Mini for the coffee maker, but the older Plug for some lights or the water cooler.
I decided to stick with scenes as my main way or doing things for two reasons:
1. I have a number of the older Plug models that can't be used as triggers
2. The smart plugs for some devices will be hidden in inconvenient places
I did discover that the "remote button" can execute scenes, and the two buttons on this small device can be assigned to separate scenes. In this case, I could assign "coffee machine" to one button and "Basement AC" to the other button on the device I attach to the coffee machine.
Likewise, I can assign "Dishwasher" and "Basement AC" to the two buttons on the device I attach to the dishwasher.
Doing it this way does cost more, as now I need not only a smart plug, but also a button for each device, but it means that it's easy to use each device without needing to fumble with an app or fight with Alexa.
I want a cup of coffee? I press the button. I'm done with making coffee? I press the other side of the button. The other devices are controlled as appropriate.
The only real hole this leaves is that we still have the issue that there is no delay feature for the AC when operating via IR control. This is not ideal, but basically okay, since we can trigger that based on temperature.
If I set the trigger temperature too low (in the summer), then I risk cutting my dishwasher cycle short, or having my coffee machine cut off in the middle of a cup!
If I set the trigger too high, then I let the room get hotter than I need to. Since this is meant to be an emergency measure to turn the AC back on in case someone forget - I think a few degrees above where I want it allows some buffer.
Another interesting option is the door sensor. This is probably more appropriate for things like lights, but can be used to turn on devices when a room is entered, and off when the room is exited, etc.
For example, I placed a door sensor on the basement door.
* When entering the room, it turns the ceiling light on (any time of day).
* When leaving the room, it turns the light off if the time is between 8pm and 8am.
What this means is that I want the light to be off at night, unless I am in the room.
Comments
Post a Comment