Modified to select one or multiple thermostats