1
1
/*
2
- * Copyright 2022-2023 NXP
2
+ * Copyright 2022-2024 NXP
3
3
*
4
4
* SPDX-License-Identifier: BSD-3-Clause
5
5
*/
@@ -25,7 +25,6 @@ extern "C"{
25
25
* 3) internal and external interfaces from this unit
26
26
* 4) user callback header files
27
27
==================================================================================================*/
28
- #include <zephyr/devicetree.h>
29
28
#include "S32Z2_LINFLEXD.h"
30
29
#include "Mcal.h"
31
30
/*==================================================================================================
@@ -35,7 +34,7 @@ extern "C"{
35
34
#define LINFLEXD_UART_IP_DEFINES_AR_RELEASE_MAJOR_VERSION 4
36
35
#define LINFLEXD_UART_IP_DEFINES_AR_RELEASE_MINOR_VERSION 7
37
36
#define LINFLEXD_UART_IP_DEFINES_AR_RELEASE_REVISION_VERSION 0
38
- #define LINFLEXD_UART_IP_DEFINES_SW_MAJOR_VERSION 1
37
+ #define LINFLEXD_UART_IP_DEFINES_SW_MAJOR_VERSION 2
39
38
#define LINFLEXD_UART_IP_DEFINES_SW_MINOR_VERSION 0
40
39
#define LINFLEXD_UART_IP_DEFINES_SW_PATCH_VERSION 0
41
40
@@ -46,7 +45,7 @@ extern "C"{
46
45
/* Checks against Mcal.h */
47
46
#if ((LINFLEXD_UART_IP_DEFINES_AR_RELEASE_MAJOR_VERSION != MCAL_AR_RELEASE_MAJOR_VERSION ) || \
48
47
(LINFLEXD_UART_IP_DEFINES_AR_RELEASE_MINOR_VERSION != MCAL_AR_RELEASE_MINOR_VERSION ) \
49
- )
48
+ )
50
49
#error "AUTOSAR Version Numbers of Linflexd_Uart_Ip_Defines.h and Mcal.h are different"
51
50
#endif
52
51
#endif
@@ -55,49 +54,52 @@ extern "C"{
55
54
==================================================================================================*/
56
55
57
56
/*==================================================================================================
58
- * DEFINES AND MACROS
57
+ * DEFINES AND MACROS
59
58
==================================================================================================*/
60
- /* @Custom baudrate values */
61
- #define LINFLEXD_UART_IP_CUSTOM_BAUDRATE
59
+ /** Number of instances of the LIN module. */
60
+ #define LINFLEXD_IP_INSTANCE_COUNT LINFLEXD_INSTANCE_COUNT
62
61
62
+ /** Array initializer of LINFLEXD peripheral base pointers */
63
+ #define LINFLEXD_IP_BASE_PTRS IP_LINFLEXD_BASE_PTRS
63
64
/* @brief Development error detection */
64
65
#define LINFLEXD_UART_IP_DEV_ERROR_DETECT (STD_OFF)
65
66
66
67
/* @brief Total number of channels configured */
67
- #define LINFLEXD_UART_IP_NUMBER_OF_INSTANCES (DT_NUM_INST_STATUS_OKAY(nxp_s32_linflexd) )
68
+ #define LINFLEXD_UART_IP_NUMBER_OF_INSTANCES (2U )
68
69
69
70
/* @brief Uart Osif source counter. This parameter is used to select between different OsIf counter implementation */
70
71
#define LINFLEXD_UART_IP_TIMEOUT_TYPE (OSIF_COUNTER_DUMMY)
71
72
72
- /* @brief Number of loops before returning STATUS_TIMEOUT .*/
73
- #define LINFLEXD_UART_IP_TIMEOUT_VALUE_US (0 )
73
+ /* @brief Number of loops before returning LINFLEXD_STATUS_TIMEOUT .*/
74
+ #define LINFLEXD_UART_IP_TIMEOUT_VALUE_US (0U )
74
75
75
- /* @brief LINFLEXD rx/tx/error interrupt lines ored together. */
76
+ /* @brief LINFLEXD rx/tx/error interrupt lines ORED together. */
76
77
#define LINFLEXD_UART_IP_ORED_INT_LINES (1U)
77
78
78
- /* @brief LINFlexD DMA support */
79
+ /* @brief LINFLEXD DMA support */
79
80
#define LINFLEXD_UART_IP_HAS_DMA_ENABLED (STD_OFF)
80
81
81
- /* @brief LINFlexD User-mode support */
82
- #define LINFLEXD_UART_IP_ENABLE_USER_MODE_SUPPORT (STD_OFF)
83
-
84
82
/* @brief LINFLEXD DMA enabled instances */
85
- #define LINFLEXD_UART_IP_INST_HAS_DMA {(boolean)TRUE, (boolean)TRUE, (boolean)TRUE, (boolean)TRUE, (boolean)TRUE, (boolean)TRUE, (boolean)TRUE, (boolean)TRUE, (boolean)TRUE, (boolean)TRUE, (boolean)TRUE, (boolean)TRUE, (boolean)TRUE}
83
+ #define LINFLEXD_UART_IP_INST_HAS_DMA \
84
+ {(boolean)TRUE, (boolean)TRUE, (boolean)TRUE, (boolean)TRUE, (boolean)TRUE, (boolean)TRUE, (boolean)TRUE, (boolean)TRUE, (boolean)TRUE, (boolean)TRUE, (boolean)TRUE, (boolean)TRUE, (boolean)TRUE}
85
+
86
+ /* @brief Support for User mode. If this parameter has been configured to TRUE, the Uart driver can be executed from both supervisor and user mode. */
87
+ #define LINFLEXD_UART_IP_ENABLE_USER_MODE_SUPPORT (STD_OFF)
86
88
87
89
/* @brief Support for Uart Timeout Interrupt. If this parameter has been configured to TRUE, the Uart driver will enable Timeout Interrupt. */
88
90
#define LINFLEXD_UART_IP_ENABLE_TIMEOUT_INTERRUPT (STD_OFF)
89
91
90
92
#if (STD_ON == LINFLEXD_UART_IP_ENABLE_TIMEOUT_INTERRUPT )
91
- /* @brief Array of instances that have loopback mode enabled. */
92
- #define LINFLEXD_UART_IP_ENABLE_TIMEOUT_INTERRUPT_PER_INSTANCE {(boolean) FALSE, (boolean) FALSE, (boolean) FALSE, (boolean) FALSE, (boolean) FALSE, (boolean) FALSE, (boolean) FALSE, (boolean) FALSE, (boolean) FALSE, (boolean) FALSE, (boolean) FALSE, (boolean) FALSE, (boolean) FALSE}
93
+ /* @brief Array of instances that have timeout interrupt enabled. */
94
+ #define LINFLEXD_UART_IP_ENABLE_TIMEOUT_INTERRUPT_PER_INSTANCE {(boolean) FALSE,(boolean) FALSE,(boolean) FALSE,(boolean) FALSE,(boolean) FALSE,(boolean) FALSE,(boolean) FALSE,(boolean) FALSE,(boolean) FALSE,(boolean) FALSE,(boolean) FALSE,(boolean) FALSE,(boolean) FALSE }
93
95
#endif
94
96
95
97
/* @brief Support for Internal Loopback. If this parameter has been configured to TRUE, the Uart driver will be executed in Loopback mode. */
96
98
#define LINFLEXD_UART_IP_ENABLE_INTERNAL_LOOPBACK (STD_OFF)
97
99
98
100
#if (STD_ON == LINFLEXD_UART_IP_ENABLE_INTERNAL_LOOPBACK )
99
101
/* @brief Array of instances that have loopback mode enabled. */
100
- #define LINFLEXD_UART_IP_ENABLE_INTERNAL_LOOPBACK_PER_INSTANCE {(boolean) FALSE, (boolean) FALSE, (boolean) FALSE, (boolean) FALSE, (boolean) FALSE, (boolean) FALSE, (boolean) FALSE, (boolean) FALSE, (boolean) FALSE, (boolean) FALSE, (boolean) FALSE, (boolean) FALSE, (boolean) FALSE}
102
+ #define LINFLEXD_UART_IP_ENABLE_INTERNAL_LOOPBACK_PER_INSTANCE {(boolean) FALSE,(boolean) FALSE,(boolean) FALSE,(boolean) FALSE,(boolean) FALSE,(boolean) FALSE,(boolean) FALSE,(boolean) FALSE,(boolean) FALSE,(boolean) FALSE,(boolean) FALSE,(boolean) FALSE,(boolean) FALSE }
101
103
#endif
102
104
103
105
/* Check the driver user mode is enabled only when the MCAL_ENABLE_USER_MODE_SUPPORT is enabled */
0 commit comments