Skip to content

ESP32 support ?  #6

@johncohn

Description

@johncohn

I'm trying to use your PPM-Reader with an Adafruit ESP32 Huzzah Feather and I'm not able to get anything but zeros for all 6 channels. I'm using a Radiolink T8S transmitter and an R8EF receiver. The two are correctly paired and I can drive a servo correctly from the transmitter receiver pair . The R8EF is in PPM /SBUS mode and I believe I have the right pins to be getting PPM. I'm using the code from your example only modified to point at a different pin. I suspect this has to do with needing to set up the HW interrupts on that pin i'm usoing. In ESP32 any GPIO can have a HW interrupt.. but I only know how to set them up with a unuqe ISR. Have you gotten this to work with ESP32. ? An earlier posted issue seems to indicate it used to work. Any help MUCH appreciated. Thank you for creating this !

John Cohn johncohnvt@gmail.com

/*
This example outputs values from all PPM channels to Serial
in a format compatible with Arduino IDE Serial Plotter
*/

#include <PPMReader.h>

// Initialize a PPMReader on digital pin 3 with 6 expected channels.
byte interruptPin = 13; // original example used pin 3
byte channelAmount = 6;
PPMReader ppm(interruptPin, channelAmount);

void setup() {
Serial.begin(115200);
}

void loop() {
// Print latest valid values from all channels
for (byte channel = 1; channel <= channelAmount; ++channel) {
unsigned value = ppm.latestValidChannelValue(channel, 0);
Serial.print(value);
if(channel < channelAmount) Serial.print('\t');
}
Serial.println();
delay(20);
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions