mirror of
https://git.intern.spaceteamaachen.de/ALPAKA/sta-core.git
synced 2025-06-12 01:25:59 +00:00
feat: secondary can bus callback
This commit is contained in:
parent
faebbfcb02
commit
64757fb220
@ -117,6 +117,15 @@ namespace sta
|
|||||||
* @ingroup sta_core_stm32_can
|
* @ingroup sta_core_stm32_can
|
||||||
*/
|
*/
|
||||||
void CanBus_RxPendingCallback();
|
void CanBus_RxPendingCallback();
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @brief Interrupt handler for pending RX frames. Secondary handler.
|
||||||
|
*
|
||||||
|
* May be implemented by application.
|
||||||
|
*
|
||||||
|
* @ingroup sta_core_stm32_can
|
||||||
|
*/
|
||||||
|
void CanBus_RxPendingCallbackSecondary();
|
||||||
#endif // STA_STM32_CAN_GLOBAL
|
#endif // STA_STM32_CAN_GLOBAL
|
||||||
} // namespace sta
|
} // namespace sta
|
||||||
|
|
||||||
|
@ -215,6 +215,10 @@ namespace sta
|
|||||||
STA_WEAK
|
STA_WEAK
|
||||||
void CanBus_RxPendingCallback(uint32_t fifo)
|
void CanBus_RxPendingCallback(uint32_t fifo)
|
||||||
{}
|
{}
|
||||||
|
|
||||||
|
STA_WEAK
|
||||||
|
void CanBus_RxPendingCallbackSecondary(uint32_t fifo)
|
||||||
|
{}
|
||||||
} // namespace sta
|
} // namespace sta
|
||||||
|
|
||||||
|
|
||||||
@ -226,6 +230,10 @@ extern "C"
|
|||||||
{
|
{
|
||||||
sta::CanBus_RxPendingCallback(CAN_RX_FIFO0);
|
sta::CanBus_RxPendingCallback(CAN_RX_FIFO0);
|
||||||
}
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
sta::CanBus_RxPendingCallbackSecondary(CAN_RX_FIFO0);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void HAL_CAN_RxFifo1MsgPendingCallback(CAN_HandleTypeDef *hcan)
|
void HAL_CAN_RxFifo1MsgPendingCallback(CAN_HandleTypeDef *hcan)
|
||||||
@ -234,6 +242,9 @@ extern "C"
|
|||||||
{
|
{
|
||||||
sta::CanBus_RxPendingCallback(CAN_RX_FIFO1);
|
sta::CanBus_RxPendingCallback(CAN_RX_FIFO1);
|
||||||
}
|
}
|
||||||
|
else{
|
||||||
|
sta::CanBus_RxPendingCallbackSecondary(CAN_RX_FIFO1);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user