PID works with max PWM of 255

This commit is contained in:
David P Hilton
2018-10-29 08:17:58 -06:00
parent 43d11fa8f8
commit 73f07489fe
3 changed files with 10 additions and 7 deletions

View File

@@ -9,11 +9,11 @@
#include <Settings.h>
#include <hardware.h>
history<uint16_t, 75> milliWattHistory = {{0}, 0, 0};
const uint8_t tipResistance = 87;
const uint8_t hz = 33;
const uint8_t maxPWM = 100;
const uint8_t maxPWM = 255;
history<uint16_t, oscillationPeriod> milliWattHistory = {{0}, 0, 0};
int32_t tempToMilliWatts(int32_t rawTemp, uint16_t mass, uint8_t rawC) {
// mass is in milliJ/*C, rawC is raw per degree C