This commit is contained in:
Pawel Spychalski (DzikuVx)
2017-10-23 19:37:13 +02:00
parent 974a31ad61
commit d0120405fb
3 changed files with 5 additions and 5 deletions

View File

@@ -1,8 +1,8 @@
// #define LORA_HARDWARE_SERIAL
#define LORA_HARDWARE_SPI
// #define DEVICE_MODE_TX
#define DEVICE_MODE_RX
#define DEVICE_MODE_TX
// #define DEVICE_MODE_RX
#define DEBUG_SERIAL
// #define DEBUG_PING_PONG

View File

@@ -9,7 +9,7 @@ void qspDecodeRcDataFrame(QspConfiguration_t *qsp, int output[]) {
temporaryPpmOutput[0] = (uint16_t) (((uint16_t) qsp->payload[0] << 2) & 0x3fc) | ((qsp->payload[1] >> 6) & 0x03);
temporaryPpmOutput[1] = (uint16_t) (((uint16_t) qsp->payload[1] << 4) & 0x3f0) | ((qsp->payload[2] >> 4) & 0x0F);
temporaryPpmOutput[2] = (uint16_t) (((uint16_t) qsp->payload[2] << 6) & 0x3c0) | ((qsp->payload[3] >> 2) & 0x3F);
temporaryPpmOutput[3] = (uint16_t) (((uint16_t) qsp->payload[3] << 8) & 0x300) | ((qsp->payload[4] >> 2) & 0xFF);
temporaryPpmOutput[3] = (uint16_t) (((uint16_t) qsp->payload[3] << 8) & 0x300) | ((qsp->payload[4]) & 0xFF);
temporaryPpmOutput[4] = qsp->payload[5];
temporaryPpmOutput[5] = qsp->payload[6];
temporaryPpmOutput[6] = (qsp->payload[7] >> 4) & 0b00001111;

View File

@@ -5,8 +5,8 @@
#define E45_TTL_100_UART_DOWNTIME 30
#define RX_RX_HEALTH_FRAME_RATE 2000
#define TX_RC_FRAME_RATE 1000 //ms
#define RX_FAILSAFE_DELAY (TX_RC_FRAME_RATE * 4)
#define TX_RC_FRAME_RATE 50 //ms
#define RX_FAILSAFE_DELAY (TX_RC_FRAME_RATE * 8)
#define TX_PING_RATE 2000