Full question(s):
These questions refer to Table 564 of Apollo2 datasheet rev1.0.
In the table, TMRPINB is available as a clock source option. TMRPINB is the output signal of timer B, and it seems that it is also an enable signal.
1.) How do you use TMRPINB as a clock?
2.) What is the clock frequency?
Answer(s):
1.) The TMRPIN pin function can be used as Timer input or Timer output. When using internal clock source for CTimer, the TMRPIN can be used as timer output pin, such as for PWM output. When TMRPIN is selected as clock source (this is selected in SDK using AM_HAL_CTIMER_CLK_PIN for clock source) then TMRPIN is used for clock input, and the timer output pin function is not available. For Timer B0, either GPIO13, GPIO26, or GPIO43 can be configured as TCTB0, which is TMRPIN fo CTimer B0.
2.) When using TMRPIN as external clock input, the clock can be any frequency up to 12 MHz, and requires minimum pulse width of 40 ns (this is specified in section 17.18 of datasheet). The external "clock" does not have to be a regular clock of fixed frequency. The external clock input can be used for event counting.
Comments
0 comments
Article is closed for comments.