[X7] Pots calibration fix - #4143

This commit is contained in:
Bertrand Songis
2016-12-19 17:52:16 +01:00
parent 880216c544
commit d52f89674c
8 changed files with 33 additions and 28 deletions
+1 -1
View File
@@ -45,7 +45,7 @@ void drawPotsBars()
{
// Optimization by Mike Blandford
for (uint8_t x=LCD_W/2 - (NUM_POTS+NUM_SLIDERS-1) * 5 / 2, i=NUM_STICKS; i<NUM_STICKS+NUM_POTS+NUM_SLIDERS; x+=5, i++) {
if (IS_POT_OR_SLIDER_AVAILABLE(i)) {
if (IS_POT_SLIDER_AVAILABLE(i)) {
uint8_t len = ((calibratedStick[i]+RESX)*BAR_HEIGHT/(RESX*2))+1l; // calculate once per loop
V_BAR(x, LCD_H-8, len);
}