Fixed serial_device IRQ infinite loop bug due to uint8_t overflowing

pull/11042/head
Yuan Cao 2019-07-13 00:05:25 -04:00
parent 2d6db332e6
commit 6ed21ee1c0
11 changed files with 11 additions and 11 deletions

View File

@ -605,7 +605,7 @@ int serial_irq_handler_asynch(serial_t *obj)
volatile int return_event = 0;
uint8_t *buf = (uint8_t *)(obj->rx_buff.buffer);
uint8_t i = 0;
size_t i = 0;
// TX PART:
if (__HAL_UART_GET_FLAG(huart, UART_FLAG_TC) != RESET) {

View File

@ -476,7 +476,7 @@ int serial_irq_handler_asynch(serial_t *obj)
volatile int return_event = 0;
uint8_t *buf = (uint8_t *)(obj->rx_buff.buffer);
uint8_t i = 0;
size_t i = 0;
// TX PART:
if (__HAL_UART_GET_FLAG(huart, UART_FLAG_TC) != RESET) {

View File

@ -559,7 +559,7 @@ int serial_irq_handler_asynch(serial_t *obj)
volatile int return_event = 0;
uint8_t *buf = (uint8_t *)(obj->rx_buff.buffer);
uint8_t i = 0;
size_t i = 0;
// TX PART:
if (__HAL_UART_GET_FLAG(huart, UART_FLAG_TC) != RESET) {

View File

@ -522,7 +522,7 @@ int serial_irq_handler_asynch(serial_t *obj)
volatile int return_event = 0;
uint8_t *buf = (uint8_t *)(obj->rx_buff.buffer);
uint8_t i = 0;
size_t i = 0;
// TX PART:
if (__HAL_UART_GET_FLAG(huart, UART_FLAG_TC) != RESET) {

View File

@ -604,7 +604,7 @@ int serial_irq_handler_asynch(serial_t *obj)
volatile int return_event = 0;
uint8_t *buf = (uint8_t *)(obj->rx_buff.buffer);
uint8_t i = 0;
size_t i = 0;
// TX PART:
if (__HAL_UART_GET_FLAG(huart, UART_FLAG_TC) != RESET) {

View File

@ -560,7 +560,7 @@ int serial_irq_handler_asynch(serial_t *obj)
volatile int return_event = 0;
uint8_t *buf = (uint8_t *)(obj->rx_buff.buffer);
uint8_t i = 0;
size_t i = 0;
// TX PART:
if (__HAL_UART_GET_FLAG(huart, UART_FLAG_TC) != RESET) {

View File

@ -573,7 +573,7 @@ int serial_irq_handler_asynch(serial_t *obj)
volatile int return_event = 0;
uint8_t *buf = (uint8_t *)(obj->rx_buff.buffer);
uint8_t i = 0;
size_t i = 0;
// TX PART:
if (__HAL_UART_GET_FLAG(huart, UART_FLAG_TC) != RESET) {

View File

@ -500,7 +500,7 @@ int serial_irq_handler_asynch(serial_t *obj)
volatile int return_event = 0;
uint8_t *buf = (uint8_t *)(obj->rx_buff.buffer);
uint8_t i = 0;
size_t i = 0;
// TX PART:
if (__HAL_UART_GET_FLAG(huart, UART_FLAG_TC) != RESET) {

View File

@ -512,7 +512,7 @@ int serial_irq_handler_asynch(serial_t *obj)
volatile int return_event = 0;
uint8_t *buf = (uint8_t *)(obj->rx_buff.buffer);
uint8_t i = 0;
size_t i = 0;
// TX PART:
if (__HAL_UART_GET_FLAG(huart, UART_FLAG_TC) != RESET) {

View File

@ -536,7 +536,7 @@ int serial_irq_handler_asynch(serial_t *obj)
volatile int return_event = 0;
uint8_t *buf = (uint8_t *)(obj->rx_buff.buffer);
uint8_t i = 0;
size_t i = 0;
// TX PART:
if (__HAL_UART_GET_FLAG(huart, UART_FLAG_TC) != RESET) {

View File

@ -461,7 +461,7 @@ int serial_irq_handler_asynch(serial_t *obj)
volatile int return_event = 0;
uint8_t *buf = (uint8_t *)(obj->rx_buff.buffer);
uint8_t i = 0;
size_t i = 0;
// TX PART:
if (__HAL_UART_GET_FLAG(huart, UART_FLAG_TC) != RESET) {