PPMReader
PPMReader copied to clipboard
Arduino running F_CPU ≠ 8MHz does not work with Timer1
First of all, great library! It got my small Syma S107 heli in the air using a "normal" remote control providing PPM signals. I converted the PPM into infrared signals that the heli could recieve.
However, when I tried to improve accuracy by using Timer1 I could not get any PPM signals with ppmReader.get() anymore.
The reason was because my Nano v3 ran on 16MHz. After changing
counter = TCNT1 * CPU_SPEED_MULTIPLIER;
into
counter = TCNT1 / CPU_SPEED_MULTIPLIER;
it worked like a charm. Maybe you could include the fix in the next release.
Cheers!