ADM/GW/RTD/src/Lpuart_Uart_Ip_Irq.c
2024-08-08 10:00:15 +09:00

509 lines
15 KiB
C

/*==================================================================================================
* Project : RTD AUTOSAR 4.4
* Platform : CORTEXM
* Peripheral : FLEXIO
* Dependencies :
*
* Autosar Version : 4.4.0
* Autosar Revision : ASR_REL_4_4_REV_0000
* Autosar Conf.Variant :
* SW Version : 0.9.0
* Build Version : S32K3_RTD_0_9_0__ASR_REL_4_4_REV_0000_20210326
*
* (c) Copyright 2020 - 2021 NXP Semiconductors
* All Rights Reserved.
*
* NXP Confidential. This software is owned or controlled by NXP and may only be
* used strictly in accordance with the applicable license terms. By expressly
* accepting such terms or by downloading, installing, activating and/or otherwise
* using the software, you are agreeing that you have read, and that you agree to
* comply with and are bound by, such license terms. If you do not agree to be
* bound by the applicable license terms, then you may not retain, install,
* activate or otherwise use the software.
==================================================================================================*/
/**
* @file
* @defgroup lpuart_uart_ip Lpuart UART IPL
* @addtogroup lpuart_uart_ip Lpuart UART IPL
* @{
*/
#ifdef __cplusplus
extern "C"{
#endif
/*==================================================================================================
* INCLUDE FILES
* 1) system and project includes
* 2) needed interfaces from external units
* 3) internal and external interfaces from this unit
==================================================================================================*/
#include "Lpuart_Uart_Ip.h"
#include "Lpuart_Uart_Ip_Irq.h"
/*==================================================================================================
* SOURCE FILE VERSION INFORMATION
==================================================================================================*/
#define LPUART_UART_IP_IRQ_VENDOR_ID_C 43
#define LPUART_UART_IP_IRQ_AR_RELEASE_MAJOR_VERSION_C 4
#define LPUART_UART_IP_IRQ_AR_RELEASE_MINOR_VERSION_C 4
#define LPUART_UART_IP_IRQ_AR_RELEASE_REVISION_VERSION_C 0
#define LPUART_UART_IP_IRQ_SW_MAJOR_VERSION_C 0
#define LPUART_UART_IP_IRQ_SW_MINOR_VERSION_C 9
#define LPUART_UART_IP_IRQ_SW_PATCH_VERSION_C 0
/*==================================================================================================
* FILE VERSION CHECKS
==================================================================================================*/
/* Checks against Lpuart_Uart_Ip.h */
#if (LPUART_UART_IP_IRQ_VENDOR_ID_C != LPUART_UART_IP_VENDOR_ID)
#error "Lpuart_Uart_Ip_Irq.c and Lpuart_Uart_Ip.h have different vendor ids"
#endif
#if ((LPUART_UART_IP_IRQ_AR_RELEASE_MAJOR_VERSION_C != LPUART_UART_IP_AR_RELEASE_MAJOR_VERSION) || \
(LPUART_UART_IP_IRQ_AR_RELEASE_MINOR_VERSION_C != LPUART_UART_IP_AR_RELEASE_MINOR_VERSION) || \
(LPUART_UART_IP_IRQ_AR_RELEASE_REVISION_VERSION_C != LPUART_UART_IP_AR_RELEASE_REVISION_VERSION))
#error "AUTOSAR Version Numbers of Lpuart_Uart_Ip_Irq.c and Lpuart_Uart_Ip.h are different"
#endif
#if ((LPUART_UART_IP_IRQ_SW_MAJOR_VERSION_C != LPUART_UART_IP_SW_MAJOR_VERSION) || \
(LPUART_UART_IP_IRQ_SW_MINOR_VERSION_C != LPUART_UART_IP_SW_MINOR_VERSION) || \
(LPUART_UART_IP_IRQ_SW_PATCH_VERSION_C != LPUART_UART_IP_SW_PATCH_VERSION))
#error "Software Version Numbers of Lpuart_Uart_Ip_Irq.c and Lpuart_Uart_Ip.h are different"
#endif
/* Checks against Lpuart_Uart_Ip_Irq.h */
#if (LPUART_UART_IP_IRQ_VENDOR_ID_C != LPUART_UART_IP_IRQ_VENDOR_ID)
#error "Lpuart_Uart_Ip_Irq.c and Lpuart_Uart_Ip_Irq.h have different vendor ids"
#endif
#if ((LPUART_UART_IP_IRQ_AR_RELEASE_MAJOR_VERSION_C != LPUART_UART_IP_IRQ_AR_RELEASE_MAJOR_VERSION) || \
(LPUART_UART_IP_IRQ_AR_RELEASE_MINOR_VERSION_C != LPUART_UART_IP_IRQ_AR_RELEASE_MINOR_VERSION) || \
(LPUART_UART_IP_IRQ_AR_RELEASE_REVISION_VERSION_C != LPUART_UART_IP_IRQ_AR_RELEASE_REVISION_VERSION))
#error "AUTOSAR Version Numbers of Lpuart_Uart_Ip_Irq.c and Lpuart_Uart_Ip_Irq.h are different"
#endif
#if ((LPUART_UART_IP_IRQ_SW_MAJOR_VERSION_C != LPUART_UART_IP_IRQ_SW_MAJOR_VERSION) || \
(LPUART_UART_IP_IRQ_SW_MINOR_VERSION_C != LPUART_UART_IP_IRQ_SW_MINOR_VERSION) || \
(LPUART_UART_IP_IRQ_SW_PATCH_VERSION_C != LPUART_UART_IP_IRQ_SW_PATCH_VERSION))
#error "Software Version Numbers of Lpuart_Uart_Ip_Irq.c and Lpuart_Uart_Ip_Irq.h are different"
#endif
/*==================================================================================================
* LOCAL TYPEDEFS (STRUCTURES, UNIONS, ENUMS)
==================================================================================================*/
/*==================================================================================================
* LOCAL MACROS
==================================================================================================*/
/*==================================================================================================
* LOCAL CONSTANTS
==================================================================================================*/
/*==================================================================================================
* LOCAL VARIABLES
==================================================================================================*/
/*==================================================================================================
* GLOBAL CONSTANTS
==================================================================================================*/
/*==================================================================================================
* GLOBAL VARIABLES
==================================================================================================*/
/*==================================================================================================
* LOCAL FUNCTION PROTOTYPES
==================================================================================================*/
/*==================================================================================================
* LOCAL FUNCTIONS
==================================================================================================*/
/*==================================================================================================
* GLOBAL FUNCTIONS
==================================================================================================*/
#define UART_START_SEC_CODE
/* @violates @ref Uart_c_REF_1 This violation is not fixed since the inclusion of Uart_MemMap.h is as per AUTOSAR requirement*/
#include "Uart_MemMap.h"
#if (LPUART_UART_IP_NUMBER_OF_INSTANCES > 0U)
#ifdef LPUART_IP_0
/* Implementation of Lpuart0 handler named in startup code. */
ISR(LPUART_UART_IP_0_IRQHandler)
{
Lpuart_Uart_Ip_IRQHandler(0U);
}
#endif
#endif
#if (LPUART_UART_IP_NUMBER_OF_INSTANCES > 1U)
#ifdef LPUART_IP_1
/* Implementation of Lpuart1 handler named in startup code. */
ISR(LPUART_UART_IP_1_IRQHandler)
{
Lpuart_Uart_Ip_IRQHandler(1U);
}
#endif
#endif
#if (LPUART_UART_IP_NUMBER_OF_INSTANCES > 2U)
#ifdef LPUART_IP_2
/* Implementation of Lpuart2 handler named in startup code. */
ISR(LPUART_UART_IP_2_IRQHandler)
{
Lpuart_Uart_Ip_IRQHandler(2U);
}
#endif
#endif
#if (LPUART_UART_IP_NUMBER_OF_INSTANCES > 3U)
#ifdef LPUART_IP_3
/* Implementation of Lpuart3 handler named in startup code. */
ISR(LPUART_UART_IP_3_IRQHandler)
{
Lpuart_Uart_Ip_IRQHandler(3U);
}
#endif
#endif
#if (LPUART_UART_IP_NUMBER_OF_INSTANCES > 4U)
#ifdef LPUART_IP_4
/* Implementation of Lpuart4 handler named in startup code. */
ISR(LPUART_UART_IP_4_IRQHandler)
{
Lpuart_Uart_Ip_IRQHandler(4U);
}
#endif
#endif
#if (LPUART_UART_IP_NUMBER_OF_INSTANCES > 5U)
#ifdef LPUART_IP_5
/* Implementation of Lpuart5 handler named in startup code. */
ISR(LPUART_UART_IP_5_IRQHandler)
{
Lpuart_Uart_Ip_IRQHandler(5U);
}
#endif
#endif
#if (LPUART_UART_IP_NUMBER_OF_INSTANCES > 6U)
#ifdef LPUART_IP_6
/* Implementation of Lpuart6 handler named in startup code. */
ISR(LPUART_UART_IP_6_IRQHandler)
{
Lpuart_Uart_Ip_IRQHandler(6U);
}
#endif
#endif
#if (LPUART_UART_IP_NUMBER_OF_INSTANCES > 7U)
#ifdef LPUART_IP_7
/* Implementation of Lpuart7 handler named in startup code. */
ISR(LPUART_UART_IP_7_IRQHandler)
{
Lpuart_Uart_Ip_IRQHandler(7U);
}
#endif
#endif
#if (LPUART_UART_IP_NUMBER_OF_INSTANCES > 8U)
#ifdef LPUART_IP_8
/* Implementation of Lpuart8 handler named in startup code. */
ISR(LPUART_UART_IP_8_IRQHandler)
{
Lpuart_Uart_Ip_IRQHandler(8U);
}
#endif
#endif
#if (LPUART_UART_IP_NUMBER_OF_INSTANCES > 9U)
#ifdef LPUART_IP_9
/* Implementation of Lpuart9 handler named in startup code. */
ISR(LPUART_UART_IP_9_IRQHandler)
{
Lpuart_Uart_Ip_IRQHandler(9U);
}
#endif
#endif
#if (LPUART_UART_IP_NUMBER_OF_INSTANCES > 10U)
#ifdef LPUART_IP_10
/* Implementation of Lpuart10 handler named in startup code. */
ISR(LPUART_UART_IP_10_IRQHandler)
{
Lpuart_Uart_Ip_IRQHandler(10U);
}
#endif
#endif
#if (LPUART_UART_IP_NUMBER_OF_INSTANCES > 11U)
#ifdef LPUART_IP_11
/* Implementation of Lpuart11 handler named in startup code. */
ISR(LPUART_UART_IP_11_IRQHandler)
{
Lpuart_Uart_Ip_IRQHandler(11U);
}
#endif
#endif
#if (LPUART_UART_IP_NUMBER_OF_INSTANCES > 12U)
#ifdef LPUART_IP_12
/* Implementation of Lpuart12 handler named in startup code. */
ISR(LPUART_UART_IP_12_IRQHandler)
{
Lpuart_Uart_Ip_IRQHandler(12U);
}
#endif
#endif
#if (LPUART_UART_IP_NUMBER_OF_INSTANCES > 13U)
#ifdef LPUART_IP_13
/* Implementation of Lpuart13 handler named in startup code. */
ISR(LPUART_UART_IP_13_IRQHandler)
{
Lpuart_Uart_Ip_IRQHandler(13U);
}
#endif
#endif
#if (LPUART_UART_IP_NUMBER_OF_INSTANCES > 14U)
#ifdef LPUART_IP_14
/* Implementation of Lpuart14 handler named in startup code. */
ISR(LPUART_UART_IP_14_IRQHandler)
{
Lpuart_Uart_Ip_IRQHandler(14U);
}
#endif
#endif
#if (LPUART_UART_IP_NUMBER_OF_INSTANCES > 15U)
#ifdef LPUART_IP_15
/* Implementation of Lpuart15 handler named in startup code. */
ISR(LPUART_UART_IP_15_IRQHandler)
{
Lpuart_Uart_Ip_IRQHandler(15U);
}
#endif
#endif
#if (LPUART_UART_IP_HAS_DMA_ENABLED == STD_ON)
#if (LPUART_UART_IP_NUMBER_OF_INSTANCES > 0U)
#ifdef LPUART_IP_0
void Lpuart_0_Uart_Ip_DmaRxCompleteCallback(void)
{
Lpuart_Uart_Ip_CompleteReceiveUsingDma(0);
}
void Lpuart_0_Uart_Ip_DmaTxCompleteCallback(void)
{
Lpuart_Uart_Ip_CompleteSendUsingDma(0);
}
#endif
#endif
#if (LPUART_UART_IP_NUMBER_OF_INSTANCES > 1U)
#ifdef LPUART_IP_1
void Lpuart_1_Uart_Ip_DmaRxCompleteCallback(void)
{
Lpuart_Uart_Ip_CompleteReceiveUsingDma(1);
}
void Lpuart_1_Uart_Ip_DmaTxCompleteCallback(void)
{
Lpuart_Uart_Ip_CompleteSendUsingDma(1);
}
#endif
#endif
#if (LPUART_UART_IP_NUMBER_OF_INSTANCES > 2U)
#ifdef LPUART_IP_2
void Lpuart_2_Uart_Ip_DmaRxCompleteCallback(void)
{
Lpuart_Uart_Ip_CompleteReceiveUsingDma(2);
}
void Lpuart_2_Uart_Ip_DmaTxCompleteCallback(void)
{
Lpuart_Uart_Ip_CompleteSendUsingDma(2);
}
#endif
#endif
#if (LPUART_UART_IP_NUMBER_OF_INSTANCES > 3U)
#ifdef LPUART_IP_3
void Lpuart_3_Uart_Ip_DmaRxCompleteCallback(void)
{
Lpuart_Uart_Ip_CompleteReceiveUsingDma(3);
}
void Lpuart_3_Uart_Ip_DmaTxCompleteCallback(void)
{
Lpuart_Uart_Ip_CompleteSendUsingDma(3);
}
#endif
#endif
#if (LPUART_UART_IP_NUMBER_OF_INSTANCES > 4U)
#ifdef LPUART_IP_4
void Lpuart_4_Uart_Ip_DmaRxCompleteCallback(void)
{
Lpuart_Uart_Ip_CompleteReceiveUsingDma(4);
}
void Lpuart_4_Uart_Ip_DmaTxCompleteCallback(void)
{
Lpuart_Uart_Ip_CompleteSendUsingDma(4);
}
#endif
#endif
#if (LPUART_UART_IP_NUMBER_OF_INSTANCES > 5U)
#ifdef LPUART_IP_5
void Lpuart_5_Uart_Ip_DmaRxCompleteCallback(void)
{
Lpuart_Uart_Ip_CompleteReceiveUsingDma(5);
}
void Lpuart_5_Uart_Ip_DmaTxCompleteCallback(void)
{
Lpuart_Uart_Ip_CompleteSendUsingDma(5);
}
#endif
#endif
#if (LPUART_UART_IP_NUMBER_OF_INSTANCES > 6U)
#ifdef LPUART_IP_6
void Lpuart_6_Uart_Ip_DmaRxCompleteCallback(void)
{
Lpuart_Uart_Ip_CompleteReceiveUsingDma(6);
}
void Lpuart_6_Uart_Ip_DmaTxCompleteCallback(void)
{
Lpuart_Uart_Ip_CompleteSendUsingDma(6);
}
#endif
#endif
#if (LPUART_UART_IP_NUMBER_OF_INSTANCES > 7U)
#ifdef LPUART_IP_7
void Lpuart_7_Uart_Ip_DmaRxCompleteCallback(void)
{
Lpuart_Uart_Ip_CompleteReceiveUsingDma(7);
}
void Lpuart_7_Uart_Ip_DmaTxCompleteCallback(void)
{
Lpuart_Uart_Ip_CompleteSendUsingDma(7);
}
#endif
#endif
#if (LPUART_UART_IP_NUMBER_OF_INSTANCES > 8U)
#ifdef LPUART_IP_8
void Lpuart_8_Uart_Ip_DmaRxCompleteCallback(void)
{
Lpuart_Uart_Ip_CompleteReceiveUsingDma(8);
}
void Lpuart_8_Uart_Ip_DmaTxCompleteCallback(void)
{
Lpuart_Uart_Ip_CompleteSendUsingDma(8);
}
#endif
#endif
#if (LPUART_UART_IP_NUMBER_OF_INSTANCES > 9U)
#ifdef LPUART_IP_9
void Lpuart_9_Uart_Ip_DmaRxCompleteCallback(void)
{
Lpuart_Uart_Ip_CompleteReceiveUsingDma(9);
}
void Lpuart_9_Uart_Ip_DmaTxCompleteCallback(void)
{
Lpuart_Uart_Ip_CompleteSendUsingDma(9);
}
#endif
#endif
#if (LPUART_UART_IP_NUMBER_OF_INSTANCES > 10U)
#ifdef LPUART_IP_10
void Lpuart_10_Uart_Ip_DmaRxCompleteCallback(void)
{
Lpuart_Uart_Ip_CompleteReceiveUsingDma(10);
}
void Lpuart_10_Uart_Ip_DmaTxCompleteCallback(void)
{
Lpuart_Uart_Ip_CompleteSendUsingDma(10);
}
#endif
#endif
#if (LPUART_UART_IP_NUMBER_OF_INSTANCES > 11U)
#ifdef LPUART_IP_11
void Lpuart_11_Uart_Ip_DmaRxCompleteCallback(void)
{
Lpuart_Uart_Ip_CompleteReceiveUsingDma(11);
}
void Lpuart_11_Uart_Ip_DmaTxCompleteCallback(void)
{
Lpuart_Uart_Ip_CompleteSendUsingDma(11);
}
#endif
#endif
#if (LPUART_UART_IP_NUMBER_OF_INSTANCES > 12U)
#ifdef LPUART_IP_12
void Lpuart_12_Uart_Ip_DmaRxCompleteCallback(void)
{
Lpuart_Uart_Ip_CompleteReceiveUsingDma(12);
}
void Lpuart_12_Uart_Ip_DmaTxCompleteCallback(void)
{
Lpuart_Uart_Ip_CompleteSendUsingDma(12);
}
#endif
#endif
#if (LPUART_UART_IP_NUMBER_OF_INSTANCES > 13U)
#ifdef LPUART_IP_13
void Lpuart_13_Uart_Ip_DmaRxCompleteCallback(void)
{
Lpuart_Uart_Ip_CompleteReceiveUsingDma(13);
}
void Lpuart_13_Uart_Ip_DmaTxCompleteCallback(void)
{
Lpuart_Uart_Ip_CompleteSendUsingDma(13);
}
#endif
#endif
#if (LPUART_UART_IP_NUMBER_OF_INSTANCES > 14U)
#ifdef LPUART_IP_14
void Lpuart_14_Uart_Ip_DmaRxCompleteCallback(void)
{
Lpuart_Uart_Ip_CompleteReceiveUsingDma(14);
}
void Lpuart_14_Uart_Ip_DmaTxCompleteCallback(void)
{
Lpuart_Uart_Ip_CompleteSendUsingDma(14);
}
#endif
#endif
#if (LPUART_UART_IP_NUMBER_OF_INSTANCES > 15U)
#ifdef LPUART_IP_15
void Lpuart_15_Uart_Ip_DmaRxCompleteCallback(void)
{
Lpuart_Uart_Ip_CompleteReceiveUsingDma(15);
}
void Lpuart_15_Uart_Ip_DmaTxCompleteCallback(void)
{
Lpuart_Uart_Ip_CompleteSendUsingDma(15);
}
#endif
#endif
#endif /*(LPUART_UART_IP_HAS_DMA_ENABLED == STD_ON)*/
#define UART_STOP_SEC_CODE
/* @violates @ref Uart_c_REF_1 This violation is not fixed since the inclusion of Uart_MemMap.h is as per AUTOSAR requirement*/
#include "Uart_MemMap.h"
#ifdef __cplusplus
}
/** @} */
#endif