An in-situ sensor system that is configured to be placed inside of an oxygen mask for a pilot. The sensor system is readily placed in a position over the exhalation valve such that it can capture data from the exhaled air of the pilot. The sensor system has an optical sensor element that can capture data real time and feed the data to a control module that can subsequently be use to generate output data for the pilot and/or ground elements.