@@ -74,49 +74,49 @@ int main(void)
set.temp_units = TEMP_UNITS_CELSIUS;
set.windup_guard = 1;
set.k_p = 1;
set.k_i = 1;
set.k_d = 1;
set.ignore_tc_error = 0;
set.setpoint_brew = 0;
set.setpoint_steam = 0;
// Default status
status.temp = 0;
status.temp_frac = 0;
status.state_resume = 0;
status.state = STATE_IDLE;
status.setpoint = 0;
status.pid_enabled = 0;
// Load settings (if any) from EEPROM
restore_settings();
if(set.boottobrew)
status.state = STATE_PREHEAT_BREW; // Go to brew instead of idle if configured thusly
// Startup screen
ssd1306_DrawString("therm v0.1", 1, 40);
ssd1306_DrawString("therm v0.2", 1, 40);
ssd1306_DrawString("protofusion.org/therm", 3, 0);
HAL_Delay(1500);
ssd1306_clearscreen();
// Main loop
while(1)
{
// Process sensor inputs
process();
// Run state machine
display_process(&set, &status);
}
/** System Clock Configuration
*/
void SystemClock_Config(void)
RCC_OscInitTypeDef RCC_OscInitStruct;
RCC_ClkInitTypeDef RCC_ClkInitStruct;
Status change: