Add the source code main.c

we use the timer to detect and count it, then we know the RPM.