Raise STM32F1 UART IRQ Priority, add error handling (#19301)

(Error handling for Overrun, Framing and Parity.)
This commit is contained in:
Victor Oliveira
2020-09-10 00:46:50 -03:00
committed by GitHub
parent 20ac0faa86
commit b98946b5c1
3 changed files with 52 additions and 24 deletions

View File

@ -55,10 +55,8 @@
void MarlinSerial::begin(unsigned long baud, uint8_t config) {
HardwareSerial::begin(baud, config);
// replace the IRQ callback with the one we have defined
#if ENABLED(EMERGENCY_PARSER)
_serial.rx_callback = _rx_callback;
#endif
// Replace the IRQ callback with the one we have defined
TERN_(EMERGENCY_PARSER, _serial.rx_callback = _rx_callback);
}
// This function is Copyright (c) 2006 Nicholas Zambetti.