mirror of
https://github.com/betaflight/betaflight.git
synced 2025-07-23 16:25:31 +03:00
Use spaces instead of tabs
This commit is contained in:
parent
c85a172370
commit
0ed47d5e6d
4 changed files with 1027 additions and 1027 deletions
File diff suppressed because it is too large
Load diff
|
@ -1,37 +1,37 @@
|
||||||
/*
|
/*
|
||||||
* This file is part of Cleanflight.
|
* This file is part of Cleanflight.
|
||||||
*
|
*
|
||||||
* Cleanflight is free software: you can redistribute it and/or modify
|
* Cleanflight is free software: you can redistribute it and/or modify
|
||||||
* it under the terms of the GNU General Public License as published by
|
* it under the terms of the GNU General Public License as published by
|
||||||
* the Free Software Foundation, either version 3 of the License, or
|
* the Free Software Foundation, either version 3 of the License, or
|
||||||
* (at your option) any later version.
|
* (at your option) any later version.
|
||||||
*
|
*
|
||||||
* Cleanflight is distributed in the hope that it will be useful,
|
* Cleanflight is distributed in the hope that it will be useful,
|
||||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
* GNU General Public License for more details.
|
* GNU General Public License for more details.
|
||||||
*
|
*
|
||||||
* You should have received a copy of the GNU General Public License
|
* You should have received a copy of the GNU General Public License
|
||||||
* along with Cleanflight. If not, see <http://www.gnu.org/licenses/>.
|
* along with Cleanflight. If not, see <http://www.gnu.org/licenses/>.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
#include <stdint.h>
|
#include <stdint.h>
|
||||||
|
|
||||||
typedef struct blackboxValues_t {
|
typedef struct blackboxValues_t {
|
||||||
uint32_t time;
|
uint32_t time;
|
||||||
|
|
||||||
int32_t axisP[3], axisI[3], axisD[3];
|
int32_t axisP[3], axisI[3], axisD[3];
|
||||||
|
|
||||||
int16_t rcCommand[4];
|
int16_t rcCommand[4];
|
||||||
int16_t gyroData[3];
|
int16_t gyroData[3];
|
||||||
int16_t accSmooth[3];
|
int16_t accSmooth[3];
|
||||||
int16_t motor[MAX_SUPPORTED_MOTORS];
|
int16_t motor[MAX_SUPPORTED_MOTORS];
|
||||||
int16_t servo[MAX_SUPPORTED_SERVOS];
|
int16_t servo[MAX_SUPPORTED_SERVOS];
|
||||||
} blackboxValues_t;
|
} blackboxValues_t;
|
||||||
|
|
||||||
void initBlackbox(void);
|
void initBlackbox(void);
|
||||||
void handleBlackbox(void);
|
void handleBlackbox(void);
|
||||||
void startBlackbox(void);
|
void startBlackbox(void);
|
||||||
void finishBlackbox(void);
|
void finishBlackbox(void);
|
||||||
|
|
|
@ -339,9 +339,9 @@ static void pidRewrite(pidProfile_t *pidProfile, controlRateConfig_t *controlRat
|
||||||
axisPID[axis] = PTerm + ITerm + DTerm;
|
axisPID[axis] = PTerm + ITerm + DTerm;
|
||||||
|
|
||||||
#ifdef BLACKBOX
|
#ifdef BLACKBOX
|
||||||
axisP[axis] = PTerm;
|
axisP[axis] = PTerm;
|
||||||
axisI[axis] = ITerm;
|
axisI[axis] = ITerm;
|
||||||
axisD[axis] = DTerm;
|
axisD[axis] = DTerm;
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -307,7 +307,7 @@ void mwDisarm(void)
|
||||||
|
|
||||||
#ifdef BLACKBOX
|
#ifdef BLACKBOX
|
||||||
if (feature(FEATURE_BLACKBOX)) {
|
if (feature(FEATURE_BLACKBOX)) {
|
||||||
finishBlackbox();
|
finishBlackbox();
|
||||||
if (isSerialPortFunctionShared(FUNCTION_BLACKBOX, FUNCTION_MSP)) {
|
if (isSerialPortFunctionShared(FUNCTION_BLACKBOX, FUNCTION_MSP)) {
|
||||||
mspAllocateSerialPorts(&masterConfig.serialConfig);
|
mspAllocateSerialPorts(&masterConfig.serialConfig);
|
||||||
}
|
}
|
||||||
|
@ -341,7 +341,7 @@ void mwArm(void)
|
||||||
if (sharedBlackboxAndMspPort) {
|
if (sharedBlackboxAndMspPort) {
|
||||||
mspReleasePortIfAllocated(sharedBlackboxAndMspPort);
|
mspReleasePortIfAllocated(sharedBlackboxAndMspPort);
|
||||||
}
|
}
|
||||||
startBlackbox();
|
startBlackbox();
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
return;
|
return;
|
||||||
|
@ -700,9 +700,9 @@ void loop(void)
|
||||||
writeMotors();
|
writeMotors();
|
||||||
|
|
||||||
#ifdef BLACKBOX
|
#ifdef BLACKBOX
|
||||||
if (!cliMode && feature(FEATURE_BLACKBOX)) {
|
if (!cliMode && feature(FEATURE_BLACKBOX)) {
|
||||||
handleBlackbox();
|
handleBlackbox();
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue