mirror of
https://github.com/betaflight/betaflight.git
synced 2025-07-18 22:05:17 +03:00
Change defaults // Cleanup debug
This commit is contained in:
parent
0ea5a99e2b
commit
893b45c518
3 changed files with 4 additions and 27 deletions
|
@ -128,7 +128,7 @@ static uint32_t activeFeaturesLatch = 0;
|
|||
static uint8_t currentControlRateProfileIndex = 0;
|
||||
controlRateConfig_t *currentControlRateProfile;
|
||||
|
||||
static const uint8_t EEPROM_CONF_VERSION = 106;
|
||||
static const uint8_t EEPROM_CONF_VERSION = 107;
|
||||
|
||||
static void resetAccelerometerTrims(flightDynamicsTrims_t *accelerometerTrims)
|
||||
{
|
||||
|
@ -390,13 +390,13 @@ static void resetConf(void)
|
|||
masterConfig.boardAlignment.pitchDegrees = 0;
|
||||
masterConfig.boardAlignment.yawDegrees = 0;
|
||||
masterConfig.acc_hardware = ACC_DEFAULT; // default/autodetect
|
||||
masterConfig.acc_for_fast_looptime = 0;
|
||||
masterConfig.acc_for_fast_looptime = 0; // FIXME - Needs to be removed through the code
|
||||
masterConfig.max_angle_inclination = 500; // 50 degrees
|
||||
masterConfig.yaw_control_direction = 1;
|
||||
masterConfig.gyroConfig.gyroMovementCalibrationThreshold = 32;
|
||||
|
||||
masterConfig.mag_hardware = MAG_DEFAULT; // default/autodetect
|
||||
masterConfig.baro_hardware = BARO_DEFAULT; // default/autodetect
|
||||
masterConfig.mag_hardware = 1; // default/autodetect
|
||||
masterConfig.baro_hardware = 1; // default/autodetect
|
||||
|
||||
resetBatteryConfig(&masterConfig.batteryConfig);
|
||||
|
||||
|
|
|
@ -461,7 +461,6 @@ const clivalue_t valueTable[] = {
|
|||
#endif
|
||||
|
||||
{ "acc_hardware", VAR_UINT8 | MASTER_VALUE, &masterConfig.acc_hardware, 0, ACC_MAX },
|
||||
{ "acc_for_fast_looptime", VAR_UINT8 | MASTER_VALUE, &masterConfig.acc_for_fast_looptime, 0, 1 },
|
||||
{ "acc_lpf_factor", VAR_UINT8 | PROFILE_VALUE, &masterConfig.profile[0].acc_lpf_factor, 0, 250 },
|
||||
{ "accxy_deadband", VAR_UINT8 | PROFILE_VALUE, &masterConfig.profile[0].accDeadband.xy, 0, 100 },
|
||||
{ "accz_deadband", VAR_UINT8 | PROFILE_VALUE, &masterConfig.profile[0].accDeadband.z, 0, 100 },
|
||||
|
|
|
@ -20,8 +20,6 @@
|
|||
#include <stdint.h>
|
||||
#include <math.h>
|
||||
|
||||
#include "debug.h"
|
||||
|
||||
#include "platform.h"
|
||||
|
||||
#include "common/maths.h"
|
||||
|
@ -82,8 +80,6 @@
|
|||
#include "config/config_profile.h"
|
||||
#include "config/config_master.h"
|
||||
|
||||
#define DEBUG_CYCLE_TIME
|
||||
|
||||
// June 2013 V2.2-dev
|
||||
|
||||
enum {
|
||||
|
@ -731,12 +727,6 @@ void loop(void)
|
|||
{
|
||||
static uint32_t loopTime;
|
||||
|
||||
#ifdef DEBUG_CYCLE_TIME
|
||||
static uint32_t minCycleTime = 0xffffffff;
|
||||
static uint32_t maxCycleTime = 0;
|
||||
static uint32_t clearTime = 0;
|
||||
#endif
|
||||
|
||||
#if defined(BARO) || defined(SONAR)
|
||||
static bool haveProcessedAnnexCodeOnce = false;
|
||||
#endif
|
||||
|
@ -792,18 +782,6 @@ void loop(void)
|
|||
previousTime = currentTime;
|
||||
|
||||
dT = (float)cycleTime * 0.000001f;
|
||||
#ifdef DEBUG_CYCLE_TIME
|
||||
if (currentTime > clearTime) {
|
||||
clearTime = currentTime + (uint32_t)20000000;
|
||||
minCycleTime = 0xffffffff;
|
||||
maxCycleTime = 0;
|
||||
}
|
||||
if (cycleTime < minCycleTime) minCycleTime = cycleTime;
|
||||
if (cycleTime > maxCycleTime) maxCycleTime = cycleTime;
|
||||
debug[0] = cycleTime;
|
||||
debug[1] = minCycleTime;
|
||||
debug[2] = maxCycleTime;
|
||||
#endif
|
||||
|
||||
filterApply7TapFIR(gyroADC);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue