First thank you to chris.troutner for uploading his code, it has saved me a good deal of time getting started with my first Maple project.
WRT to this code http://pastebin.com/53rmN4rF
I can give a little back by telling you why you are having the overflow problem. It's because you set value=0; only inside the input capture ISR. If you have no input pulse to capture, and therefore an overflow, the input capture ISR will never trigger and therefore you never set value=0. Move the overflow_flag check to the serial output loop.
Also when capturing input durations you should never stop or reset the counter (pretty sure the STM32 is no exception). Leave it alone, just let it run. Currently the input capture ISR zeros the counter. This means your counter reset is offset from the actual transition event by the interrupt latency, and the code inside the ISR. At 100Hz this makes little to no difference on this 72Mhz CPU, but as speeds increase it will become more apparent.
The best thing to do is something like this inside your ISR:
current = TIMER4_BASE->CCR1; //read the captured value
value = current - previous;
previous = current;
Make sure current and previous are unsigned 16 bit datatypes and everything will take care of itself.
Only problem with this approach is you can't use timer overflow events in quite the same way to spot an overflow.
And finally you can chain or cascade timers together to give you 32-bit input capture resolution see AN2592 (CD00165509.pdf). Another thought to save this complexity is to use the prescaler like an autoranger, take a quick measurement at an arbitrary prescaler, then adjust the prescaler to better suit the frequency. I dare say you could confuse it with a fast enough moving frequency, but with a thought.