19.7 INLVLx - Input Threshold Control
The INLVLx register controls the input voltage threshold for each available PORTx input pin. A selection between the Schmitt Trigger (ST, CMOS-compatible) and the Low-Voltage Buffer (LVBUF, TTL-compatible) thresholds is available.
The ST input buffer provides voltage-dependent input sensing, meaning the VIL and VIH levels are proportional to the supply voltage (VDD). The ST buffer typically has a wide gap between VIL and VIH levels (hysteresis). The ST buffer is also compatible with CMOS levels.
Unlike the ST buffer, the LVBUF input buffer provides voltage-independent input sensing, meaning the VIL and VIH levels remain constant for the entire range of supply voltage (VDD). The LVBUF buffer typically has very low VIL and VIH levels with a smaller hysteresis, thus making it an ideal choice for low-voltage input irrespective of the VDD supply voltage. The LVBUF buffer is also compatible with TTL levels.
Choosing an appropriate input threshold is vital in determining the value of a read of the PORTx register and the level at which an interrupt-on-change occurs if that feature is enabled. Refer to the I/O Ports table in the "Electrical Specifications" chapter for more details on the threshold levels.