SPRUJD3A July 2025 – October 2025 F28E120SB , F28E120SC
FILE: cmpss_lite_ex1_asynch.c
This example enables the CMPSSLITE2 COMPH comparator and feeds the asynchronous CTRIPOUTH signal to the GPIO4/OUTPUTXBAR3 pin and CTRIPH to GPIO0/MCPWM1A.
CMPSS is configured to generate trip signals to trip the MCPWM signals. CMPIN2P is used to give positive input and internal DAC is configured to provide the negative input. Internal DAC is configured to provide a signal at VDD/2. An MCPWM signal is generated at GPIO0 and is configured to be tripped by CTRIPOUTH.
When a low input(VSS) is provided to CMPIN2P,
When a high input(higher than VDD/2) is provided to CMPIN2P,
PWMXBAR is used to provide the trip signal (CTRIPH) to MCPWM. The trip signal is inverted in PWMXBAR since MCPWM trip zone signals are active low signals.
External Connections
Watch Variables