24.3.2.1 Input Matrix

The Input Matrix (INMX) unit distributes and routes the Timer/Counter waveform output across the WEX internal connections, according to the selectable configurations, as shown in Table 24-1.

The Input Matrix decides how inputs go into the dead-time generator. If the dead-time generator is enabled, it splits each input in two. All the signals are split if at least one dead time generator is enabled. The table below shows the output from the dead-time generator based on DTI and INMX settings.

Swap does not change which waveform output goes where, only the LS/HS pair.

When the DTI is disabled, and the SWAP is in the default condition, it is possible to bypass the WEX module functions and see the Timer/Counter (T/C) WO signals to port pins, which can be considered as Transparent mode for the WEX that the user can configure.

Table 24-1. Input Matrix Configurations
INMX[2:0] Name DTInEN PIN7 PIN6 PIN5 PIN4 PIN3 PIN2 PIN1 PIN0
000 DIRECT 0 - - - - WO3* WO2* WO1* WO0*
1 WO3-HS WO3-LS WO2-HS WO2-LS WO1-HS WO1-LS WO0-HS WO0-LS
001 - Reserved
010 CWCMA 0 WO0 WO0 WO0 WO0 WO0 WO0 WO0 WO0
1 WO0-HS WO0-LS WO0-HS WO0-LS WO0-HS WO0-LS WO0-HS WO0-LS
011 CWCMB 0 WO1 WO0 WO1 WO0 WO1 WO0 WO1 WO0
1 WO1-HS WO1-LS WO0-HS WO0-LS WO1-HS WO1-LS WO0-HS WO0-LS
1xx - Reserved
Note: * - If one WOn has Dead Time Unit enabled, the WOn with disabled Dead Time Units will be available on their respective WOn-LS PIN instead of their WOn PINs.

For example, INMX is in DIRECT mode. DTI2EN bit is set to ‘1’, and the other DTInEN bits are set to ‘0’.

  • WO0 signal is available on PIN0
  • WO1 signal is available on PIN2
  • WO2 signal is split on PIN4 and PIN5
  • WO3 signal is available on PIN6

An extra set of signals goes with the waveform when using a Timer/counter in High Resolution mode. These need to be adjusted for the signals to follow the waveform. For example, when INMX[2:0] = CWCMA, the high-resolution signals for WO0 need to be distributed on all channels for the output from the WEX peripheral. For DIRECT mode, the hires-values for WO2 received on position 2 in the input vector must be output on position 4 and 5 on the output vector.

For the direct mode, each waveform output is used as input for a separate Dead Time Unit. Use this mode to bypass the WEX and see the T/C outputs on I/O pins when the DTI units are disabled.

The Common Waveform Channel Mode A uses WO0 as input to all dead-time generators. The other waveforms are ignored. When the DTIs are enabled, the WEX will output WO0 and its complementary with dead-time added on all outputs.

The Common Waveform Channel Mode B can be used if dead-time is handled in the Timer/Counter by carefully selecting the values of Compare 0 and Compare 1 (TCEn.CMP0 and TCEn.CMP1) registers, as depicted below. The WEX Module will only ensure correct waveform propagation to I/Os, where WO0 is output on every even pin while WO1 is on every odd pin.

Figure 24-3. PWM Generation for CWCMB