Hello there,
I am using the S32K116EVB2Q048 for FTM input capture project for speed measurement.
I am using PTD15 and PTD16 as FTM0CH0 and FTM0CH1 from the port configuration of P&E pin mux settings.
However, the interrupt of FTM0 is not getting triggered all the time if I feed the PTD15 and 16 pin the signal from external, which generated by a signal generator, ground has been connected properly.
Here are my findings:
Then I did a measurement on the PTD15 pin before and after I plugin the signal from external, the attachments are these screenshot from oscilloscope.
From them, I can see the external signal got dropped significantly after I plugin the J1 connector for PTD15 port. That is probably why it cannot be captured by PTD15 and 16
Could someone tell me why this is happening and give me the solution to get PTD15 and 16 working correctly?
Thank you
Junxi
Hi,
LED circuitry is connected on PTD15 and PTD16 on the EVB, maybe this can affect signal.
And if you have PTD15 set for input what is generating signal you measured before you plugged external one?
BR, Petr
Hello Petr,
We found the problem, it is in the FTM SC register.
The FTM0CH0 (PTD15) and FTM0CH1(PTD16) have been configured as output at PWMENn.
After disable the configuration for them. We are able to get correct input capture.
Thank you for the help,
Junxi
Hello Petr,
Thank you for the response.
I have seen the jumper in the schematic of the EVB and I can confirm the jumper is in the correct position.
The attachment is the position jumper at.
The signal I generated from the EVB itself is a 20kHz PWM, with 50% duty cycle. This can be captured by the PTD15 and 16 but not the same signal generated external of the EVB.
But as I said, if I switch to other port, for example, PTD0, PTD1 and PTE8. They are all able to capture the external signals. The port configuration is the same for these pins.
Can you please let me know why the behavior is different for PTD15 and 16?
Thank you,
Junxi