We study the problem of scheduling repetitive real-time tasks with the Earliest Deadline First (EDF) policy that can guarantee the given maximal temperature constraint. We show that the traditional scheduling approach, i.e., to repeat the schedule that is feasible through the range of one hyperperiod, does not apply any more. Then, we present necessary and sufficient conditions for real-time schedules to guarantee the maximal temperature constraint. Based on these conditions, a novel scheduling algorithm is proposed for developing the appropriate schedule that can ensure the maximal temperature guarantee. Finally, we use experiments to evaluate the performance of our approach. Categories and Subject Descriptors D.4.1 [Algorithms]: Software--Operating Systems, Process Management, Scheduling General Terms Algorithms, Reliability, Performance Keywords Real-time scheduling, thermal aware, energy consumption, maximal temperature