In the past years, we have witnessed an increasing interest in smart buildings, in particular for optimal energy management, renewable energy sources, and smart appliances. In this paper, we investigate the problem of scheduling smart appliance operation in a given time horizon with a set of energy sources and accumulators. Appliance operation is modeled in terms of uninterruptible sequential phases with a given power demand, with the goal of minimizing the energy bill fulfilling duration, energy, and user preference constraints. A mixed-integer linear programming (MIP) model and greedy heuristic algorithm are given, which are used in a synergic way. We show how a general purpose (off-the-shelf) MIP-refining procedure can be effectively used for improving, in short computing time, the quality of the solutions provided by the initial greedy heuristic. Computational results confirm the viability of the overall approach, in terms of both solution quality and speed.