Skip to content

Commit

Permalink
Another attempt
Browse files Browse the repository at this point in the history
  • Loading branch information
pascallanger committed Sep 7, 2021
1 parent 32bd39f commit bf09855
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 11 deletions.
7 changes: 4 additions & 3 deletions Multiprotocol/Multiprotocol.ino
Original file line number Diff line number Diff line change
Expand Up @@ -1134,7 +1134,6 @@ static void protocol_init()
if(IS_WAIT_BIND_off)
{
remote_callback = 0; // No protocol
modules_reset(); // Reset all modules
LED_off; // Led off during protocol init
crc16_polynomial = 0x1021; // Default CRC crc16_polynomial
crc8_polynomial = 0x31; // Default CRC crc8_polynomial
Expand Down Expand Up @@ -1196,6 +1195,9 @@ static void protocol_init()
debugln("Protocol selected: %d, sub proto %d, rxnum %d, option %d", protocol, sub_protocol, RX_num, option);
if(protocol)
{
//Reset all modules
modules_reset();

uint8_t index=0;
#if defined(FRSKYX_CC2500_INO) && defined(EU_MODULE)
if( ! ( (protocol == PROTO_FRSKYX || protocol == PROTO_FRSKYX2) && sub_protocol < 2 ) )
Expand Down Expand Up @@ -1249,8 +1251,7 @@ static void protocol_init()
}
#endif
}



#if defined(WAIT_FOR_BIND) && defined(ENABLE_BIND_CH)
if( IS_AUTOBIND_FLAG_on && IS_BIND_CH_PREV_off && (cur_protocol[1]&0x80)==0 && mode_select == MODE_SERIAL)
{ // Autobind is active but no bind requested by either BIND_CH or BIND. But do not wait if in PPM mode...
Expand Down
4 changes: 2 additions & 2 deletions Multiprotocol/_Config.h
Original file line number Diff line number Diff line change
Expand Up @@ -220,7 +220,7 @@
#define BAYANG_RX_NRF24L01_INO
#define BUGSMINI_NRF24L01_INO
#define CABELL_NRF24L01_INO
#define CFLIE_NRF24L01_INO
//#define CFLIE_NRF24L01_INO
#define CG023_NRF24L01_INO
#define CX10_NRF24L01_INO //Include Q2X2 protocol
#define DM002_NRF24L01_INO
Expand All @@ -238,7 +238,7 @@
#define JJRC345_NRF24L01_INO
#define KN_NRF24L01_INO
#define LOLI_NRF24L01_INO
#define MOULDKG_NRF24L01_INO
//#define MOULDKG_NRF24L01_INO
#define NCC1701_NRF24L01_INO
#define POTENSIC_NRF24L01_INO
#define PROPEL_NRF24L01_INO
Expand Down
6 changes: 3 additions & 3 deletions buildroot/bin/build_release_stm32f1_no_debug
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ exitcode=0;

# Builds for the DIY 5-in-1 module exceed the 120KB working capacity of the STM32F103CB
# To work around this we have to disable some protocols in the builds for this module
DIY_5IN1_DISABLED="MOULDKG_NRF24L01_INO IKEAANSLUTA_CC2500_INO";
#DIY_5IN1_DISABLED="MOULDKG_NRF24L01_INO";

# Generic 4-in-1 builds
printf "\e[33;1mBuilding mm-stm-serial-aetr-v$MULTI_VERSION.bin\e[0m\n";
Expand All @@ -29,7 +29,7 @@ mv build/Multiprotocol.ino.bin ./binaries/mm-stm-serial-reta-v$MULTI_VERSION.bin
# DIY 5-in-1 builds
printf "\e[33;1mBuilding mm-stm-5in1-aetr-v$MULTI_VERSION.bin\e[0m\n";
opt_replace RETA AETR;
opt_disable $DIY_5IN1_DISABLED;
#opt_disable $DIY_5IN1_DISABLED;
opt_enable SX1276_INSTALLED;
buildMulti;
exitcode=$((exitcode+$?));
Expand All @@ -52,7 +52,7 @@ printf "\e[33;1mBuilding mm-tlite5in1-aetr-v$MULTI_VERSION.bin\e[0m\n";
opt_replace RETA AETR;
opt_disable INVERT_TELEMETRY;
opt_disable SX1276_INSTALLED;
opt_enable $DIY_5IN1_DISABLED;
#opt_enable $DIY_5IN1_DISABLED;
opt_enable "MULTI_5IN1_INTERNAL JP_TLite"
buildMulti;
exitcode=$((exitcode+$?));
Expand Down
3 changes: 0 additions & 3 deletions buildroot/bin/build_release_stm32f1_t18int
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,9 @@
source ./buildroot/bin/buildFunctions;
exitcode=0;

T18_DISABLED="MOULDKG_NRF24L01_INO IKEAANSLUTA_CC2500_INO";

printf "\e[33;1mBuilding mm-t18int-aetr-v$MULTI_VERSION.bin\e[0m\n";
opt_disable ENABLE_PPM;
opt_disable INVERT_TELEMETRY;
opt_disable $T18_DISABLED;
buildMulti;
exitcode=$((exitcode+$?));
mv build/Multiprotocol.ino.bin ./binaries/mm-t18int-aetr-v$MULTI_VERSION.bin;
Expand Down

0 comments on commit bf09855

Please sign in to comment.