Automation Controllers: an introduction

Make your home work for you!

Over the past few years, some of my friends bought gizmos from the smart home aisles of the orange home improvement store and the blue and yellow electronics guys. I’ll clarify first that I do not have anything against that, on the contrary, I believe that the big retailers have done a wonderful job at sparking interest and distributing the building blocks of Home Automation to the general public. Now, back to my friends: In varying degrees, they have bought shiny new products like:

  • Cameras
  • Thermostats
  • Doorbells
  • Voice assistants, like Amazon Echo and Google Home
  • Switches and Dimmers of different flavors
  • Wifi speakers like Sonos or Bose
  • Locks
  • And a number of other things

They usually show me all the icons on their phones, like medals of an accomplished soldier, or like a pilot showing off the cockpit of the airplane they just got certified to fly. They show how with app X they can make a light turn on or the with app Y the entrance locks comes alive, App Z makes the speaker play some music. They are normally in a phase that I like to call the Remote Control Phase. Nothing wrong with it, it is a start. A bit later, I can see how they begin to imagine the possibilities of combining the powers of one system with the other, and suddenly they have bursts of joy like a mad scientist about to expose their monster to a thunderstorm… they are starting to get into the Automation Phase. At some point they realize that their X device does not speak with their Y device. It is not uncommon to find that a choice on one fundamental block starts defining the rest of the ecosystem later on, effectively blocking the possibility of using some new type of technology, because “what I have  does not support the new tech”. Unfortunately, they get into the Automation Blues.

In summary, Remote Control is you decide what to turn on or off, and make it happen by interacting with an app on your smart phone to tell a controller to do it. In contrast, Automation is when a certain state or condition is met, your home takes an action on your behalf. Automation Blues is what you feel when you realize that for whatever reason you cannot move from Remote Control to Automation…

Well, Automation Blues sufferers, there is hope! You can be cured of your maladies by choosing the right, one piece of tech that can open up all possibilities: The controller. Ahhh, reminds me of The One Ring, made to rule them all! Well, we do not have to start a fantastic journey across middle earth to find it, as we’ll reveal most of its secrets today.

Before we get in too deep on the controllers, I’ll talk briefly about two of the three main components of an automation system:

  • Sensors. They detect or measure and event or a physical value that we want to know, in order to determine a state. Sensors are usually physical devices that exist somewhere in your home, for example, a motion sensor in your hallway. They could also be virtual, or located away from home. An example is the weather forecast data, which is usually obtained from a company through the internet.
  • Actuators. They produce a change. This change may be physical, for example, a light switch, or virtual, like sending a message to your phone.

The types of sensors and actuators can be enormous. Specially when they come from different vendors and technologies, it is very common for them to communicate in very different ways. All the rules and languages that sensors follow to talk, are called Protocols. As you are probably thinking, the number of protocols available for sensors and actuators can be very big.

The third component is the Controller. You may remember from an earlier post that the controller is a piece of technology that must be able to handle a minimum of three things:

  • Translate messages between devices. Messages that flow between sensors  and the controller or the controller and the actuators.
  • Keep track of what’s going on. Based on the data coming from the sensors, the controller needs to keep an eye on what’s going on.
  • Manage and Execute Rules. You must be able to define some sort of logic that defines what to do when a state is reached. These have many names, but the most common ones are Rules, Scripts or Recipes. Rules will include some way to indicate when they have to be executed.

Ok. Now that we have talked about all the different components that make the controller, let’s represent it visually:

The image above shows the simplest situation you can get: One sensor, one controller and one actuator. You’ll notice that the arrow from the motion sensor shows that it sends data to the controller, which in turn translates the message into something it can understand and then updates the state of the sensor, and applies one or more rules if necessary. Those rules talk to a translator that converts the control command into something that the actuator can understand, and sends it to the actuator, represented by the bigger arrow going into the actuator. But, wait, there  is a smaller arrow going from the actuator to the controller… what’s going on?

Well, the actuator in this case is a light dimmer. One basic guideline for the design of an automation system is that everything that your system does must have a manual control. The dimmer itself must have a lever or paddle that allows to manually set the dimming level at any time. In order to keep the state of things synchronized with reality, the dimmer must also be able to tell the controller when it has been manually changed. Otherwise the “State of things” in the controller would be useless.

And the Automation Rules?

Automation rules are similar to recipes, but with a twist: They indicate when to prepare the recipe. Conceptually, the automation rule to turn the light on when I walk into the washroom, will look like this:

When 

       the motion detector indicates movement

Then

        Turn the Vanity Light (which is a dimmer) to 100% power

Pretty simple, right? but it has a few problems: The bathroom light will go full blast during the day or night, whether it’s sunny or not. What can we do? well, we need the controller to know more about the environment. How is it done? You are guessing right: more sensors, and more automation logic. Let’s add a light sensor and a time sensor.

now we can make our automation script smarter:

When 

       the motion detector indicates movement

       and the light sensor senses low light

       and the time is between 6:30 PM and 7:00 AM (of the next day)

Then

        Turn the Vanity Light (which is a dimmer) to 100% power

By now, I’m sure that you have already realized that in order to get a more intelligent behavior, it is crucial to add more sensors. If we take a look at us, and how we perceive the world we quickly say: we only have five senses… why do we need more than five types of sensors? Well, although we talk about those five senses, they are extremely powerful in terms of the data they can gather… with our sight, we can judge color, distance, brightness, and (indirectly) temperature. Our touch can sense many types of textures, and also temperature and humidity. Or hearing can give us tone, loudness, distance and direction… Our brain then takes data from one sense and mixes it with data from another sense, which gives it even more meaning. We have a sense called proprioception, that allows us to know the position of our bodies in space, that is really a fusion of our balance, touch and special sensors in our limbs. With our senses we acquire situational awareness. With sensors, our automation controller also acquires situational awareness, and with that we can produce more intelligent automation. It is almost impossible to have more intelligence without additional sensor data.

As a closing point for this post, just want to contrast how the diagram looks like when a system is at the Remote Control Phase:

This is pretty boring, as it does not allow your home to react to almost anything. The time sensor is normally built into the controller, so that’s probably the only thing that you’ll be able to do without real sensors.

These are the basic concepts that you’ll need for our future posts. If you’re interested in Automating your home, but feel that this is not for you, why not give us a call? we’ll gladly make the magic happen without you needing to know the gory details.

See you later!

Leave a Reply

Your email address will not be published. Required fields are marked *