Hi all,
In order to initialize FTM1 and FTM2 as input capture source select, register SIM_SOPT4 has specific fields (Re pagenumber:-266 (FTM2CH0SRC & FTM1CH0SRC)) to do the initialization. My doubt is how FTM3 can be configured as "input capture source" selection ? or Is it possible to initialize FTM3 as "input capture source" selection.
Thanks in advance
Raj
Hi rajath,
FTM3 can be configured as "Input Capture mode". Please refer the description in '38.4.4 Input Capture mode' of K22P144M120SF5V2RM.
For the FTM0 and FTM3, no additional configuration is required. The input capture pins are default as FTMx_CHn. For example: FTM3_CH0 and FTM3_CH1 and etc.
Best Regards,
Robin
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------
Thanks Robin. Even i have found that FTMxCHn can be configured as input capture mode. My, doubt is why there is any field specified in SIM_SOPT4. (Ref the same datasheet you provided Page No 276). Im attaching the screenshot as well
There is not "input capture source" selection for FTM3. The input capture source are FTM3_CH0 ~ FTM3_CH7.
Hi Robin,
So, you meant to say that FTM3 (FTM3-CH0 to FTM3-CH7) by default is in "Input capture mode".
After configure the FTM as "Input capture mode":
The FTM3_CH0 to FTM3_CH7 pins are input capture pins. You can't select other input capture source for FTM3.
The FTM1_CHx and FTM2_CHx pins are input capture pins by default, but you can select other sources for FTM1_CH0 FTM2_CH0 input capture.
For example: use CMP0 output\CMP1 output instead of the default pin FTM2_CH0.
"After configure the FTM as "Input capture mode": " This is where my doubt is brother. If you go through SIM_SOPT4 register you wont find any specific field for FTM3 wheras FTM1 and FTM2 has