A respiratory device (e.g., BiPAP machine) to tracheostomy tube connector includes a first component including a first hollow channel through which air is pumped from a respiratory device in one direction, and a second component connected to the first component, wherein the second component includes a second hollow channel through which air moves in two directions to and from a tracheostomy tube, and an opening through which air is vented upon return from the tracheostomy tube. The connector further includes a valve positioned in between the first component and the second component and a sensor seated in the second component and adjacent to the opening, wherein the sensor detects any of a flow of air in the second component and a motion of the valve.