⚗️ Use pwm_set_duty over analogWrite to set PWM (#23048)

Co-authored-by: Scott Lahteine <thinkyhead@users.noreply.github.com>
This commit is contained in:
Andrei M
2021-11-02 01:47:16 -04:00
committed by GitHub
parent 767a15d468
commit da830e6ced
26 changed files with 159 additions and 126 deletions

View File

@@ -70,7 +70,7 @@ void CaseLight::update(const bool sflag) {
#if CASELIGHT_USES_BRIGHTNESS
if (pin_is_pwm())
analogWrite(pin_t(CASE_LIGHT_PIN), (
set_pwm_duty(pin_t(CASE_LIGHT_PIN), (
#if CASE_LIGHT_MAX_PWM == 255
n10ct
#else