diff options
Diffstat (limited to 'os/hal/templates/can_lld.c')
-rw-r--r-- | os/hal/templates/can_lld.c | 29 |
1 files changed, 11 insertions, 18 deletions
diff --git a/os/hal/templates/can_lld.c b/os/hal/templates/can_lld.c index f2f54e66d..792c4f888 100644 --- a/os/hal/templates/can_lld.c +++ b/os/hal/templates/can_lld.c @@ -63,10 +63,6 @@ void can_lld_init(void) { */
void can_lld_start(CANDriver *canp) {
- if (canp->can_state == CAN_STOP) {
- /* Clock activation.*/
- }
- /* Configuration.*/
}
/**
@@ -76,8 +72,13 @@ void can_lld_start(CANDriver *canp) { */
void can_lld_stop(CANDriver *canp) {
+ /* If in ready state then disables the CAN peripheral.*/
+ if (canp->cd_state == CAN_READY) {
+
+ }
}
+
/**
* @brief Determines whether a frame can be transmitted.
* @@ -94,16 +95,12 @@ bool_t can_lld_can_transmit(CANDriver *canp) { /**
* @brief Inserts a frame into the transmit queue.
- * - * @param[in] canp pointer to the @p CANDriver object
- * @param[in] cfp pointer to the CAN frame to be transmitted
*
- * @return The operation status.
- * @retval RDY_OK frame transmitted. + * @param[in] canp pointer to the @p CANDriver object
+ * @param[in] ctfp pointer to the CAN frame to be transmitted
*/
-msg_t can_lld_transmit(CANDriver *canp, const CANFrame *cfp) {
+void can_lld_transmit(CANDriver *canp, const CANTxFrame *ctfp) {
- return RDY_OK;
}
/**
@@ -122,16 +119,12 @@ bool_t can_lld_can_receive(CANDriver *canp) { /**
* @brief Receives a frame from the input queue.
- * - * @param[in] canp pointer to the @p CANDriver object
- * @param[out] cfp pointer to the buffer where the CAN frame is copied
*
- * @return The operation status.
- * @retval RDY_OK frame received.
+ * @param[in] canp pointer to the @p CANDriver object
+ * @param[out] crfp pointer to the buffer where the CAN frame is copied
*/
-msg_t can_lld_receive(CANDriver *canp, CANFrame *cfp) {
+void can_lld_receive(CANDriver *canp, CANRxFrame *crfp) {
- return RDY_OK;
}
#if CAN_USE_SLEEP_MODE || defined(__DOXYGEN__)
|