1.7 AFE

When using the PIC32CXMTC, the connected AFE (ATSENSE301, MCP3910, MCP3912, MCP3913, or MCP3914) is selected by the AFE_SELECTION register. When using the PIC32CXMTSH (internal ATSENSE203), this register is not used.

The AFE_CTRL_0 register configures the selected AFE, mainly the PGA gains. This register has a different meaning depending on the selected AFE. For PIC32CXMTC + MCP3910 this register is not used.

The CHANNEL_MATRIX register allows to map each physical channel (0, 1, 2, 3, 4, 5, 6, or 7) to a specific logical channel (I_A, V_A, I_B, V_B, I_C, V_D, I_N, or V_D). When using PIC32CXMTSH or PIC32CXMTC + ATSENSE301, channels 0, 1, 3, and 5 (differential channels) should be used for currents and channels 2, 4, and 6 (single-ended channels) should be used for voltages.

Several configuration examples are given below.