[STM32] Fix issue that CAN driver won't receive any messages once OV iterrupt occurs.

Change-Id: I4cd98ca4840f32925e89e8c467ec78e03e9a2836
This commit is contained in:
Noe Xu 2019-01-07 00:27:01 -08:00
parent d55a9cd62a
commit 5e47dc41b3
1 changed files with 10 additions and 6 deletions

View File

@ -362,12 +362,16 @@ void CAN2_SCE_IRQHandler(void)
*/
void HAL_CAN_ErrorCallback(CAN_HandleTypeDef *hcan)
{
/* TODO Error Callback */
/* Prevent unused argument(s) compilation warning */
UNUSED(hcan);
/* NOTE : This function Should not be modified, when the callback is needed,
the HAL_CAN_ErrorCallback could be implemented in the user file
*/
__HAL_CAN_ENABLE_IT(hcan, CAN_IT_EWG |
CAN_IT_EPV |
CAN_IT_BOF |
CAN_IT_LEC |
CAN_IT_ERR |
CAN_IT_FMP0|
CAN_IT_FOV0|
CAN_IT_FMP1|
CAN_IT_FOV1|
CAN_IT_TME);
}
/**