You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have an ESP-WROOM-32 DEV KIT 1 with RX2 and TX2 (Serial2) connected to a MAX3380 RS232 Transceiver.
Hardware Configuration
Nothing else attached to the board.
Version
v3.0.7
IDE Name
Arduino IDE 2.3.3
Operating System
macOS 13.7.1
Flash frequency
80Mhz
PSRAM enabled
yes
Upload speed
921600
Description
#10172 corrects a problem with baud rates above 250K by setting the proper clock source. This functionality only works in Serial.begin() and does not work in Serial.updateBaudRate().
If Serial.begin() is invoked with a baud rate under 250K, the source clock is set to UART_SCLK_REF_TICK, otherwise the source clock is set to UART_SCLK_APB.
If the source clock is set to UART_SCLK_REF_TICK during Serial.begin(), updating the baud rate with Serial.updateBaudRate() to one that requires UART_SCLK_APB will not work because the source clock isn't change.
Sketch
Serial2.begin(230400);
Serial.printf("%d\n", Serial2.baudRate());
// Clock is now UART_SCLK_REF_TICK
Serial2.updateBaudRate(460800);
Serial.printf("%d\n", Serial2.baudRate());
// Clock is still UART_SCLK_REF_TICK
Serial2.end();
Serial2.begin(460800);
Serial.printf("%d\n", Serial2.baudRate());
// Clock is now UART_SCLK_APB
Debug Message
I do not have any debug output as I do not know how to access the current UART source clock setting from the Serial API. I just know Serial2.baudRate() returns baud rates based on the initial `Serial2.begin()` source clock setting.
Other Steps to Reproduce
No response
I have checked existing issues, online documentation and the Troubleshooting Guide
I confirm I have checked existing issues, online documentation and Troubleshooting guide.
The text was updated successfully, but these errors were encountered:
Board
ESP-WROOM-32
Device Description
I have an ESP-WROOM-32 DEV KIT 1 with RX2 and TX2 (Serial2) connected to a MAX3380 RS232 Transceiver.
Hardware Configuration
Nothing else attached to the board.
Version
v3.0.7
IDE Name
Arduino IDE 2.3.3
Operating System
macOS 13.7.1
Flash frequency
80Mhz
PSRAM enabled
yes
Upload speed
921600
Description
#10172 corrects a problem with baud rates above 250K by setting the proper clock source. This functionality only works in
Serial.begin()
and does not work inSerial.updateBaudRate()
.If
Serial.begin()
is invoked with a baud rate under 250K, the source clock is set toUART_SCLK_REF_TICK
, otherwise the source clock is set toUART_SCLK_APB
.If the source clock is set to
UART_SCLK_REF_TICK
duringSerial.begin()
, updating the baud rate withSerial.updateBaudRate()
to one that requiresUART_SCLK_APB
will not work because the source clock isn't change.Sketch
Debug Message
Other Steps to Reproduce
No response
I have checked existing issues, online documentation and the Troubleshooting Guide
The text was updated successfully, but these errors were encountered: