CanIf.h 6.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124
  1. /**
  2. * @file CanIf.h
  3. * @version 1.0.0
  4. *
  5. * @brief AUTOSAR CanIf - CanIf module interface
  6. * @details AUTOSAR CanIf module interface.- Stub Version
  7. * This file contains sample code only. It is not part of the production code deliverables.
  8. *
  9. * @addtogroup CANIF_MODULE
  10. * @{
  11. */
  12. /*==================================================================================================
  13. * Project : RTD AUTOSAR 4.4
  14. * Platform : CORTEXM
  15. * Peripheral : generic
  16. * Dependencies :
  17. *
  18. * Autosar Version : 4.4.0
  19. * Autosar Revision : ASR_REL_4_4_REV_0000
  20. * Autosar Conf.Variant :
  21. * SW Version : 1.0.0
  22. * Build Version : S32K1_RTD_1_0_0_HF01_D2109_ASR_REL_4_4_REV_0000_20210907
  23. *
  24. * (c) Copyright 2020-2021 NXP Semiconductors
  25. * All Rights Reserved.
  26. *
  27. * NXP Confidential. This software is owned or controlled by NXP and may only be
  28. * used strictly in accordance with the applicable license terms. By expressly
  29. * accepting such terms or by downloading, installing, activating and/or otherwise
  30. * using the software, you are agreeing that you have read, and that you agree to
  31. * comply with and are bound by, such license terms. If you do not agree to be
  32. * bound by the applicable license terms, then you may not retain, install,
  33. * activate or otherwise use the software.
  34. ==================================================================================================*/
  35. /*==================================================================================================
  36. ==================================================================================================*/
  37. #ifndef CANIF_H
  38. #define CANIF_H
  39. #ifdef __cplusplus
  40. extern "C"
  41. {
  42. #endif
  43. /*==================================================================================================
  44. * INCLUDE FILES
  45. * 1) system and project includes
  46. * 2) needed interfaces from external units
  47. * 3) internal and external interfaces from this unit
  48. ==================================================================================================*/
  49. #include "CanIf_Types.h"
  50. #include "EcuM.h"
  51. /*==================================================================================================
  52. * SOURCE FILE VERSION INFORMATION
  53. ==================================================================================================*/
  54. #define CANIF_VENDOR_ID 43
  55. #define CANIF_MODULE_ID 60
  56. #define CANIF_AR_RELEASE_MAJOR_VERSION 4
  57. #define CANIF_AR_RELEASE_MINOR_VERSION 4
  58. #define CANIF_AR_RELEASE_REVISION_VERSION 0
  59. #define CANIF_SW_MAJOR_VERSION 1
  60. #define CANIF_SW_MINOR_VERSION 0
  61. #define CANIF_SW_PATCH_VERSION 0
  62. /*==================================================================================================
  63. * FILE VERSION CHECKS
  64. ==================================================================================================*/
  65. /* Check if current file and CanIf_Types.h header file are of the same vendor */
  66. #if (CANIF_VENDOR_ID != CANIF_TYPES_VENDOR_ID)
  67. #error "CanIf.h and CanIf_Types.h have different vendor ids"
  68. #endif
  69. /* Check if current file and CanIf_Types.h header file are of the same Autosar version */
  70. #if ((CANIF_AR_RELEASE_MAJOR_VERSION != CANIF_TYPES_AR_RELEASE_MAJOR_VERSION) || \
  71. (CANIF_AR_RELEASE_MINOR_VERSION != CANIF_TYPES_AR_RELEASE_MINOR_VERSION) || \
  72. (CANIF_AR_RELEASE_REVISION_VERSION != CANIF_TYPES_AR_RELEASE_REVISION_VERSION))
  73. #error "AutoSar Version Numbers of CanIf.h and CanIf_Types.h are different"
  74. #endif
  75. /* Check if current file and CanIf_Types.h header file are of the same software version */
  76. #if ((CANIF_SW_MAJOR_VERSION != CANIF_TYPES_SW_MAJOR_VERSION) || \
  77. (CANIF_SW_MINOR_VERSION != CANIF_TYPES_SW_MINOR_VERSION) || \
  78. (CANIF_SW_PATCH_VERSION != CANIF_TYPES_SW_PATCH_VERSION))
  79. #error "Software Version Numbers of CanIf.h and CanIf_Types.h are different"
  80. #endif
  81. /* Check if current file and EcuM.h header file are of the same version */
  82. #ifndef DISABLE_MCAL_INTERMODULE_ASR_CHECK
  83. #if ((CANIF_AR_RELEASE_MAJOR_VERSION != ECUM_AR_RELEASE_MAJOR_VERSION) || \
  84. (CANIF_AR_RELEASE_MINOR_VERSION != ECUM_AR_RELEASE_MINOR_VERSION))
  85. #error "AutoSar Version Numbers of CanIf.h and EcuM.h are different"
  86. #endif
  87. #endif
  88. /*==================================================================================================
  89. * CONSTANTS
  90. ==================================================================================================*/
  91. /*==================================================================================================
  92. * DEFINES AND MACROS
  93. ==================================================================================================*/
  94. /*==================================================================================================
  95. * ENUMS
  96. ==================================================================================================*/
  97. /*==================================================================================================
  98. * STRUCTURES AND OTHER TYPEDEFS
  99. ==================================================================================================*/
  100. /*==================================================================================================
  101. * GLOBAL VARIABLE DECLARATIONS
  102. ==================================================================================================*/
  103. /*==================================================================================================
  104. * FUNCTION PROTOTYPES
  105. ==================================================================================================*/
  106. Std_ReturnType CanIf_TriggerTransmit(PduIdType TxPduId, PduInfoType * PduInfoPtr);
  107. Std_ReturnType CanIf_CheckWakeup(EcuM_WakeupSourceType WakeupSource);
  108. #ifdef __cplusplus
  109. }
  110. #endif
  111. #endif /* CANIF_H */
  112. /** @} */