Example

The 68HC908AZ60 contains two timer modules TIMA and TIMB. Each one of these modules is based on a 16-bit counter that can operate as a free-running counter or a modulo-up counter. TIMB module has 2 channels and 2 related input/output pins. Can we use the TIMB peripheral for PWM output and input capture components at once?

Timer Module B (TIMB) is supported in PE by the following devices: TIMB, TIMB0, TIMB1, TIMBfree, TIMB_PPG, TIMBPP, TIMB0PPG, TIMB1PPG.

It follows from the table in this chapter that:

Because the channels of this timer are sharing one prescaler, it is necessary to configure the same prescaler value for both the PWM component and the Capture component.