Menu

#91 Frsky CPPM 18ms support (solution included)

New
nobody
None
Medium
Defect
2014-08-28
2014-08-28
Anonymous
No

Originally created by: krzyszto... (code.google.com)@gmail.com

What steps will reproduce the problem?
1. Connect CPPM Frsky 18ms CPPM signal
2. Set most of the chanels to 100%
3. Try to control throttle, or see RC channels using any mavlink compatible ground station

What is the expected output? What do you see instead?
The controll should be possible, but it's not because to short CPPM frame gap.

What version of the product are you using? On what operating system?
N/A

Please provide any additional information below.

The solution is really simple, if we make assumption, that during start up, the gap between CPPM frames has correct length, we can use channel counting to determine start of new frame.

So you need to modify one line radioIn.c checking if ppm_ch == PPM_NUMBER_OF_CHANNELS+1.

#if (USE_PPM_INPUT == 1)
    if (__IC_PIN(PPM_IC) == PPM_PULSE_VALUE)
    {
        uint16_t pulse = time - rise_ppm;
        rise_ppm = time;

                // kku
        //if (pulse > MIN_SYNC_PULSE_WIDTH)
                if ( (pulse > MIN_SYNC_PULSE_WIDTH) || (ppm_ch == PPM_NUMBER_OF_CHANNELS+1))
        {
            ppm_ch = 1;
        }

It works fine, and without any problems.
Regards
Krzysiek

Discussion


Log in to post a comment.

MongoDB Logo MongoDB