From Vertical to Horizontal Buildings through IoT and Software Defined Approaches