At startup, wait until on/off button is released, to prevent entering auto-calibration after flashing

This commit is contained in:
Candas1 2021-01-27 22:45:57 +01:00
parent 1df6ecf773
commit d5d85c20ec
1 changed files with 2 additions and 0 deletions

View File

@ -199,6 +199,8 @@ int main(void) {
int16_t board_temp_adcFilt = adc_buffer.temp;
int16_t board_temp_deg_c;
// Loop until button is released
while(HAL_GPIO_ReadPin(BUTTON_PORT, BUTTON_PIN)) HAL_Delay(10);
while(1) {
HAL_Delay(DELAY_IN_MAIN_LOOP); // delay in ms