1
0
forked from me/IronOS

Retiming all the PWM's

This commit is contained in:
Ben V. Brown
2021-09-14 21:48:37 +10:00
parent 159ae7a8e2
commit a57449ed0f
8 changed files with 71 additions and 102 deletions

View File

@@ -246,11 +246,7 @@ uint16_t getInputVoltageX10(uint16_t divisor, uint8_t sample) {
}
return sum * 4 / divisor;
}
bool tryBetterPWM(uint8_t pwm) {
// We dont need this for the MHP30
return false;
}
void setTipPWM(uint8_t pulse) {
void setTipPWM(const uint8_t pulse, const bool shouldUseFastModePWM) {
// We can just set the timer directly
if (htim3.Instance->PSC > 20) {
htim3.Instance->CCR1 = 0;