manitou
Senior Member+
PulsePosition hasn't been ported yet. It's filled with FTM/TPM timer code. Only Teensy 3.x & LC have those timers. NXP put different timers in this IMXRT new chip.
I will eventually port PulsePosition, maybe to the FlexPWM timers, maybe to the quad timers. But that's not going to happen for the 1.48 release.
I have a proof of concept sketch for PPM input portion of PulsePosition for the T4 using quad timer, see
https://github.com/manitou48/teensy4/blob/master/ppminq.ino
This was based on earlier sketch/discussion that used T4 quad timer. As with that sketch, I was never able to get overflow (TOF) interrupt to work on T4 quad timer, so I used timer compare (0xffff) to count timer overflows. In the ppminq.ino sketch the T4 quad timer is clocked at 37.5 MHz. I tested with a T3.2 running PulsePosition LoopBack example with PPM output on T3.2 pin 9 jumpered to T4 capture pin 11. The printed output looks good.
Code:
1086 : 600.03 1500.03 759.23 1500.03 1500.00 1234.56
1087 : 600.03 1500.00 759.25 1500.00 1500.03 1234.53
1088 : 600.03 1500.03 759.23 1500.03 1500.00 1234.56
1089 : 600.03 1500.00 759.25 1500.00 1500.03 1234.53
Now to see how to get the T4 to generate PPM out pulses...
Last edited: