This paper proposes a distributionally robust optimization approach (DROA) based on a disjoint layered ambiguity set for scheduling the energy consumption of the heating, ventilation and air conditioning (HVAC) system. The uncertainties of the predicted outdoor temperature error and indoor temperature variations that are caused by human activities are taken into account in the energy consumption scheduling of the HVAC based on historical data. The maximum uncertainty set of outdoor temperature is divided into disjoint subintervals and the probabilistic information of these subintervals is obtained to construct a disjoint layered ambiguity set. A nonlinear HVAC's energy consumption problem is formulated by using the DROA method to deal with these two uncertainties based on a disjoint layered ambiguity set with distributionally robust chance constraints (DRCCs). In order to solve this nonlinear problem, these DRCCs are converted to a linear programming problem and solved by using linear programming. Simulation results illustrate the effectiveness of the proposed method and comparing them with the DROA based on a nest layered ambiguity set and the traditional robust approach (ROA), the proposed DROA based on a disjoint layered ambiguity set reduces the electricity cost and guarantees the thermal comfort level of users.