Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 5492733

Browse filesBrowse files
authored
feat (uart): uses the same IDF 32bits size for TX/RX buffers (espressif#9561)
* feat (uart): uses the same IDF 32bits size for TX/RX buffers Uses the same IDF 32bits size for TX/RX buffers. Changed header files to use the same IDF buffer limits. * this is a backport from PR espressif#9554 * feat (uart): change UART events logs to Verbose UART events like BREAK or errors are now Verbose instead of Warning Level. Backporting change from Issue espressif#9551 * feat (uart): uses the same IDF 32bits size for TX/RX buffers. Uses the same IDF 32bits size for TX/RX buffers. Changed header files to use the same IDF buffer limits. * this is a backport from PR espressif#9554 * feat (uart): keep overflow log as warning Keeps Overflow / Buffer Full log messages in Warning Level.
1 parent 58962d2 commit 5492733
Copy full SHA for 5492733

File tree

3 files changed

+8
-8
lines changed
Filter options

3 files changed

+8
-8
lines changed

‎cores/esp32/HardwareSerial.cpp

Copy file name to clipboardExpand all lines: cores/esp32/HardwareSerial.cpp
+4-4Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -244,19 +244,19 @@ void HardwareSerial::_uartEventTask(void *args)
244244
currentErr = UART_BUFFER_FULL_ERROR;
245245
break;
246246
case UART_BREAK:
247-
log_w("UART%d RX break.", uart->_uart_nr);
247+
log_v("UART%d RX break.", uart->_uart_nr);
248248
currentErr = UART_BREAK_ERROR;
249249
break;
250250
case UART_PARITY_ERR:
251-
log_w("UART%d parity error.", uart->_uart_nr);
251+
log_v("UART%d parity error.", uart->_uart_nr);
252252
currentErr = UART_PARITY_ERROR;
253253
break;
254254
case UART_FRAME_ERR:
255-
log_w("UART%d frame error.", uart->_uart_nr);
255+
log_v("UART%d frame error.", uart->_uart_nr);
256256
currentErr = UART_FRAME_ERROR;
257257
break;
258258
default:
259-
log_w("UART%d unknown event type %d.", uart->_uart_nr, event.type);
259+
log_v("UART%d unknown event type %d.", uart->_uart_nr, event.type);
260260
break;
261261
}
262262
if (currentErr != UART_NO_ERROR) {

‎cores/esp32/esp32-hal-uart.c

Copy file name to clipboardExpand all lines: cores/esp32/esp32-hal-uart.c
+2-2Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -301,7 +301,7 @@ bool uartSetHwFlowCtrlMode(uart_t *uart, uart_hw_flowcontrol_t mode, uint8_t thr
301301
}
302302

303303
// This helper function will return true if a new IDF UART driver needs to be restarted and false if the current one can continue its execution
304-
bool _testUartBegin(uint8_t uart_nr, uint32_t baudrate, uint32_t config, int8_t rxPin, int8_t txPin, uint16_t rx_buffer_size, uint16_t tx_buffer_size, bool inverted, uint8_t rxfifo_full_thrhd)
304+
bool _testUartBegin(uint8_t uart_nr, uint32_t baudrate, uint32_t config, int8_t rxPin, int8_t txPin, uint32_t rx_buffer_size, uint32_t tx_buffer_size, bool inverted, uint8_t rxfifo_full_thrhd)
305305
{
306306
if(uart_nr >= SOC_UART_NUM) {
307307
return false; // no new driver has to be installed
@@ -320,7 +320,7 @@ bool _testUartBegin(uint8_t uart_nr, uint32_t baudrate, uint32_t config, int8_t
320320
}
321321
}
322322

323-
uart_t* uartBegin(uint8_t uart_nr, uint32_t baudrate, uint32_t config, int8_t rxPin, int8_t txPin, uint16_t rx_buffer_size, uint16_t tx_buffer_size, bool inverted, uint8_t rxfifo_full_thrhd)
323+
uart_t* uartBegin(uint8_t uart_nr, uint32_t baudrate, uint32_t config, int8_t rxPin, int8_t txPin, uint32_t rx_buffer_size, uint32_t tx_buffer_size, bool inverted, uint8_t rxfifo_full_thrhd)
324324
{
325325
if(uart_nr >= SOC_UART_NUM) {
326326
log_e("UART number is invalid, please use number from 0 to %u", SOC_UART_NUM - 1);

‎cores/esp32/esp32-hal-uart.h

Copy file name to clipboardExpand all lines: cores/esp32/esp32-hal-uart.h
+2-2Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,8 @@ extern "C" {
2929
struct uart_struct_t;
3030
typedef struct uart_struct_t uart_t;
3131

32-
bool _testUartBegin(uint8_t uart_nr, uint32_t baudrate, uint32_t config, int8_t rxPin, int8_t txPin, uint16_t rx_buffer_size, uint16_t tx_buffer_size, bool inverted, uint8_t rxfifo_full_thrhd);
33-
uart_t* uartBegin(uint8_t uart_nr, uint32_t baudrate, uint32_t config, int8_t rxPin, int8_t txPin, uint16_t rx_buffer_size, uint16_t tx_buffer_size, bool inverted, uint8_t rxfifo_full_thrhd);
32+
bool _testUartBegin(uint8_t uart_nr, uint32_t baudrate, uint32_t config, int8_t rxPin, int8_t txPin, uint32_t rx_buffer_size, uint32_t tx_buffer_size, bool inverted, uint8_t rxfifo_full_thrhd);
33+
uart_t* uartBegin(uint8_t uart_nr, uint32_t baudrate, uint32_t config, int8_t rxPin, int8_t txPin, uint32_t rx_buffer_size, uint32_t tx_buffer_size, bool inverted, uint8_t rxfifo_full_thrhd);
3434
void uartEnd(uint8_t uart_num);
3535

3636
// This is used to retrieve the Event Queue pointer from a UART IDF Driver in order to allow user to deal with its events

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.