Patients under mechanical ventilation who are suspected to be recovered and ready to return to spontaneous ventilation often undergo an spontaneous breathing trial (SBT) before extubation and liberation from mechanical ventilation. During the test, which lasts from 30 minutes to 2 hours , the patient receives minimal support from the ventilator, and the ICU team observes if the patient develops any signs or symptoms of discomfort or respiratory distress. If the patient tolerates the test, he or she is considered ready for extubation. The Neurally Adjusted Ventilatory Assist (NAVA) is a new mode of ventilation, shown to improve patient-ventilator synchrony. It has not been tested during SBTs. Our objective is to compare the performance of NAVA with the commonly used Pressure Support ventilation, during an SBT. Patients considered to be ready for an SBT by the ICU team will undergo two SBTs in random order: one in pressure support, and the other on NAVA, with a 1-hour interval between the tests. Ventilatory parameters and patient-ventilator interaction variables will be compared among the two tests.