Esempio n. 1
0
//*****************************************************************************
//
//! \InterruptTestTerm
//! Performs termination processing.
//! This function is called once the test completes to tidy up as required.
//!
//! \param None.
//!
//! \return None.
//
//*****************************************************************************
static void
InterruptTestTerm(void)
{

    //
    // Unhook our interrupt handlers if they are still hooked.
    //
    TimerIntUnregister(TIMERA0_BASE, TIMER_A);
    TimerIntUnregister(TIMERA1_BASE, TIMER_A);
    TimerIntUnregister(TIMERA2_BASE, TIMER_A);

    //
    // Restore the original timer interrupt priorities and priority group
    // settings.
    //
    MAP_IntPriorityGroupingSet(g_lPriorityGrouping);
    MAP_IntPrioritySet(INT_TIMERA0A, (unsigned char)g_ulTimer0APriority);
    MAP_IntPrioritySet(INT_TIMERA1A, (unsigned char)g_ulTimer1APriority);

    //
    // Reset and Disable the timer blocks
    //
    MAP_PRCMPeripheralReset(PRCM_TIMERA0);
    MAP_PRCMPeripheralReset(PRCM_TIMERA1);
    MAP_PRCMPeripheralReset(PRCM_TIMERA2);

    MAP_PRCMPeripheralClkDisable(PRCM_TIMERA0, PRCM_RUN_MODE_CLK);
    MAP_PRCMPeripheralClkDisable(PRCM_TIMERA1, PRCM_RUN_MODE_CLK);
    MAP_PRCMPeripheralClkDisable(PRCM_TIMERA2, PRCM_RUN_MODE_CLK);

}
void CommutationControllerClass::releasePeripherals()
{
	TimerIntDisable(TIMER_BASE, TIMER_TIMA_TIMEOUT);
	TimerIntUnregister(TIMER_BASE, TIMER_A);
	TimerDisable(TIMER_BASE, TIMER_A);
	SysCtlPeripheralDisable(SYSCTL_PERIPH_TIMER);
}
Esempio n. 3
0
//*****************************************************************************
//
//! Is the handle for the Timer1A
//!
//! This function change the level of the pin PE3 to low.
//!
//! \return none.
//
//*****************************************************************************
void
HandleTrigger(){

	TimerIntClear(TIMER1_BASE,TIMER_TIMA_TIMEOUT);
	GPIOPinWrite(GPIO_PORTE_BASE, GPIO_PIN_3,0);
	TimerIntUnregister(TIMER1_BASE,TIMER_A);
	TimerDisable(TIMER1_BASE,TIMER_A);

}