109 lines
3.2 KiB
C
109 lines
3.2 KiB
C
|
/*@<40><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ʵ<EFBFBD><CAB5><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>д<EFBFBD><D0B4><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ϣ<EFBFBD><CFA2><EFBFBD><EFBFBD>@<40>ַ<EFBFBD><D6B7>Լ<EFBFBD><D4BC><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ʾ<EFBFBD><CABE><EFBFBD><EFBFBD>ȥ<EFBFBD><C8A5>*/
|
|||
|
/******************************************************************************
|
|||
|
| File Name : @<EFBFBD>ļ<EFBFBD><EFBFBD><EFBFBD>
|
|||
|
| Description: @<EFBFBD>ļ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
|||
|
******************************************************************************/
|
|||
|
#ifndef CANTP_H
|
|||
|
#define CANTP_H
|
|||
|
|
|||
|
/******************************************************************************
|
|||
|
* Description: : Include File Section
|
|||
|
******************************************************************************/
|
|||
|
#include "CanSm.h"
|
|||
|
#include "CanTp_Cfg.h"
|
|||
|
|
|||
|
/******************************************************************************
|
|||
|
* Description: : Macro Description Section
|
|||
|
******************************************************************************/
|
|||
|
|
|||
|
|
|||
|
/******************************************************************************
|
|||
|
* Description: : Structure Type Declaration Section
|
|||
|
******************************************************************************/
|
|||
|
|
|||
|
typedef enum
|
|||
|
{
|
|||
|
CeCanTp_e_Empty = 0,
|
|||
|
CeCanTp_e_Full = 1,
|
|||
|
}TeCanTp_e_RxBufferSts;
|
|||
|
|
|||
|
typedef enum
|
|||
|
{
|
|||
|
CeCanTp_e_Physical=0,
|
|||
|
CeCanTp_e_Functional,
|
|||
|
}TeCanTp_e_AddrMethod;
|
|||
|
|
|||
|
typedef enum
|
|||
|
{
|
|||
|
CeCanTp_e_Idel = 0,
|
|||
|
CeCanTp_e_SF_Get,
|
|||
|
CeCanTp_e_MF_FFGet,
|
|||
|
CeCanTp_e_MF_CFTakein,
|
|||
|
CeCanTp_e_MF_Get,
|
|||
|
CeCanTp_e_Answer,
|
|||
|
}TeCanTp_e_TpSts;
|
|||
|
|
|||
|
typedef enum
|
|||
|
{
|
|||
|
CeCanTp_e_CntnsIdel = 0,
|
|||
|
CeCanTp_e_CntnsSF_Get,
|
|||
|
}TeCanTp_e_CntnsTpSts;
|
|||
|
|
|||
|
typedef enum
|
|||
|
{
|
|||
|
CeCanTp_e_TX_Idel = 0,
|
|||
|
CeCanTp_e_TX_FCWaiting,
|
|||
|
CeCanTp_e_TX_FCGet,
|
|||
|
CeCanTp_e_TX_CFGaving,
|
|||
|
}TeCanTp_e_MFTxSts;
|
|||
|
|
|||
|
typedef enum
|
|||
|
{
|
|||
|
CeCanTp_e_As = 0,
|
|||
|
CeCanTp_e_Bs,
|
|||
|
CeCanTp_e_Cs,
|
|||
|
CeCanTp_e_Ar,
|
|||
|
CeCanTp_e_Br,
|
|||
|
CeCanTp_e_Cr,
|
|||
|
}TeCanTp_e_MFTimerSwitch;
|
|||
|
|
|||
|
typedef enum
|
|||
|
{
|
|||
|
CeCanTp_e_Tx_Idle = 0,
|
|||
|
CeCanTp_e_Tx_Busy,
|
|||
|
}TeCanTp_e_TxSts;
|
|||
|
|
|||
|
typedef enum
|
|||
|
{
|
|||
|
CeCanTp_e_Tx_Succeed = 0,
|
|||
|
CeCanTp_e_Tx_Wrong,
|
|||
|
}TeCanTp_e_TxResult;
|
|||
|
|
|||
|
typedef enum
|
|||
|
{
|
|||
|
CeCanTp_e_S3_Start = 0,
|
|||
|
CeCanTp_e_S3_Stop,
|
|||
|
}TeCanTp_e_S3TimerSts;
|
|||
|
|
|||
|
/******************************************************************************
|
|||
|
* Description: : Global Variable Declaration Section
|
|||
|
******************************************************************************/
|
|||
|
|
|||
|
|
|||
|
/******************************************************************************
|
|||
|
* Description: : Global Function Prototype Declaration
|
|||
|
******************************************************************************/
|
|||
|
extern uint8 GetCanTp_u_S3Sts(void);/*<2A><>ȡS3*/
|
|||
|
extern void MngCanTp_MainFunction(void);/*<2A><><EFBFBD><EFBFBD><EFBFBD>Ⱥ<EFBFBD><C8BA><EFBFBD>*/
|
|||
|
extern void InitCanTp_Parameter(void);/*<2A><>ʼ<EFBFBD><CABC>*/
|
|||
|
|
|||
|
extern TeCanTp_e_TxResult SetCanTp_TxBuffer(uint16 LeCanTp_p_DL, const uint8 LeCanTp_p_DataAddr[]);/*<2A><><EFBFBD>ͺ<EFBFBD><CDBA><EFBFBD>*/
|
|||
|
extern TeCanTp_e_TxResult SetCanTp_Tx_78Neg(uint16 LeCanTp_p_DL , const uint8 LeCanTp_p_DataAddr[]);
|
|||
|
|
|||
|
extern void RxIndicationCanTP_AddrFunc_Message(CanIf_HwHandleType LeCanTp_e_Hrh, CanIf_CanIdType LeCanTp_e_CanId,CanIf_CanDlcType LeCanTp_e_CanDlc, const CanIf_CanDataType LeCanTp_e_CanSduPtr[]);/*<2A><><EFBFBD>պ<EFBFBD><D5BA><EFBFBD>*/
|
|||
|
|
|||
|
extern void RxIndicationCanTP_AddrPhy_Message(CanIf_HwHandleType LeCanTp_e_Hrh, CanIf_CanIdType LeCanTp_e_CanId,CanIf_CanDlcType LeCanTp_e_CanDlc,const CanIf_CanDataType LeCanTp_e_CanSduPtr[]);/*<2A><><EFBFBD>պ<EFBFBD><D5BA><EFBFBD>*/
|
|||
|
|
|||
|
extern TeCanTp_e_RxBufferSts GetCanTp_e_RxBufferSts(uint8* LeCanTp_p_AddrMethod , uint16* LeCanTp_p_DL , uint8** LeCanTp_p_DataAddr);/*<2A>ϲ<EFBFBD><CFB2><EFBFBD>ȡ<EFBFBD><C8A1><EFBFBD>յ<EFBFBD><D5B5>ñ<EFBFBD><C3B1><EFBFBD>*/
|
|||
|
#endif
|