frequency counter? but...

Configure one timer as a counter for the pulse and another as time base.