mirror of
https://github.com/pascallanger/DIY-Multiprotocol-TX-Module.git
synced 2025-02-04 20:08:11 +00:00
FrSkyD and X telemetry
This commit is contained in:
parent
70f52afb3d
commit
21ab94c512
@ -177,26 +177,33 @@ void frsky_check_telemetry(uint8_t *pkt,uint8_t len)
|
||||
TX_LQI = pkt[len-1]&0x7F;
|
||||
for (uint8_t i=3;i<len-2;i++)
|
||||
pktt[i]=pkt[i]; // Buffer telemetry values to be sent
|
||||
if((pktt[6]>0 && pktt[6]<=10) && ( pktt[7] & 0x1F ) == (telemetry_counter & 0x1F) )
|
||||
|
||||
if(pktt[6]>0 && pktt[6]<=10)
|
||||
{
|
||||
uint8_t topBit = 0 ;
|
||||
if ( telemetry_counter & 0x80 )
|
||||
if (protocol==MODE_FRSKYD)
|
||||
{
|
||||
if ( ( telemetry_counter & 0x1F ) != RetrySequence )
|
||||
if ( ( pktt[7] & 0x1F ) == (telemetry_counter & 0x1F) )
|
||||
{
|
||||
topBit = 0x80 ;
|
||||
uint8_t topBit = 0 ;
|
||||
if ( telemetry_counter & 0x80 )
|
||||
{
|
||||
if ( ( telemetry_counter & 0x1F ) != RetrySequence )
|
||||
{
|
||||
topBit = 0x80 ;
|
||||
}
|
||||
}
|
||||
telemetry_counter = ( (telemetry_counter+1)%32 ) | topBit ; // Request next telemetry frame
|
||||
}
|
||||
else
|
||||
{
|
||||
// incorrect sequence
|
||||
RetrySequence = pktt[7] & 0x1F ;
|
||||
telemetry_counter |= 0x80 ;
|
||||
}
|
||||
}
|
||||
telemetry_counter = ( (telemetry_counter+1)%32 ) | topBit ; // Request next telemetry frame
|
||||
}
|
||||
else
|
||||
{
|
||||
if(pktt[6]>0 && pktt[6]<=10)
|
||||
{
|
||||
// incorrect sequence
|
||||
RetrySequence = pktt[7] & 0x1F ;
|
||||
telemetry_counter |= 0x80 ;
|
||||
}
|
||||
pktt[6]=0; // Discard packet
|
||||
}
|
||||
//
|
||||
|
@ -70,37 +70,37 @@
|
||||
//The protocols below need an A7105 to be installed
|
||||
#define FLYSKY_A7105_INO
|
||||
#define HUBSAN_A7105_INO
|
||||
#define AFHDS2A_A7105_INO
|
||||
//#define AFHDS2A_A7105_INO
|
||||
|
||||
//The protocols below need a CYRF6936 to be installed
|
||||
#define DEVO_CYRF6936_INO
|
||||
//#define DEVO_CYRF6936_INO
|
||||
#define DSM_CYRF6936_INO
|
||||
#define J6PRO_CYRF6936_INO
|
||||
#define WK2x01_CYRF6936_INO
|
||||
//#define J6PRO_CYRF6936_INO
|
||||
//#define WK2x01_CYRF6936_INO
|
||||
|
||||
//The protocols below need a CC2500 to be installed
|
||||
#define FRSKYV_CC2500_INO
|
||||
//#define FRSKYV_CC2500_INO
|
||||
#define FRSKYD_CC2500_INO
|
||||
#define FRSKYX_CC2500_INO
|
||||
#define SFHSS_CC2500_INO
|
||||
//#define FRSKYX_CC2500_INO
|
||||
//#define SFHSS_CC2500_INO
|
||||
|
||||
//The protocols below need a NRF24L01 to be installed
|
||||
#define BAYANG_NRF24L01_INO
|
||||
#define CG023_NRF24L01_INO
|
||||
#define CX10_NRF24L01_INO // Include Q2X2 protocol
|
||||
#define ESKY_NRF24L01_INO
|
||||
//#define ESKY_NRF24L01_INO
|
||||
#define HISKY_NRF24L01_INO
|
||||
#define KN_NRF24L01_INO
|
||||
#define SLT_NRF24L01_INO
|
||||
//#define KN_NRF24L01_INO
|
||||
//#define SLT_NRF24L01_INO
|
||||
#define SYMAX_NRF24L01_INO
|
||||
#define V2X2_NRF24L01_INO
|
||||
#define YD717_NRF24L01_INO
|
||||
#define MT99XX_NRF24L01_INO
|
||||
#define MJXQ_NRF24L01_INO
|
||||
#define SHENQI_NRF24L01_INO
|
||||
#define FY326_NRF24L01_INO
|
||||
#define FQ777_NRF24L01_INO
|
||||
#define ASSAN_NRF24L01_INO
|
||||
//#define FY326_NRF24L01_INO
|
||||
//#define FQ777_NRF24L01_INO
|
||||
//#define ASSAN_NRF24L01_INO
|
||||
#define HONTAI_NRF24L01_INO
|
||||
#define Q303_NRF24L01_INO
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user