Skip to content

Commit 612149e

Browse files
committed
stress/fuzzing testing
1 parent 3d82a64 commit 612149e

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

cores/esp32/esp32-hal-uart.c

+4-3
Original file line numberDiff line numberDiff line change
@@ -718,8 +718,8 @@ void uartStartDetectBaudrate(uart_t *uart) {
718718
#elif CONFIG_IDF_TARGET_ESP32S3
719719
// log_v("Start Init HW for baud detection");
720720
uart_dev_t *hw = UART_LL_GET_HW(uart->num);
721-
hw->rx_filt.glitch_filt = 1;
722-
hw->rx_filt.glitch_filt_en = 1;
721+
hw->rx_filt.glitch_filt = 0;
722+
hw->rx_filt.glitch_filt_en = 0;
723723
hw->conf0.autobaud_en = 0;
724724
hw->conf0.autobaud_en = 1;
725725
// log_v("End Init HW for baud detection");
@@ -778,7 +778,6 @@ uartDetectBaudrate(uart_t *uart)
778778
// log_v("Divisor: %d", divisor);
779779
// log_v("Divider: %d", div16);
780780

781-
782781
baudrate = sclk_freq / (divisor * 2);
783782

784783
// switch(clk_src)
@@ -828,6 +827,8 @@ uartDetectBaudrate(uart_t *uart)
828827
}
829828
}
830829

830+
log_v("Rounded %d to %d (b: %d) (n: %d)", baudrate, default_rates[i], default_rates[i-1], default_rates[i+1]); //THIS WILL OVERFLOW, only for testing now
831+
831832
return default_rates[i];
832833
#else
833834
#ifdef CONFIG_IDF_TARGET_ESP32C3

0 commit comments

Comments
 (0)