mirror of
https://github.com/betaflight/betaflight.git
synced 2025-07-24 00:35:39 +03:00
Merge branch 'development' of https://github.com/borisbstyle/betaflight into fix_naze_beeper
This commit is contained in:
commit
b441465776
69 changed files with 2606 additions and 195 deletions
|
@ -55,6 +55,7 @@
|
|||
#include "drivers/transponder_ir.h"
|
||||
#include "drivers/io.h"
|
||||
#include "drivers/exti.h"
|
||||
#include "drivers/vtx_soft_spi_rtc6705.h"
|
||||
|
||||
#ifdef USE_BST
|
||||
#include "bus_bst.h"
|
||||
|
@ -73,6 +74,7 @@
|
|||
#include "io/display.h"
|
||||
#include "io/asyncfatfs/asyncfatfs.h"
|
||||
#include "io/transponder_ir.h"
|
||||
#include "io/osd.h"
|
||||
#include "io/vtx.h"
|
||||
|
||||
#include "scheduler/scheduler.h"
|
||||
|
@ -137,6 +139,7 @@ void ledStripInit(ledConfig_t *ledConfigsToUse, hsvColor_t *colorsToUse);
|
|||
void spektrumBind(rxConfig_t *rxConfig);
|
||||
const sonarHardware_t *sonarGetHardwareConfiguration(batteryConfig_t *batteryConfig);
|
||||
void sonarInit(const sonarHardware_t *sonarHardware);
|
||||
void osdInit(void);
|
||||
|
||||
typedef enum {
|
||||
SYSTEM_STATE_INITIALISING = 0,
|
||||
|
@ -195,7 +198,7 @@ void init(void)
|
|||
EXTIInit();
|
||||
#endif
|
||||
|
||||
#ifdef SPRACINGF3MINI
|
||||
#if defined(SPRACINGF3MINI) || defined(OMNIBUS)
|
||||
gpio_config_t buttonAGpioConfig = {
|
||||
BUTTON_A_PIN,
|
||||
Mode_IPU,
|
||||
|
@ -414,11 +417,13 @@ void init(void)
|
|||
}
|
||||
#endif
|
||||
|
||||
#if defined(SPRACINGF3MINI) && defined(SONAR) && defined(USE_SOFTSERIAL1)
|
||||
#if defined(SPRACINGF3MINI) || defined(OMNIBUS)
|
||||
#if defined(SONAR) && defined(USE_SOFTSERIAL1)
|
||||
if (feature(FEATURE_SONAR) && feature(FEATURE_SOFTSERIAL)) {
|
||||
serialRemovePort(SERIAL_PORT_SOFTSERIAL1);
|
||||
}
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#ifdef USE_I2C
|
||||
#if defined(NAZE)
|
||||
|
@ -465,6 +470,21 @@ void init(void)
|
|||
}
|
||||
#endif
|
||||
|
||||
#ifdef USE_RTC6705
|
||||
if (feature(FEATURE_VTX)) {
|
||||
rtc6705_soft_spi_init();
|
||||
current_vtx_channel = masterConfig.vtx_channel;
|
||||
rtc6705_soft_spi_set_channel(vtx_freq[current_vtx_channel]);
|
||||
rtc6705_soft_spi_set_rf_power(masterConfig.vtx_power);
|
||||
}
|
||||
#endif
|
||||
|
||||
#ifdef OSD
|
||||
if (feature(FEATURE_OSD)) {
|
||||
osdInit();
|
||||
}
|
||||
#endif
|
||||
|
||||
if (!sensorsAutodetect(&masterConfig.sensorAlignmentConfig,
|
||||
masterConfig.acc_hardware,
|
||||
masterConfig.mag_hardware,
|
||||
|
@ -735,6 +755,9 @@ void main_init(void)
|
|||
#ifdef TRANSPONDER
|
||||
setTaskEnabled(TASK_TRANSPONDER, feature(FEATURE_TRANSPONDER));
|
||||
#endif
|
||||
#ifdef OSD
|
||||
setTaskEnabled(TASK_OSD, feature(FEATURE_OSD));
|
||||
#endif
|
||||
#ifdef USE_BST
|
||||
setTaskEnabled(TASK_BST_MASTER_PROCESS, true);
|
||||
#endif
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue