diff --git a/main.c b/main.c --- a/main.c +++ b/main.c @@ -6,6 +6,7 @@ #include "states.h" #include "ssd1306.h" #include "max31855.h" +#include "max31865.h" #include "gpio.h" #include "spi.h" #include "flash.h" @@ -47,6 +48,10 @@ int main(void) // Init SPI busses spi_init(); + + #ifdef MAX31865_RTD_SENSOR + max31865_config(spi_get()); + #endif // Init OLED over SPI ssd1306_init(); @@ -59,7 +64,7 @@ int main(void) set.val.k_p = 10; set.val.k_i = 1; set.val.k_d = 1; - set.val.ignore_tc_error = 0; + set.val.ignore_error = 0; set.val.setpoint_brew = 70; set.val.setpoint_steam = 70; @@ -111,7 +116,7 @@ int main(void) #endif #ifdef MAX31865_RTD_SENSOR - max31865_readtemp(&set, &status); + max31865_readtemp(spi_get(), &set, &status); #endif