Revert change and use a specific config for YUPIF7
This commit is contained in:
parent
765274699f
commit
ec9a713c2f
|
@ -73,7 +73,7 @@ static void alignBoard(float *vec)
|
|||
vec[Z] = (boardRotation[0][Z] * x + boardRotation[1][Z] * y + boardRotation[2][Z] * z);
|
||||
}
|
||||
|
||||
void alignSensors(float *dest, uint8_t rotation)
|
||||
FAST_CODE void alignSensors(float *dest, uint8_t rotation)
|
||||
{
|
||||
const float x = dest[X];
|
||||
const float y = dest[Y];
|
||||
|
|
|
@ -26,24 +26,13 @@
|
|||
#ifdef USE_TARGET_CONFIG
|
||||
#include "fc/config.h"
|
||||
|
||||
#include "flight/pid.h"
|
||||
#include "sensors/boardalignment.h"
|
||||
|
||||
|
||||
// alternative defaults settings for YuPiF4 targets
|
||||
void targetConfiguration(void)
|
||||
{
|
||||
/* Specific PID values for YupiF4 */
|
||||
for (uint8_t pidProfileIndex = 0; pidProfileIndex < MAX_PROFILE_COUNT; pidProfileIndex++) {
|
||||
pidProfile_t *pidProfile = pidProfilesMutable(pidProfileIndex);
|
||||
|
||||
pidProfile->pid[PID_ROLL].P = 30;
|
||||
pidProfile->pid[PID_ROLL].I = 45;
|
||||
pidProfile->pid[PID_ROLL].D = 20;
|
||||
pidProfile->pid[PID_PITCH].P = 30;
|
||||
pidProfile->pid[PID_PITCH].I = 50;
|
||||
pidProfile->pid[PID_PITCH].D = 20;
|
||||
pidProfile->pid[PID_YAW].P = 40;
|
||||
pidProfile->pid[PID_YAW].I = 50;
|
||||
}
|
||||
boardAlignmentMutable()->yawDegrees = 90;
|
||||
}
|
||||
#endif
|
||||
|
||||
|
|
|
@ -20,6 +20,7 @@
|
|||
|
||||
#pragma once
|
||||
#define TARGET_BOARD_IDENTIFIER "YPF7"
|
||||
#define USE_TARGET_CONFIG
|
||||
|
||||
#define USBD_PRODUCT_STRING "YUPIF7"
|
||||
|
||||
|
|
Loading…
Reference in New Issue