1
0
Fork 0
mirror of https://github.com/betaflight/betaflight.git synced 2025-07-19 14:25:20 +03:00

Relocate some structures and code to the right places.

This cleans up the include file order somewhat and fixes a couple of
dependencies.

The goal of this is to rename flight.c/flight.h to pid.c/pid.h.
This commit is contained in:
Dominic Clifton 2015-01-31 23:47:51 +01:00
parent a9b2c39872
commit 53406a7ac7
20 changed files with 198 additions and 145 deletions

View file

@ -26,11 +26,8 @@
#include <platform.h>
#include "common/axis.h"
#include "flight/flight.h"
#include "drivers/system.h"
#include "drivers/sensor.h"
#include "drivers/accgyro.h"
#include "drivers/compass.h"
@ -42,14 +39,16 @@
#include "sensors/barometer.h"
#include "sensors/sonar.h"
#include "flight/mixer.h"
#include "flight/flight.h"
#include "flight/imu.h"
#include "config/runtime_config.h"
#include "flight/mixer.h"
#include "flight/imu.h"
extern int16_t debug[4];
int16_t gyroADC[XYZ_AXIS_COUNT], accADC[XYZ_AXIS_COUNT], accSmooth[XYZ_AXIS_COUNT];
int16_t gyroADC[XYZ_AXIS_COUNT], accSmooth[XYZ_AXIS_COUNT];
int32_t accSum[XYZ_AXIS_COUNT];
uint32_t accTimeSum = 0; // keep track for integration of acc
@ -311,7 +310,7 @@ void imuUpdate(rollAndPitchTrims_t *accelerometerTrims, uint8_t mixerMode)
gyroUpdate();
if (sensors(SENSOR_ACC)) {
updateAccelerationReadings(accelerometerTrims);
updateAccelerationReadings(accelerometerTrims); // TODO rename to accelerometerUpdate and rename many other 'Acceleration' references to be 'Accelerometer'
imuCalculateEstimatedAttitude();
} else {
accADC[X] = 0;