SWRU543B January 2019 – June 2025 CC3230S , CC3230SF , CC3235MODS , CC3235MODSF , CC3235S , CC3235SF
The main components of each GPTM block follow:
The exact functionality of each GPTM is controlled by software and configured through the register interface. Timer A and Timer B can be used individually, in which case they have a 16-bit counting range for the 16/32-bit GPTM blocks. In addition, Timer A and Timer B can be concatenated to provide a 32-bit counting range for the 16/32-bit GPTM blocks
The prescaler can only be used when the timers are used individually.
Table 9-2 lists the available modes for each GPTM block. When counting down in one-shot or periodic modes, the prescaler acts as a true prescaler and contains the least significant bits (LSBs) of the count. When counting up in one-shot or periodic modes, the prescaler acts as a timer extension, and holds the most significant bits (MSBs) of the count. In input edge count, input edge time, and PWM mode, the prescaler always acts as a timer extension, regardless of the count direction.
| Mode | Timer Use | Count Direction | Counter Size | Prescaler Size(1) |
|---|---|---|---|---|
| One-shot | Individual | Up or down | 16-bit | 8-bit |
| Concatenated | Up or down | 32-bit | – | |
| Periodic | Individual | Up or down | 16-bit | 8-bit |
| Concatenated | Up or down | 32-bit | – | |
| Edge count | Individual | Up or down | 16-bit | 8-bit |
| Edge time | Individual | Up or down | 16-bit | 8-bit |
| PWM | Individual | Down | 16-bit | 8-bit |
Software configures the GPTM using the GPTM Configuration (GPTMCFG) register, the GPTM Timer A Mode (GPTMTAMR) register, and the GPTM Timer B Mode (GPTMTBMR) register. When Timer A and Timer B are in one of the concatenated modes, they can only operate in one mode. However, when configured in an individual mode, Timer A and Timer B can be independently configured in any combination of the individual modes.