The Technical Foundations of IoT