Skip to content

Commit

Permalink
Replaced deleted code
Browse files Browse the repository at this point in the history
  • Loading branch information
HoverClub committed Feb 25, 2022
1 parent 91b5087 commit 95a4e90
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions Marlin/src/HAL/ESP32/HAL.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -338,6 +338,8 @@ void analogWrite(const pin_t pin, const uint16_t value, const uint32_t freq/*=PW
// Start timer on first use
if (idx == 0) HAL_timer_start(MF_TIMER_PWM, PWM_TIMER_FREQUENCY);

// Use 7bit internal value - add 1 to have 100% high at 255
pwmValues[idx] = (value + 1) / 2;
++numPWMUsed;
}
}
Expand Down

0 comments on commit 95a4e90

Please sign in to comment.