Hi there! I am a student of electrical engineering. Can you help me out with my project? I have to design a project in which I have to control the speed and direction of a DC geared motor with the help of the STM32F407 discovery board. This blog covers all my queries regarding speed and control management. **But I also need to measure the RPM of that motor using an infrared sensor (like MOC7811) and display its RPM on an LCD interfaced with STM. I need your help with the code with which we can configure the timers and other things to get this work done.** Please reply to me ASAP. Regards, Mohsin Zafar