INTERRUPT: Methods

INTERRUPT

INTERRUPT
Methods
DAVE_APP_VERSION_t INTERRUPT_GetAppVersion (void)
 Get INTERRUPT APP version.
INTERRUPT_STATUS_t INTERRUPT_Init (const INTERRUPT_t *const handler)
 Initializes INTERRUPT APP instance.
__STATIC_INLINE void INTERRUPT_Enable (const INTERRUPT_t *const handler)
 Enables the IRQ.
__STATIC_INLINE void INTERRUPT_Disable (const INTERRUPT_t *const handler)
 Disables the IRQ.
__STATIC_INLINE uint32_t INTERRUPT_GetPending (const INTERRUPT_t *const handler)
 Get the pending IRQ.
__STATIC_INLINE void INTERRUPT_SetPending (const INTERRUPT_t *const handler)
 Set the IRQ to pending state.
__STATIC_INLINE void INTERRUPT_ClearPending (const INTERRUPT_t *const handler)
 Clears the pending status of the IRQ.
__STATIC_INLINE uint32_t INTERRUPT_GetActive (const INTERRUPT_t *const handler)
 Get current running active status of the IRQ. This API is applicable only for XMC4000 devices.

Methods


Function Documentation

__STATIC_INLINE void INTERRUPT_ClearPending ( const INTERRUPT_t *const  handler)

Clears the pending status of the IRQ.

Parameters:
handleConstant pointer to constant structure of type INTERRUPT_t
Returns:
None

Example: Pre-requisite: Instantiate two instances of INTERRUPT APP

  #include <DAVE.h>

  uint32_t pend_IRQ;
  int main(void)
  {
    DAVE_Init(); // INTERRUPT_Init() is called within DAVE_Init()
    INTERRUPT_Enable(&INTERRUPT_0);
    while(1)
    {}
    return 0;
  }

  void MyISR_handler(void)
  {
    INTERRUPT_Enable(&INTERRUPT_1);
    INTERRUPT_SetPending(&INTERRUPT_1);
    pend_IRQ = INTERRUPT_GetPending(&INTERRUPT_1);
    if(pend_IRQ)
    {
      INTERRUPT_Disable(&INTERRUPT_0);
      INTERRUPT_ClearPending(&INTERRUPT_1);
    }
  }


Definition at line 324 of file INTERRUPT.h.

References INTERRUPT::node.

__STATIC_INLINE void INTERRUPT_Disable ( const INTERRUPT_t *const  handler)

Disables the IRQ.

Parameters:
handleConstant pointer to constant structure of type INTERRUPT_t
Returns:
None

Example: Pre-requisite: Instantiate one instance of INTERRUPT APP

  #include <DAVE.h>

  int main(void)
  {
    DAVE_Init(); // INTERRUPT_Init() is called within DAVE_Init()
    INTERRUPT_Disable(&INTERRUPT_0);
    while(1)
    {}
    return 0;
  }


Definition at line 235 of file INTERRUPT.h.

References INTERRUPT::node.

__STATIC_INLINE void INTERRUPT_Enable ( const INTERRUPT_t *const  handler)

Enables the IRQ.

Parameters:
handleConstant pointer to constant structure of type INTERRUPT_t
Returns:
None

Example: Pre-requisite: Instantiate one instance of INTERRUPT APP

  #include <DAVE.h>

  int main(void)
  {
    DAVE_Init(); // INTERRUPT_Init() is called within DAVE_Init()
    INTERRUPT_Enable(&INTERRUPT_0);
    while(1)
    {}
    return 0;
  }


Definition at line 210 of file INTERRUPT.h.

References INTERRUPT::node.

Referenced by INTERRUPT_Init().

__STATIC_INLINE uint32_t INTERRUPT_GetActive ( const INTERRUPT_t *const  handler)

Get current running active status of the IRQ. This API is applicable only for XMC4000 devices.

Parameters:
handleConstant pointer to constant structure of type INTERRUPT_t
Returns:
uint32_t current active running IRQ node

Example: Pre-requisite: Instantiate one instance of INTERRUPT APP

  #include <DAVE.h>

  int main(void)
  {
    uint32_t Status;
    DAVE_Init(); // INTERRUPT_Init() is called within DAVE_Init()
    Status = INTERRUPT_GetActive(&INTERRUPT_0);
    while(1)
    {}
    return 0;
  }


Definition at line 352 of file INTERRUPT.h.

References INTERRUPT::node.

DAVE_APP_VERSION_t INTERRUPT_GetAppVersion ( void  )

Get INTERRUPT APP version.

Returns:
DAVE_APP_VERSION_t APP version information (major, minor and patch number)
Description:
The function can be used to check application software compatibility with a specific version of the APP.
 #include <DAVE.h>

 int main(void)
 {
   DAVE_APP_VERSION_t version;
   DAVE_Init();
   version = INTERRUPT_GetAppVersion();
   if(version.major != 4U)
   {
   }
   while(1)
   {}
   return 0;
 }

Definition at line 79 of file INTERRUPT.c.

__STATIC_INLINE uint32_t INTERRUPT_GetPending ( const INTERRUPT_t *const  handler)

Get the pending IRQ.

Parameters:
handleConstant pointer to constant structure of type INTERRUPT_t
Returns:
uint32_t IRQ node

Example: Pre-requisite: Instantiate one instance of INTERRUPT APP

  #include <DAVE.h>

  int main(void)
  {
    uint32_t Status;
    DAVE_Init(); // INTERRUPT_Init() is called within DAVE_Init()
    Status = INTERRUPT_GetPending(&INTERRUPT_0);
    while(1)
    {}
    return 0;
  }


Definition at line 261 of file INTERRUPT.h.

References INTERRUPT::node.

INTERRUPT_STATUS_t INTERRUPT_Init ( const INTERRUPT_t *const  handler)

Initializes INTERRUPT APP instance.

Parameters:
handleConstant pointer to constant structure of type INTERRUPT_t
Returns:
INTERRUPT_STATUS_t

Example: Pre-requisite: Instantiate one instance of INTERRUPT APP

  #include <DAVE.h>

  int main(void)
  {
    DAVE_Init();  // INTERRUPT_Init(&INTERRUPT_0) is called within DAVE_Init()
    while(1)
    {}
    return 0;
  }


Definition at line 93 of file INTERRUPT.c.

References INTERRUPT::enable_at_init, INTERRUPT_Enable(), INTERRUPT_STATUS_SUCCESS, INTERRUPT::irqctrl, INTERRUPT::node, INTERRUPT::priority, and INTERRUPT::subpriority.

__STATIC_INLINE void INTERRUPT_SetPending ( const INTERRUPT_t *const  handler)

Set the IRQ to pending state.

Parameters:
handleConstant pointer to constant structure of type INTERRUPT_t
Returns:
None

Example: Pre-requisite: Instantiate one instance of INTERRUPT APP

  #include <DAVE.h>

  int main(void)
  {
    DAVE_Init(); // INTERRUPT_Init() is called within DAVE_Init()
    INTERRUPT_SetPending(&INTERRUPT_0);
    while(1)
    {}
    return 0;
  }


Definition at line 286 of file INTERRUPT.h.

References INTERRUPT::node.