Comparators and Schmitt triggers are op-amp circuits used to convert analog signals to digital outputs. A comparator outputs one of two levels depending on if the input is above or below a reference. A Schmitt trigger introduces positive feedback to improve switching speed and reject noise, resulting in a nonlinear transfer function with hysteresis. It prevents erroneous switching from noise within a defined voltage range. Schmitt triggers find use in noisy environments and where clean switching is needed.