WdgIf_Types.h 5.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121
  1. /*==================================================================================================
  2. * Project : RTD AUTOSAR 4.4
  3. * Platform : CORTEXM
  4. * Peripheral : generic
  5. * Dependencies :
  6. *
  7. * Autosar Version : 4.4.0
  8. * Autosar Revision : ASR_REL_4_4_REV_0000
  9. * Autosar Conf.Variant :
  10. * SW Version : 1.0.0
  11. * Build Version : S32K1_RTD_1_0_0_HF01_D2109_ASR_REL_4_4_REV_0000_20210907
  12. *
  13. * (c) Copyright 2020-2021 NXP Semiconductors
  14. * All Rights Reserved.
  15. *
  16. * NXP Confidential. This software is owned or controlled by NXP and may only be
  17. * used strictly in accordance with the applicable license terms. By expressly
  18. * accepting such terms or by downloading, installing, activating and/or otherwise
  19. * using the software, you are agreeing that you have read, and that you agree to
  20. * comply with and are bound by, such license terms. If you do not agree to be
  21. * bound by the applicable license terms, then you may not retain, install,
  22. * activate or otherwise use the software.
  23. ==================================================================================================*/
  24. #ifndef WDGIF_TYPES_H
  25. #define WDGIF_TYPES_H
  26. /**
  27. * @file WdgIf_Types.h
  28. *
  29. * @addtogroup WdgIf
  30. * @{
  31. */
  32. #ifdef __cplusplus
  33. extern "C"{
  34. #endif
  35. /*==================================================================================================
  36. * INCLUDE FILES
  37. * 1) system and project includes
  38. * 2) needed interfaces from external units
  39. * 3) internal and external interfaces from this unit
  40. ==================================================================================================*/
  41. #include "StandardTypes.h"
  42. /*==================================================================================================
  43. * SOURCE FILE VERSION INFORMATION
  44. ==================================================================================================*/
  45. #define WDGIF_TYPES_VENDOR_ID 43
  46. #define WDGIF_TYPES_MODULE_ID 43
  47. #define WDGIF_TYPES_AR_RELEASE_MAJOR_VERSION 4
  48. #define WDGIF_TYPES_AR_RELEASE_MINOR_VERSION 4
  49. #define WDGIF_TYPES_AR_RELEASE_REVISION_VERSION 0
  50. #define WDGIF_TYPES_SW_MAJOR_VERSION 1
  51. #define WDGIF_TYPES_SW_MINOR_VERSION 0
  52. #define WDGIF_TYPES_SW_PATCH_VERSION 0
  53. /*==================================================================================================
  54. * FILE VERSION CHECKS
  55. ==================================================================================================*/
  56. /* Check if source file and WDGIF_TYPES configuration header file are of the same Autosar version */
  57. #ifndef DISABLE_MCAL_INTERMODULE_ASR_CHECK
  58. #if ((WDGIF_TYPES_AR_RELEASE_MAJOR_VERSION != STD_AR_RELEASE_MAJOR_VERSION) || \
  59. (WDGIF_TYPES_AR_RELEASE_MINOR_VERSION != STD_AR_RELEASE_MINOR_VERSION))
  60. #error "AutoSar Version Numbers of WdgIf.h and StandardTypes.h are different"
  61. #endif
  62. #endif
  63. /*==================================================================================================
  64. * CONSTANTS
  65. ==================================================================================================*/
  66. /*==================================================================================================
  67. * DEFINES AND MACROS
  68. ==================================================================================================*/
  69. /*==================================================================================================
  70. * ENUMS
  71. ==================================================================================================*/
  72. /**
  73. * @brief This enumerated type will contain the watchdog driver's possible states
  74. */
  75. typedef enum
  76. {
  77. WDGIF_UNINIT = 0x01U, /**< @brief = 0x01 The watchdog driver is not uninitialized. This shall be the default value after reset */
  78. WDGIF_IDLE = 0x02U, /**< @brief = 0x02 The watchdog driver is currently idle, i.e not beeing triggered or mode changed */
  79. WDGIF_BUSY = 0x03U /**< @brief = 0x03 The watchdog driver is currently busy, i.e triggered or switchd between modes */
  80. }WdgIf_StatusType;
  81. /**
  82. * @brief This enumerated type will contain the watchdog driver's possible modes
  83. */
  84. typedef enum {
  85. WDGIF_OFF_MODE = 0x00U, /**< @brief = 0x00 In this mode, the watchdog driver is disabled (switched off). */
  86. WDGIF_SLOW_MODE = 0x01U, /**< @brief = 0x01 In this mode, the watchdog driver is set up for a long timeout period (slow triggering).*/
  87. WDGIF_FAST_MODE = 0x02U /**< @brief = 0x02 In this mode, the watchdog driver is set up for a short timeout period (fast triggering).*/
  88. } WdgIf_ModeType;
  89. /*==================================================================================================
  90. * STRUCTURES AND OTHER TYPEDEFS
  91. ==================================================================================================*/
  92. typedef Std_ReturnType (*WdgIf_SetModeFctPtrType)(WdgIf_ModeType);
  93. typedef void (*WdgIf_SetTriggerFctPtrType)(uint16);
  94. /*==================================================================================================
  95. * GLOBAL VARIABLE DECLARATIONS
  96. ==================================================================================================*/
  97. /*==================================================================================================
  98. * FUNCTION PROTOTYPES
  99. ==================================================================================================*/
  100. #ifdef __cplusplus
  101. }
  102. #endif
  103. /** @} */
  104. #endif /*WDGIF_TYPES_H*/