/*! * @file uds_manage.c * @brief interaction layer between UDS service and TP layer. * */ #include "uds_config.h" static uint8_t HAL_UDS_Rx_Buffer[8]; /*!< UDS Receive Buffer */ bool HAL_Response_Pocessing; /*!< UDS Response Processing */ static uint8_t HAL_UDS_RECEIVE_LENGTH; /*!< UDS Receive Length */ static uint8_t HAL_UDS_TRANSMIT_LENGTH; /*!< UDS Transmit Length */ static uint32_t HAL_UDS_TRANSMIT_ID; /*!< UDS Transmit ID */ //extern flexcan_state_t canCom0_State[3]; //flexcan_msgbuff_t recvBuff; /*! * @brief HAL_UDS_CallBack * UDS Transmit and Receive interrupt callback * * @param instance instance * @param eventType interrupt event type * @param state flexCAN state */ /*! * @brief HAL_UDS_Init * Initialize function for CAN UDS * */ /*! * @brief HAL_UDS_Rx_DLC * Return the DLC of the Rx Msg * * @return the DLC of the Rx Msg */ uint8_t HAL_UDS_Rx_DLC(void) { return HAL_UDS_RECEIVE_LENGTH; } /*! * @brief HAL_UDS_Get_Buf * Copy the rx msg data from the temp buffer to appl_data_ptr * * @param appl_data_ptr pointer to the destination buffer */ void HAL_UDS_Get_Buf(uint8_t* appl_data_ptr) { uint8_t index; for(index = 0;index