/*
* -------------------------------------------
- * MSP432 DriverLib - v01_04_00_18
+ * MSP432 DriverLib - v3_10_00_09
* -------------------------------------------
*
* --COPYRIGHT--,BSD,BSD
- * Copyright (c) 2015, Texas Instruments Incorporated
+ * Copyright (c) 2014, Texas Instruments Incorporated
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
#include <debug.h>
#include <cpu.h>
#include <interrupt.h>
+#include <hw_memmap.h>
//*****************************************************************************
//
//
// Set the priority grouping.
//
- SCB->AIRCR = SCB_AIRCR_VECTKEY_M | g_pulPriority[bits];
+ SCB->AIRCR = SCB_AIRCR_VECTKEY_Msk | g_pulPriority[bits];
}
uint32_t Interrupt_getPriorityGrouping(void)
//
// Enable the MemManage interrupt.
//
- SCB->SHCSR |= SCB_SHCSR_MEMFAULTENA;
+ SCB->SHCSR |= SCB_SHCSR_MEMFAULTENA_Msk;
} else if (interruptNumber == FAULT_BUS)
{
//
// Enable the bus fault interrupt.
//
- SCB->SHCSR |= SCB_SHCSR_BUSFAULTENA;
+ SCB->SHCSR |= SCB_SHCSR_BUSFAULTENA_Msk;
} else if (interruptNumber == FAULT_USAGE)
{
//
// Enable the usage fault interrupt.
//
- SCB->SHCSR |= SCB_SHCSR_USGFAULTENA;
+ SCB->SHCSR |= SCB_SHCSR_USGFAULTENA_Msk;
} else if (interruptNumber == FAULT_SYSTICK)
{
//
//
// Disable the MemManage interrupt.
//
- SCB->SHCSR &= ~(SCB_SHCSR_MEMFAULTENA);
+ SCB->SHCSR &= ~(SCB_SHCSR_MEMFAULTENA_Msk);
} else if (interruptNumber == FAULT_BUS)
{
//
// Disable the bus fault interrupt.
//
- SCB->SHCSR &= ~(SCB_SHCSR_BUSFAULTENA);
+ SCB->SHCSR &= ~(SCB_SHCSR_BUSFAULTENA_Msk);
} else if (interruptNumber == FAULT_USAGE)
{
//
// Disable the usage fault interrupt.
//
- SCB->SHCSR &= ~(SCB_SHCSR_USGFAULTENA);
+ SCB->SHCSR &= ~(SCB_SHCSR_USGFAULTENA_Msk);
} else if (interruptNumber == FAULT_SYSTICK)
{
//
//
// Check the MemManage interrupt.
//
- ulRet = SCB->SHCSR & SCB_SHCSR_MEMFAULTENA;
+ ulRet = SCB->SHCSR & SCB_SHCSR_MEMFAULTENA_Msk;
} else if (interruptNumber == FAULT_BUS)
{
//
// Check the bus fault interrupt.
//
- ulRet = SCB->SHCSR & SCB_SHCSR_BUSFAULTENA;
+ ulRet = SCB->SHCSR & SCB_SHCSR_BUSFAULTENA_Msk;
} else if (interruptNumber == FAULT_USAGE)
{
//
// Check the usage fault interrupt.
//
- ulRet = SCB->SHCSR & SCB_SHCSR_USGFAULTENA;
+ ulRet = SCB->SHCSR & SCB_SHCSR_USGFAULTENA_Msk;
} else if (interruptNumber == FAULT_SYSTICK)
{
//
//
// Pend the NMI interrupt.
//
- SCB->ICSR |= SCB_ICSR_NMIPENDSET;
+ SCB->ICSR |= SCB_ICSR_NMIPENDSET_Msk;
} else if (interruptNumber == FAULT_PENDSV)
{
//
// Pend the PendSV interrupt.
//
- SCB->ICSR |= SCB_ICSR_PENDSVSET;
+ SCB->ICSR |= SCB_ICSR_PENDSVSET_Msk;
} else if (interruptNumber == FAULT_SYSTICK)
{
//
// Pend the SysTick interrupt.
//
- SCB->ICSR |= SCB_ICSR_PENDSTSET;
+ SCB->ICSR |= SCB_ICSR_PENDSTSET_Msk;
} else if (interruptNumber >= 16)
{
//
//
// Unpend the PendSV interrupt.
//
- SCB->ICSR |= SCB_ICSR_PENDSVCLR;
+ SCB->ICSR |= SCB_ICSR_PENDSVCLR_Msk;
} else if (interruptNumber == FAULT_SYSTICK)
{
//
// Unpend the SysTick interrupt.
//
- SCB->ICSR |= SCB_ICSR_PENDSTCLR;
+ SCB->ICSR |= SCB_ICSR_PENDSTCLR_Msk;
} else if (interruptNumber >= 16)
{
//
void Interrupt_enableSleepOnIsrExit(void)
{
- SCB->SCR |= SCB_SCR_SLEEPONEXIT;
+ SCB->SCR |= SCB_SCR_SLEEPONEXIT_Msk;
}
void Interrupt_disableSleepOnIsrExit(void)
{
- SCB->SCR &= ~SCB_SCR_SLEEPONEXIT;
+ SCB->SCR &= ~SCB_SCR_SLEEPONEXIT_Msk;
}