An apparatus (1) to assist a patients respiration by delivering air to a patient through a mask (20), including a ramp module (10) connected to a control unit (2) to provide the control unit with a pressure value PM at mask (20), so that when apparatus (1) starts functioning, the pressure progressively rises until it reaches a treatment pressure PTi, the apparatus further including a comparator connected to ramp module (10), at least one device for detecting the patients breathing parameters and sending them to the comparator, so that the comparator can determine whether an event (E1, E2 or E3) occurs in patients breathing and to send the corresponding data to ramp module (10) which provides control unit (2) with a pressure value PM that will speed up with respect of time, so that the pressure rise at patients mask (20) is accelerated.