I have happily used my library in testing phase. After that I built a sketch wich using an another interrupt driven library too, and found a little time "glitching" in the PPM-PWM conversion.
I think this is when the another interrupt blocking the input interrupt. Is there a solution for setting priority between interrupts? Wich interrupt is prior, the input or the timer one?
Timer0 is always running, if it would be the case, the test also would done "glitching".
I'm sure, this is because of the additional library, wich is using Timer2 for it's functionality.
I would be happy if I would set input Interrupt as a priority for Timer2.
If it is not possible, the proper setting is impossible if other interrupt is used. The PPM signal is 2 ms wide, with resolution of 255.
I was trying to get the PPM signals/channels from the DJI Ocusync Unit separated for controlling a custom gimbal driven by 2 servos and your library is working like a charm. Thanks a lot for your affords and making this so easy!
Most probably you know ppm topic in Arduino world very well. So please advice.
Problem is that I have 6ch ppm signal. In transmitter I would like to install Arduino to :
catch signal from ppm out from transmitter main board
read 2 potentiometers connected to Arduino
replace ch 5 and 6 with potentometers values
Generate back all 1-4 and 5,6 channels to transfer them to radio module.
Is your library a good start to tinker, or there are better, more suitable for this specific topic?
I found on forum here info about rc channel extender, but it is for extending from 6 to 8, not replacing. And it is not for Arduino but for pic. And not source available.
The function You try to build is called trainer port in RC radios. The trainer port is a PPM input for the radio, and with the mixes You able to mix the trainer port CH 1 and 2 to radio output CH 5 and 6.
This radio is 6ch, but 5 and 6 are for flaps and landing gear. There are no potentometers for them. And I would need 5 and 6 made analog , for gimbal movement. So the idea is tho replace 5 and 6 with new signals before they will reach dht module in transmitter.
I am not sure if it is doable. If not maybe finnaly buy a taranis radio...
OK. I understand the reason. The concept can work. As I see You can do it with cutting the PPM signal between your radio, and the module, and You can insert the Arduino in between. For receiving the radio ppm signal, this library is OK.For regenerating the PPM signal maybe the loop{} can do, but because it is time critical I suggest a timer based solution instead.
I have a PWM2PPM project, which I wrote to create a PPM signal from my old PWM receiver ( PWM signal reading problem - Programming Questions - Arduino Forum )
You can cut the PPM generation part from it, and the loop role is only the data transfer, and the ADC.