Optical triple sensor for measuring pH, oxygen and carbon dioxide