How can I measure the period of a wave using a comparator and timer?
I am using the STM32L476G Discovery board and I understand that the COMP is able to trigger interrupts using the exti line 21 and that can be used to along with the timer to measure the time between consecutive rising edges or falling edges. However what I'm struggling with is with the coding. I've looked at countless tutorials but I don't quite see a pattern that I can use to implement my own code. Are there perhaps any other resources I can use to help me?