120 #include "Std_Types.h" 121 #include "ComStack_Types.h" 122 #include "Can_GeneralTypes.h" 146 #define CAN_SW_MAJOR_VERSION (1U) 149 #define CAN_SW_MINOR_VERSION (2U) 152 #define CAN_SW_PATCH_VERSION (1U) 161 #define CAN_AR_RELEASE_MAJOR_VERSION (4U) 163 #define CAN_AR_RELEASE_MINOR_VERSION (3U) 166 #define CAN_AR_RELEASE_REVISION_VERSION (1U) 174 #define CAN_VENDOR_ID (44U) 176 #define CAN_MODULE_ID (80U) 178 #define CAN_INSTANCE_ID (0U) 186 #define CAN_UNINIT ((uint8)0U) 188 #define CAN_READY ((uint8)1U) 200 #define CAN_INIT_ID (0x00U) 202 #define CAN_MAINFCT_WRITE_ID (0x01U) 204 #define CAN_SETCTR_ID (0x03U) 206 #define CAN_DIINT_ID (0x04U) 208 #define CAN_ENINT_ID (0x05U) 210 #define CAN_WRITE_ID (0x06U) 212 #define CAN_VERSION_ID (0x07U) 214 #define CAN_MAINFCT_READ_ID (0x08U) 216 #define CAN_MAINFCT_BO_ID (0x09U) 218 #define CAN_MAINFCT_WU_ID (0x0AU) 220 #define CAN_CKWAKEUP_ID (0x0BU) 222 #define CAN_MAINFCT_MODE_ID (0x0CU) 224 #define CAN_SETBAUDRATE_ID (0x0FU) 226 #define CAN_DEINIT_ID (0x10U) 228 #define CAN_GETCTRERRST_ID (0x11U) 230 #define CAN_GETCTRMODE_ID (0x12U) 232 #define CAN_LOOPBACK_ID (0x20U) 234 #define CAN_RXPROCESS_ID (0x21U) 244 #ifndef CAN_E_PARAM_POINTER 245 #define CAN_E_PARAM_POINTER (0x01U) 248 #ifndef CAN_E_PARAM_HANDLE 249 #define CAN_E_PARAM_HANDLE (0x02U) 252 #ifndef CAN_E_PARAM_DLC 253 #define CAN_E_PARAM_DLC (0x03U) 256 #ifndef CAN_E_PARAM_CONTROLLER 257 #define CAN_E_PARAM_CONTROLLER (0x04U) 261 #define CAN_E_UNINIT (0x05U) 264 #ifndef CAN_E_TRANSITION 265 #define CAN_E_TRANSITION (0x06U) 268 #ifndef CAN_E_DATALOST 269 #define CAN_E_DATALOST (0x07U) 272 #ifndef CAN_E_PARAM_BAUDRATE 273 #define CAN_E_PARAM_BAUDRATE (0x08U) 276 #ifndef CAN_E_ICOM_CONFIG_INVALID 277 #define CAN_E_ICOM_CONFIG_INVALID (0x09U) 280 #ifndef CAN_E_INIT_FAILED 281 #define CAN_E_INIT_FAILED (0x0AU) 294 #define CAN_CFG_ID_0 (0x01U) 297 #define CAN_CFG_ID_1 (0x02U) 299 #define CAN_CFG_ID_2 (0x04U) 301 #define CAN_CFG_ID_3 (0x08U) 304 #define CAN_CFG_ID_4 (0x10U) 307 #define CAN_CFG_ID_5 (0x20U) 309 #define CAN_CFG_ID_6 (0x40U) 366 #if defined (SOC_J721E) 411 typedef struct Can_MaskStruct
420 typedef struct Can_HwFilterStruct
431 typedef struct Can_FdBaudConfigStruct
456 typedef struct Can_BaudConfigStruct
480 typedef struct Can_ControllerStruct
492 typedef struct Can_ControllerStruct_PC
516 typedef struct Can_MailboxStruct
548 typedef struct Can_MailboxStruct_PC
568 typedef struct Can_ConfigType_s
584 #if (STD_ON == CAN_REGISTER_READBACK_API) 611 #if (CAN_VERSION_INFO_API == STD_ON) 633 CAN_APPL_DATA) VersionInfo);
683 uint8 Controller, Can_ControllerStateType Transition);
714 FUNC(Std_ReturnType, CAN_CODE)
Can_Write(Can_HwHandleType Hth,
715 const Can_PduType *PduInfo);
860 uint16 BaudRateConfigID);
862 #if (CAN_LOOPBACK_ENABLE == STD_ON) 920 #if (STD_ON == CAN_REGISTER_READBACK_API) 945 CAN_APPL_DATA) RegRbPtr);
948 #if defined (CAN_CONTROLLER_MCU_MCAN0) 969 FUNC(
void, CAN_CODE) Can_0_Int0ISR_Fun(
void);
972 #if defined (CAN_CONTROLLER_MCU_MCAN1) 993 FUNC(
void, CAN_CODE) Can_1_Int0ISR_Fun(
void);
996 #if defined (SOC_J721E) 998 #if defined (CAN_CONTROLLER_MCAN0) 1019 FUNC(
void, CAN_CODE) Can_2_Int0ISR_Fun(
void);
1022 #if defined (CAN_CONTROLLER_MCAN1) 1043 FUNC(
void, CAN_CODE) Can_3_Int0ISR_Fun(
void);
1046 #if defined (CAN_CONTROLLER_MCAN2) 1067 FUNC(
void, CAN_CODE) Can_4_Int0ISR_Fun(
void);
1070 #if defined (CAN_CONTROLLER_MCAN3) 1091 FUNC(
void, CAN_CODE) Can_5_Int0ISR_Fun(
void);
1094 #if defined (CAN_CONTROLLER_MCAN4) 1115 FUNC(
void, CAN_CODE) Can_6_Int0ISR_Fun(
void);
1118 #if defined (CAN_CONTROLLER_MCAN5) 1139 FUNC(
void, CAN_CODE) Can_7_Int0ISR_Fun(
void);
1142 #if defined (CAN_CONTROLLER_MCAN6) 1163 FUNC(
void, CAN_CODE) Can_8_Int0ISR_Fun(
void);
1166 #if defined (CAN_CONTROLLER_MCAN7) 1187 FUNC(
void, CAN_CODE) Can_9_Int0ISR_Fun(
void);
1190 #if defined (CAN_CONTROLLER_MCAN8) 1211 FUNC(
void, CAN_CODE) Can_10_Int0ISR_Fun(
void);
1214 #if defined (CAN_CONTROLLER_MCAN9) 1235 FUNC(
void, CAN_CODE) Can_11_Int0ISR_Fun(
void);
1238 #if defined (CAN_CONTROLLER_MCAN10) 1259 FUNC(
void, CAN_CODE) Can_12_Int0ISR_Fun(
void);
1262 #if defined (CAN_CONTROLLER_MCAN11) 1283 FUNC(
void, CAN_CODE) Can_13_Int0ISR_Fun(
void);
1286 #if defined (CAN_CONTROLLER_MCAN12) 1307 FUNC(
void, CAN_CODE) Can_14_Int0ISR_Fun(
void);
1310 #if defined (CAN_CONTROLLER_MCAN13) 1331 FUNC(
void, CAN_CODE) Can_15_Int0ISR_Fun(
void);
1380 Can_ControllerStateType* ControllerModePtr);
1406 (uint8 ControllerId, Can_ErrorStateType* ErrorStatePtr);
Can_BaudConfigType * DefaultBaud
Definition: Can.h:482
Std_ReturnType Can_GetControllerMode(uint8 Controller, Can_ControllerStateType *ControllerModePtr)
This service reports about the current status of the requested CAN controller.
uint8 PropSeg
Definition: Can.h:460
void Can_DeInit(void)
This function de-initializes the module.
uint8 CanFdPaddingValue
Definition: Can.h:534
uint32 CanReadBackRegCREL
Definition: Can.h:598
uint16 Baud
Definition: Can.h:433
boolean CanHardwareObjectUsesPolling
Definition: Can.h:540
Can mailox configuration definition.
Definition: Can.h:516
Can_MailboxType ** MailBoxList
Definition: Can.h:574
uint8 CanHandleType
Definition: Can.h:518
Can_ControllerInstance CanControllerInst
Definition: Can.h:506
uint32 CanReadBackRegENDN
Definition: Can.h:600
uint16 BrpValue
Definition: Can.h:470
void Can_EnableControllerInterrupts(uint8 Controller)
This function enables all allowed interrupts.
Std_ReturnType Can_SetControllerMode(uint8 Controller, Can_ControllerStateType Transition)
This function performs software triggered state transitions of the CAN controller State machine...
void Can_MainFunction_Read(void)
This function performs the polling of RX indications when CAN_RX_PROCESSING is set to POLLING...
Std_ReturnType Can_RegisterReadback(VAR(uint8,) Controller, Can_RegisterReadbackType *RegRbPtr)
This service will readback CAN registers.
void Can_MainFunction_BusOff(void)
This function performs the polling of bus-off events that are configured statically as 'to be polled'...
Can_TxRxProcessingType TxProcessingType
Definition: Can.h:502
Can_ControllerType ** CanControllerList
Definition: Can.h:570
Can Controller Pre Compile Configuration definition.
Definition: Can.h:492
uint32 Can_InterruptMask_Type
Can Interrupt Mask type.
Definition: Can.h:406
uint32 Mask
Definition: Can.h:424
uint32 CanReadBackRegPID
Definition: Can.h:594
Std_ReturnType Can_Write(Can_HwHandleType Hth, const Can_PduType *PduInfo)
This function is called by CanIf to pass a CAN message to CanDrv for transmission.
Can_TxRxProcessingType RxProcessingType
Definition: Can.h:500
Std_ReturnType Can_SetBaudrate(uint8 Controller, uint16 BaudRateConfigID)
This service shall set the baud rate configuration of the CAN controller. Depending on necessary baud...
Can_IdType IDValue
Definition: Can.h:422
Std_ReturnType Can_TestLoopBackModeDisable(uint8 Controller, uint8 Mode)
This service will disable CAN loopback mode.
boolean CntrActive
Definition: Can.h:496
boolean CanFDModeEnabled
Definition: Can.h:508
uint8 Pseg1
Definition: Can.h:462
uint8 CanControllerState_Type
Can Controller State enum type.
Definition: Can.h:401
uint32 MaxMbCnt
Definition: Can.h:576
Can_BaudConfigType ** BaudRateConfigList
Definition: Can.h:484
Dummy structure will be used if DMA support is required.
Definition: Can.h:557
Can mailox Pre compile configuration definition.
Definition: Can.h:548
void Can_MainFunction_Mode(void)
This function performs the polling of CAN controller mode transitions.
Std_ReturnType Can_GetControllerErrorState(uint8 ControllerId, Can_ErrorStateType *ErrorStatePtr)
This service obtains the error state of the CAN controller.
const Can_ControllerType_PC * Controller
Definition: Can.h:528
Can_FdBaudConfigType BaudFdRateConfig
Definition: Can.h:472
Can_MailBoxDirectionType MBDir
Definition: Can.h:526
Structure defining the CAN baud rate configuration.
Definition: Can.h:456
Can_HwFilterType ** HwFilterList
Definition: Can.h:530
uint32 CanReadBackRegSTAT
Definition: Can.h:596
Can_TxRxProcessingType
Can Tx/Rx processing enum.
Definition: Can.h:346
uint32 MBIdType
Definition: Can.h:520
uint8 PropSeg
Definition: Can.h:435
Structure defining the filter mask to be used.
Definition: Can.h:411
void Can_GetVersionInfo(Std_VersionInfoType *VersionInfo)
Function returns the version information of this module.
Can Controller Configuration definition.
Definition: Can.h:480
uint16 CanHwObjectCount
Definition: Can.h:524
Can_HwHandleType HwHandle
Definition: Can.h:522
uint8 ControllerId
Definition: Can.h:494
uint16 BrpValue
Definition: Can.h:445
Can_ControllerInstance
Can Controller Instances enum.
Definition: Can.h:360
boolean BrsSwitch
Definition: Can.h:449
uint8 Pseg1
Definition: Can.h:437
uint16 Baud
Definition: Can.h:458
#define CAN_MAX_CONTROLLER
Definition: Can_Cfg.h:151
Structure defining the HW filter to be used.
Definition: Can.h:420
uint16 CanObjectId
Definition: Can.h:550
void Can_MainFunction_Write(void)
This function performs the polling of TX confirmation when CAN_TX_PROCESSING is set to POLLING...
uint8 Sjw
Definition: Can.h:466
Can MCAL root configuration structure.
Definition: Can.h:568
uint16 TimingValues
Definition: Can.h:443
uint16 TrcvCompDelay
Definition: Can.h:447
uint8 Pseg2
Definition: Can.h:464
Can_DmaPrms * DmaPrms
Definition: Can.h:580
This file contains generated pre compile configuration file for CAN MCAL driver.
uint8 CanMaxControllerCount
Definition: Can.h:572
uint32 CntrAddr
Definition: Can.h:498
This file contains cover page for generating doxygen API documentation.
uint16 TimingValues
Definition: Can.h:468
uint32 MaskValue
Definition: Can.h:413
Can_HandleType
Can Handle Type enum.
Definition: Can.h:335
Std_ReturnType Can_TestLoopBackModeEnable(uint8 Controller, uint8 Mode)
This service will enable CAN loopback mode.
Can_MailBoxDirectionType
Can Mailbox direction enum.
Definition: Can.h:324
void Can_MainFunction_Wakeup(void)
This function performs the polling of wake-up events that are configured statically as 'to be polled'...
void Can_DisableControllerInterrupts(uint8 Controller)
This function disables all interrupts for this CAN controller.
Structure defining the CAN FD data phase baud rate configuration.
Definition: Can.h:431
boolean BusOffProcessingInterrupt
Definition: Can.h:504
uint8 Pseg2
Definition: Can.h:439
uint8 Sjw
Definition: Can.h:441
Register Readback Structure.
Definition: Can.h:592
void Can_Init(const Can_ConfigType *CfgPtr)
This function initializes the module.
uint32 HwFilterCnt
Definition: Can.h:532
uint32 Reserved
Definition: Can.h:559