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

Fixed unit tests using 'ledstrip.c'.

This commit is contained in:
mikeller 2019-01-21 00:58:43 +13:00
parent bdf179c4b8
commit 18496fe745
3 changed files with 4 additions and 4 deletions

View file

@ -286,7 +286,7 @@ void init(void)
targetPreInit();
#endif
#if !defined(UNIT_TEST) && !defined(USE_FAKE_LED)
#if !defined(USE_FAKE_LED)
ledInit(statusLedConfig());
#endif
LED2_ON;

View file

@ -679,11 +679,9 @@ static uint8_t applySelectAdjustment(adjustmentFunction_e adjustmentFunction, ui
break;
case ADJUSTMENT_LED_PROFILE:
#ifdef USE_LED_STRIP
#ifndef UNIT_TEST
if (getLedProfile() != position) {
setLedProfile(position);
}
#endif
#endif
break;

View file

@ -739,9 +739,11 @@ PG_REGISTER(blackboxConfig_t, blackboxConfig, PG_BLACKBOX_CONFIG, 0);
PG_REGISTER(systemConfig_t, systemConfig, PG_SYSTEM_CONFIG, 2);
void resetArmingDisabled(void) {}
timeDelta_t getTaskDeltaTime(cfTaskId_e) { return 20000; }
}
armingDisableFlags_e getArmingDisableFlags(void) {
return (armingDisableFlags_e) 0;
}
bool isTryingToArm(void) { return false; }
void resetTryingToArm(void) {}
void setLedProfile(uint8_t profile) { UNUSED(profile); }
uint8_t getLedProfile(void) { return 0; }
}