From b07b081a153449e9ff6eb07f59d29a91fd8130ba Mon Sep 17 00:00:00 2001 From: pascallanger Date: Thu, 7 Nov 2019 11:13:48 +0100 Subject: [PATCH] HoTT telemetry size change --- Multiprotocol/HOTT_cc2500.ino | 6 +++--- Multiprotocol/Multiprotocol.h | 8 +++++--- Multiprotocol/Telemetry.ino | 4 ++-- 3 files changed, 10 insertions(+), 8 deletions(-) diff --git a/Multiprotocol/HOTT_cc2500.ino b/Multiprotocol/HOTT_cc2500.ino index 60d67ad..59a6512 100644 --- a/Multiprotocol/HOTT_cc2500.ino +++ b/Multiprotocol/HOTT_cc2500.ino @@ -293,7 +293,7 @@ uint16_t ReadHOTT() { //Telemetry // [0..4] = TXID // [5..9] = RXID - // [10] = 0x40 bind, 0x00 normal + // [10] = 0x40 bind, 0x00 normal, 0x80 text menu // [11] = 0x0X telmetry page X=0,1,2,3,4 ? // Telem page 0 = 0x00, 0x33, 0x34, 0x46, 0x64, 0x33, 0x0A, 0x00, 0x00, 0x00 // = 0x55, 0x32, 0x38, 0x55, 0x64, 0x32, 0xD0, 0x07, 0x00, 0x55 @@ -314,9 +314,9 @@ uint16_t ReadHOTT() packet_in[0]= TX_RSSI; packet_in[1]= TX_LQI; debug("T="); - for(uint8_t i=11;i < HOTT_RX_PACKET_LEN; i++) + for(uint8_t i=10;i < HOTT_RX_PACKET_LEN; i++) { - packet_in[i-9]=packet_in[i]; + packet_in[i-8]=packet_in[i]; debug(" %02X",packet_in[i]); } debugln(""); diff --git a/Multiprotocol/Multiprotocol.h b/Multiprotocol/Multiprotocol.h index 39cd26a..481e31b 100644 --- a/Multiprotocol/Multiprotocol.h +++ b/Multiprotocol/Multiprotocol.h @@ -19,7 +19,7 @@ #define VERSION_MAJOR 1 #define VERSION_MINOR 3 #define VERSION_REVISION 0 -#define VERSION_PATCH_LEVEL 39 +#define VERSION_PATCH_LEVEL 40 //****************** // Protocols @@ -978,9 +978,11 @@ Serial: 100000 Baud 8e2 _ xxxx xxxx p -- data[4-]= packed channels data, 11 bit per channel Type 0x0E HoTT telemetry - length: 13 + length: 14 data[0] = TX_RSSI data[1] = TX_LQI - data[2-12] = telemetry data + data[2] = type + data[3] = page + data[4-13] = data */ diff --git a/Multiprotocol/Telemetry.ino b/Multiprotocol/Telemetry.ino index d7ec899..bb197cb 100644 --- a/Multiprotocol/Telemetry.ino +++ b/Multiprotocol/Telemetry.ino @@ -308,11 +308,11 @@ static void multi_send_status() void HOTT_short_frame() { #if defined MULTI_TELEMETRY - multi_send_header(MULTI_TELEMETRY_HOTT, 13); + multi_send_header(MULTI_TELEMETRY_HOTT, 14); #else Serial_write(0xAA); // Telemetry packet #endif - for (uint8_t i = 0; i < 13; i++) // TX RSSI and TX LQI values followed by frame number and telemetry data + for (uint8_t i = 0; i < 14; i++) // TX RSSI and TX LQI values followed by frame number and telemetry data Serial_write(packet_in[i]); } #endif