ACDC Senior Project v1.0.0
Senior Project for Textron Aviation
Loading...
Searching...
No Matches
ACDC_INTERRUPT.c File Reference

Implementation of general-purpose interrupt configuration functions. More...

#include "ACDC_INTERRUPT.h"
#include "ACDC_GPIO.h"

Functions

void INTERRUPT_Enable (IRQn_Type IRQn)
 Enables Interrupts for the specific vector IRQn.
 
void INTERRUPT_Disable (IRQn_Type IRQn)
 Disables Interrupts for the specific vector IRQn.
 
void INTERRUPT_SetPriority (IRQn_Type IRQn, uint8_t Priority)
 Sets the priority of the Interrupt vector IRQn.
 
void GPIO_INT_SetToInterrupt (const GPIO_TypeDef *GPIOx, uint16_t GPIO_PIN, GPIO_TriggerType TT_x)
 Enables Interrupts for GPIO_PIN on GPIOx. (Make sure to set GPIO_PIN as an Input)
 

Detailed Description

Implementation of general-purpose interrupt configuration functions.

This file provides functions for configuring and managing interrupts, including support for GPIO interrupts.

Author
Devin Marx
Version
0.1
Date
2023-11-02

The functions in this file enable the configuration of interrupts, allowing users to set up interrupt triggers on various sources, including GPIO pins.

Note
External interrupts are muxed, allowing the configuration of up to 16 concurrent interrupts. Refer to RM-210 for details.

Function Documentation

◆ GPIO_INT_SetToInterrupt()

void GPIO_INT_SetToInterrupt ( const GPIO_TypeDef * GPIOx,
uint16_t GPIO_PIN,
GPIO_TriggerType TT_x )

Enables Interrupts for GPIO_PIN on GPIOx. (Make sure to set GPIO_PIN as an Input)

Parameters
GPIOxPort of the GPIO (Ex. GPIOA, GPIOB, ...)
GPIO_PINDesired pin on port GPIOx (Ex. GPIO_PIN_0, GPIO_PIN_1, ...)
triggerTypeEdge that triggers the Interrupt (Ex. RISING_EDGE, FALLING_EDGE, RISING_AND_FALLING_EDGE)

◆ INTERRUPT_Disable()

void INTERRUPT_Disable ( IRQn_Type IRQn)

Disables Interrupts for the specific vector IRQn.

Parameters
IRQnInterrupt vector to disable

◆ INTERRUPT_Enable()

void INTERRUPT_Enable ( IRQn_Type IRQn)

Enables Interrupts for the specific vector IRQn.

Parameters
IRQnInterrupt vector to enable

◆ INTERRUPT_SetPriority()

void INTERRUPT_SetPriority ( IRQn_Type IRQn,
uint8_t Priority )

Sets the priority of the Interrupt vector IRQn.

Parameters
IRQnInterrupt vector
PriorityPriority of the IRQn vector (Value: 0-15 Lower value means higher priority)