Reading 20 pwm signals with arduino

Hello, I have a project where i need to read 20 pwm signals from 2 RC hobby receivers. Arduino mega has 14 pwm pins so i have no idea what to do for the other 6 pins. How can i read 20 pwm signals on an arduino board?

The Arduino PWM enabled pins output PWM. You don't need to use a PWM enabled pin to read a PWM input

What characteristics of the received PWM input do you want to read ?

  • Frequency ?
  • Pulse width ?
  • Voltage ?
  • Something else ?
1 Like

I just need to read a pulse width between 1000 to 2000 microseconds... Can i read these with standard digital pins ?

yes. Your need an interrupts on these pins

1 Like

The signals are output sequentially, just as received from the serial RF stream. So you know which signal to detect next from the same receiver. It may be easier to monitor the receiver input signal, if accessible.

If free pins are rare then you can multiplex the signals of each receiver. Then only one timer and its ICMP pin is required for measuring the signals of each receiver.

1 Like

When I tried that in the past it worked fine with a HobbyKing (Flysky) receiver, but then I took a Futaba (FASST) receiver, and that was outputting overlapping PWM output servo signals.

OP did not mention what brand receivers or transmission protocol. The receiver micht even be outputting BSUS or PPM streams, that are easier to capture with one wire.

1 Like

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.