Fixes #1035
This commit is contained in:
@@ -3973,8 +3973,7 @@ void perOut(uint8_t mode, uint8_t tick10ms)
|
|||||||
|
|
||||||
//========== CURVES ===============
|
//========== CURVES ===============
|
||||||
#if defined(PCBTARANIS)
|
#if defined(PCBTARANIS)
|
||||||
// TODO something cleaner ...
|
if (apply_offset_and_curve && md->curve.type != CURVE_REF_DIFF && md->curve.value) {
|
||||||
if (apply_offset_and_curve && md->curve.value) {
|
|
||||||
v = applyCurve(v, md->curve);
|
v = applyCurve(v, md->curve);
|
||||||
}
|
}
|
||||||
#else
|
#else
|
||||||
@@ -3994,8 +3993,12 @@ void perOut(uint8_t mode, uint8_t tick10ms)
|
|||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if !defined(PCBTARANIS) // TODO move before WEIGHT for readability
|
|
||||||
//========== DIFFERENTIAL =========
|
//========== DIFFERENTIAL =========
|
||||||
|
#if defined(PCBTARANIS)
|
||||||
|
if (md->curve.type == CURVE_REF_DIFF && md->curve.value) {
|
||||||
|
dv = applyCurve(dv, md->curve);
|
||||||
|
}
|
||||||
|
#else
|
||||||
if (md->curveMode == MODE_DIFFERENTIAL) {
|
if (md->curveMode == MODE_DIFFERENTIAL) {
|
||||||
// @@@2 also recalculate curveParam to a 256 basis which ease the calculation later a lot
|
// @@@2 also recalculate curveParam to a 256 basis which ease the calculation later a lot
|
||||||
int16_t curveParam = calc100to256(GET_GVAR(md->curveParam, -100, 100, s_perout_flight_phase));
|
int16_t curveParam = calc100to256(GET_GVAR(md->curveParam, -100, 100, s_perout_flight_phase));
|
||||||
|
|||||||
Reference in New Issue
Block a user