//***************************************************************************** // (C) Automotive Lighting Reutlingen GmbH // Tuebinger Strasse 123, 72762 Reutlingen, Germany // // Automotive Lighting Reutlingen GmbH owns all the rights to this work. // This work shall not be copied, reproduced, used, modified, transferred // or its information shall not be disclosed without the prior written // authorization of Automotive Lighting Reutlingen GmbH. //***************************************************************************** //----------------------------------------------------------------------------- /// \file CddSbc_Router.c /// /// \brief Specific code for CddSbc Router /// /// \author ZHAO, Kai ALDE-RT/EES6 //----------------------------------------------------------------------------- //============================================================================= // Includes //============================================================================= #include #include #include <../Cfg/CddSbc_Cfg.h> #include <../Cfg/CddSbc_Router.h> #include //============================================================================= // Defines and Typedef //============================================================================= //============================================================================= // Static variable declarations //============================================================================= //============================================================================= // Function prototypes //============================================================================= //============================================================================= // Macros //============================================================================= //----------------------------------------------------------------------------- // Start declaration or definitions of functions //----------------------------------------------------------------------------- #define ctadCddSbc_START_SEC_CODE #include <../Cfg/CddSbc_MemMap.h> //----------------------------------------------------------------------------- //============================================================================= // Function definitions //============================================================================= #if (CDD_SBC_CFG_INIT_OPERATION == STD_ON) //----------------------------------------------------------------------------- /// \brief CddSbc_Init /// /// \descr intialisation /// /// \param void /// /// \return void //----------------------------------------------------------------------------- void CddSbc_Rou_Init(void) { CddTle94x1_Init(); } //----------------------------------------------------------------------------- /// \brief CddSbc_DeInit /// /// \descr Deintialisation /// /// \param void /// /// \return void //----------------------------------------------------------------------------- void CddSbc_Rou_DeInit(void) { CddTle94x1_DeInit(); } #endif #if (CDD_SBC_CFG_SLEEPMODE == STD_ON) //----------------------------------------------------------------------------- /// \brief CddSbc_Rou_SetSleepMode /// /// \descr sleep mode function /// /// \param void /// /// \return void //----------------------------------------------------------------------------- void CddSbc_Rou_SetSleepMode(void) { CddTle94x1_SetSleepMode(); } #endif #if (CDD_SBC_CFG_CAN_OPERATION == STD_ON) //----------------------------------------------------------------------------- /// \brief CddSbc_Rou_SetCanMode /// /// \descr set can mode /// /// \param uint8 ucCanChannel - indicates SBC CAN channel /// uint8 ucCanMode - indicates SBC CAN transceiver mode /// /// \return void //----------------------------------------------------------------------------- void CddSbc_Rou_SetCanMode(uint8 ucCanChannel, uint8 ucCanMode) { CddTle94x1_SetCanMode(ucCanChannel, ucCanMode); } //----------------------------------------------------------------------------- /// \brief CddSbc_Rou_SetCanMode /// /// \descr get can mode /// /// \param uint8 ucCanChannel - indicates SBC CAN channel /// /// \return uint8 ucCanMode - indicates SBC CAN transceiver mode //----------------------------------------------------------------------------- uint8 CddSbc_Rou_GetCanMode(uint8 ucCanChannel) { return CddTle94x1_GetCanMode(ucCanChannel); } //----------------------------------------------------------------------------- /// \brief CddSbc_Rou_GetCanUV /// /// \descr get Can undervoltage /// /// \param uint8 ucCanChannel - indicates SBC CAN channel /// /// \return uint8 ucCanMode - indicates SBC CAN transceiver mode //----------------------------------------------------------------------------- uint8 CddSbc_Rou_GetCanUV(void) { return CddTle94x1_GetCanUV(); } #endif #if (CDD_SBC_CFG_CYCLIC_OPERATION == STD_ON) #if (CDD_SBC_CFG_WK_INPUT == STD_ON) boolean CddSbc_Rou_GetWakeUpStatus(void) { return CddTle94x1_GetWakeUpStatus(); } #endif //CDD_SBC_CFG_WK_INPUT == STD_ON #endif //CDD_SBC_CFG_CYCLIC_OPERATION == STD_ON #if (CDD_SBC_CFG_STORE_RESETREASON == STD_ON) ///----------------------------------------------------------------------------- /// \brief CddSbc_Rou_GetSBCResetReason /// /// \descr /// /// \param uint8 /// /// \return void ///----------------------------------------------------------------------------- uint8 CddSbc_Rou_GetSBCResetReason(void) { //Get SBC Reset Reason return CddTle94x1_GetSBCResetReason(); } #endif #if (CDD_SBC_CFG_WATCHDOG == STD_ON) void CddSbc_Rou_SetWdgWindowModeAnd10ms(void) { CddTle94x1_SetWdgWindowModeAnd10ms(); } void CddSbc_Rou_SetWdgWindowModeAnd200ms(void) { CddTle94x1_SetWdgWindowModeAnd200ms(); } void CddSbc_Rou_SetWdgTimeoutModeAnd200ms(void) { CddTle94x1_SetWdgTimeoutModeAnd200ms(); } #endif #define ctadCddSbc_STOP_SEC_CODE #include <../Cfg/CddSbc_MemMap.h> //----------------------------------------------------------------------------- // End declaration or definitions of functions //-----------------------------------------------------------------------------