Merge pull request #2418 from mikeller/fix_inconsistent_mess
Fixed inconsistent conditionals in targets.
This commit is contained in:
commit
f0e80f5a77
|
@ -36,6 +36,7 @@
|
|||
|
||||
#define BRUSHED_MOTORS_PWM_RATE 32000 // 32kHz
|
||||
|
||||
#ifdef TARGET_CONFIG
|
||||
// alternative defaults settings for AlienFlight targets
|
||||
void targetConfiguration(master_t *config)
|
||||
{
|
||||
|
@ -62,3 +63,4 @@ void targetConfiguration(master_t *config)
|
|||
config->customMotorMixer[6] = (motorMixer_t){ 1.0f, -1.0f, 0.414178f, 1.0f }; // MIDREAR_R
|
||||
config->customMotorMixer[7] = (motorMixer_t){ 1.0f, 1.0f, 0.414178f, -1.0f }; // MIDREAR_L
|
||||
}
|
||||
#endif
|
||||
|
|
|
@ -46,6 +46,7 @@
|
|||
|
||||
#define BRUSHED_MOTORS_PWM_RATE 32000 // 32kHz
|
||||
|
||||
#ifdef TARGET_CONFIG
|
||||
// alternative defaults settings for AlienFlight targets
|
||||
void targetConfiguration(master_t *config)
|
||||
{
|
||||
|
@ -105,3 +106,4 @@ void targetConfiguration(master_t *config)
|
|||
config->customMotorMixer[6] = (motorMixer_t){ 1.0f, -1.0f, 0.414178f, 1.0f }; // MIDREAR_R
|
||||
config->customMotorMixer[7] = (motorMixer_t){ 1.0f, 1.0f, 0.414178f, -1.0f }; // MIDREAR_L
|
||||
}
|
||||
#endif
|
||||
|
|
|
@ -54,6 +54,7 @@
|
|||
|
||||
#define BRUSHED_MOTORS_PWM_RATE 32000 // 32kHz
|
||||
|
||||
#ifdef TARGET_CONFIG
|
||||
// alternative defaults settings for AlienFlight targets
|
||||
void targetConfiguration(master_t *config)
|
||||
{
|
||||
|
@ -96,3 +97,4 @@ void targetConfiguration(master_t *config)
|
|||
config->customMotorMixer[6] = (motorMixer_t){ 1.0f, -1.0f, 0.414178f, 1.0f }; // MIDREAR_R
|
||||
config->customMotorMixer[7] = (motorMixer_t){ 1.0f, 1.0f, 0.414178f, -1.0f }; // MIDREAR_L
|
||||
}
|
||||
#endif
|
||||
|
|
|
@ -35,10 +35,11 @@
|
|||
#include "config/config_profile.h"
|
||||
#include "config/config_master.h"
|
||||
|
||||
#ifdef TARGET_CONFIG
|
||||
void targetConfiguration(master_t *config)
|
||||
{
|
||||
UNUSED(config);
|
||||
|
||||
batteryConfig->currentMeterScale = 235;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
|
|
@ -29,6 +29,7 @@
|
|||
|
||||
#include "hardware_revision.h"
|
||||
|
||||
#ifdef TARGET_CONFIG
|
||||
// alternative defaults settings for BlueJayF4 targets
|
||||
void targetConfiguration(master_t *config)
|
||||
{
|
||||
|
@ -58,3 +59,4 @@ void targetValidateConfiguration(master_t *config)
|
|||
}
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
|
|
@ -35,7 +35,7 @@
|
|||
#include "config/config_profile.h"
|
||||
#include "config/config_master.h"
|
||||
|
||||
|
||||
#ifdef TARGET_CONFIG
|
||||
// alternative defaults settings for Colibri/Gemini targets
|
||||
void targetConfiguration(master_t *config)
|
||||
{
|
||||
|
@ -54,3 +54,4 @@ void targetConfiguration(master_t *config)
|
|||
config->profile[0].controlRateProfile[0].tpa_breakpoint = 1700;
|
||||
config->serialConfig.portConfigs[2].functionMask = FUNCTION_RX_SERIAL;
|
||||
}
|
||||
#endif
|
||||
|
|
|
@ -29,6 +29,7 @@
|
|||
#include "config/feature.h"
|
||||
#include "io/ledstrip.h"
|
||||
|
||||
#ifdef TARGET_CONFIG
|
||||
void targetApplyDefaultLedStripConfig(ledConfig_t *ledConfigs)
|
||||
{
|
||||
const ledConfig_t defaultLedStripConfig[] = {
|
||||
|
@ -95,5 +96,5 @@ void targetConfiguration(master_t *config)
|
|||
config->profile[0].controlRateProfile[0].rates[FD_YAW] = 80;
|
||||
|
||||
targetApplyDefaultLedStripConfig(config->ledStripConfig.ledConfigs);
|
||||
|
||||
}
|
||||
#endif
|
||||
|
|
|
@ -37,7 +37,7 @@
|
|||
|
||||
#include "sensors/boardalignment.h"
|
||||
|
||||
|
||||
#ifdef TARGET_CONFIG
|
||||
void targetConfiguration(master_t *config)
|
||||
{
|
||||
UNUSED(config);
|
||||
|
@ -49,4 +49,4 @@ void targetConfiguration(master_t *config)
|
|||
config->boardAlignment.yawDegrees = 0;
|
||||
#endif
|
||||
}
|
||||
|
||||
#endif
|
||||
|
|
|
@ -22,10 +22,11 @@
|
|||
|
||||
#include "config/config_master.h"
|
||||
|
||||
|
||||
#ifdef TARGET_CONFIG
|
||||
// Motolab target supports 2 different type of boards Tornado / Cyclone.
|
||||
void targetConfiguration(master_t *config)
|
||||
{
|
||||
config->gyroConfig.gyro_sync_denom = 4;
|
||||
config->pidConfig.pid_process_denom = 1;
|
||||
}
|
||||
#endif
|
||||
|
|
|
@ -39,6 +39,7 @@
|
|||
#include "config/config_profile.h"
|
||||
#include "config/config_master.h"
|
||||
|
||||
#ifdef TARGET_CONFIG
|
||||
// alternative defaults settings for MULTIFLITEPICO targets
|
||||
void targetConfiguration(master_t *config)
|
||||
{
|
||||
|
@ -83,5 +84,5 @@ void targetConfiguration(master_t *config)
|
|||
|
||||
config->profile[0].controlRateProfile[0].rcRate8 = 70;
|
||||
config->profile[0].pidProfile.I8[PIDLEVEL] = 40;
|
||||
|
||||
}
|
||||
#endif
|
||||
|
|
|
@ -37,6 +37,7 @@
|
|||
|
||||
#include "hardware_revision.h"
|
||||
|
||||
#ifdef TARGET_CONFIG
|
||||
void targetConfiguration(master_t *config)
|
||||
{
|
||||
UNUSED(config);
|
||||
|
@ -97,4 +98,4 @@ void targetConfiguration(master_t *config)
|
|||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
#endif
|
||||
|
|
|
@ -21,6 +21,8 @@
|
|||
|
||||
#include "config/config_master.h"
|
||||
|
||||
#ifdef TARGET_CONFIG
|
||||
void targetConfiguration(master_t *config) {
|
||||
config->batteryConfig.currentMeterScale = 125;
|
||||
}
|
||||
#endif
|
||||
|
|
|
@ -24,7 +24,7 @@
|
|||
|
||||
#include "config/config_master.h"
|
||||
|
||||
|
||||
#ifdef TARGET_CONFIG
|
||||
// alternative defaults settings for COLIBRI RACE targets
|
||||
void targetConfiguration(master_t *config)
|
||||
{
|
||||
|
@ -32,3 +32,4 @@ void targetConfiguration(master_t *config)
|
|||
config->rxConfig.rssi_scale = 19;
|
||||
config->rxConfig.serialrx_provider = SERIALRX_SBUS;
|
||||
}
|
||||
#endif
|
||||
|
|
|
@ -21,7 +21,9 @@
|
|||
|
||||
#include "config/config_master.h"
|
||||
|
||||
#ifdef TARGET_CONFIG
|
||||
void targetConfiguration(master_t *config) {
|
||||
config->batteryConfig.vbatmaxcellvoltage = 45;
|
||||
config->batteryConfig.currentMeterScale = 119;
|
||||
}
|
||||
#endif
|
||||
|
|
|
@ -19,11 +19,9 @@
|
|||
#include "config/config_master.h"
|
||||
|
||||
#ifdef TARGET_CONFIG
|
||||
|
||||
void targetConfiguration(master_t *config)
|
||||
{
|
||||
// Temporary workaround: Disable SDCard DMA by default since it causes errors on this target
|
||||
config->sdcardConfig.useDma = false;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
|
|
@ -33,6 +33,7 @@
|
|||
|
||||
#define TARGET_CPU_VOLTAGE 3.0
|
||||
|
||||
#ifdef TARGET_CONFIG
|
||||
// set default settings to match our target
|
||||
void targetConfiguration(master_t *config)
|
||||
{
|
||||
|
@ -53,4 +54,4 @@ void targetConfiguration(master_t *config)
|
|||
|
||||
intFeatureSet(FEATURE_CURRENT_METER | FEATURE_VBAT, &config->enabledFeatures);
|
||||
}
|
||||
|
||||
#endif
|
||||
|
|
Loading…
Reference in New Issue