Part II. Connecting to the Physical World

To be real or not.

Must I live simulated?

You can always choose.

Connecting computers to the physical world can be tricky. This is because computers use digital signals (binary data, or 1’s and 0’s), but the physical world operates on ranges of inputs and outputs (analog data), which can represent all kinds of things, such as temperature, wind speed and direction, or degrees of force.

Yet a big part of the IoT is connecting computers to the physical world and the internet to solve problems (as with automatic climate control), right? This connectivity starts at the Edge Tier, where our software (the CDA in this case) interprets this physical world input (sensing) and converts it into the 1’s and 0’s our computing systems understand. It can also take those 1’s and 0’s and convert them into commands that can be sent to turn on, turn off, or adjust another physical system (actuation).

Sensing is the process of interpreting a mechanical input signal by converting it into electricity (and eventually into digital signals—i.e., those 1’s and 0’s I mentioned previously). Actuation is the converse of sensing: the process of converting an electrical signal into a mechanical output.

Depending on the sensor and actuator, how this happens may vary dramatically. For the purposes of this book, you’ll just need to collect the data from a sensor “source” and send a command to an actuator “target.” To keep things simple and maintain our focus ...

Get Programming the Internet of Things now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.