Example #1
0
void RIT_IRQHandler(void){

	RIT_GetIntStatus(LPC_RIT);

	// Send LED SPI data


}
Example #2
0
File: main_m0.c Project: ciaa/EOPT
// Use Timer0 as CM0 in LPC43xx does not implement the Systick peripheral!
void M0_RIT_OR_WWDT_IRQHandler(void)
{
	if(RIT_GetIntStatus(LPC_RITIMER) == SET)
	{
		if(msec)msec--;
		NVIC_ClearPendingIRQ(M0_RITIMER_OR_WWDT_IRQn);
	}
}
Example #3
0
int _RIT_GetIntStatus(uint8_t * args)
{
    uint8_t * arg_ptr;
    LPC_RIT_TypeDef* RITx;

    if ((arg_ptr = (uint8_t *) strtok(NULL, " ")) == NULL) return 1;
    RITx = (LPC_RIT_TypeDef*) strtoul((char *) arg_ptr, NULL, 16);

    sprintf((char *) str, "%x\r\n", (unsigned int) RIT_GetIntStatus(RITx));
    writeUSBOutString(str);
    return 0;
}
Example #4
0
void RIT_IRQHandler()
{
	RIT_GetIntStatus(LPC_RIT); //call this to clear interrupt flag
	if(LEDStatus == ENABLE)
	{
		LEDStatus = DISABLE;
		//turn off LED
		GPIO_ClearValue(2,(1<<2));
		_DBG_(menu2);
	}
	else
	{
		LEDStatus = ENABLE;
		//turn off LED
		GPIO_SetValue(2,(1<<2));
		_DBG_(menu1);
	}
}
Example #5
0
/*********************************************************************//**
 * @brief		RIT interrupt handler sub-routine
 * @param[in]	None
 * @return 		None
 **********************************************************************/
void RIT_IRQHandler(void)
{
	RIT_GetIntStatus(LPC_RIT); //call this to clear interrupt flag
	if(LEDStatus == ENABLE)
	{
		LEDStatus = DISABLE;
#ifdef MCB_LPC_1768
		//turn off LED
		GPIO_ClearValue(2,(1<<2));
#elif defined(IAR_LPC_1768)
		GPIO_SetValue(1,(1<<25));
#endif
	}
	else
	{
		LEDStatus = ENABLE;
#ifdef MCB_LPC_1768
		//turn off LED
		GPIO_SetValue(2,(1<<2));
#elif defined(IAR_LPC_1768)
		GPIO_ClearValue(1,(1<<25));
#endif
	}
}
Example #6
0
File: timer.c Project: Q-Mart/EMPR
/* Get RIT Interrupt Status 
* N.B. this used to return `IntStatus', but now returns int
* where SET=1 and RESET=0 (as defined in `lpc_types.h'
*/
int timer_get_rit_status(void)
{
    return (int)RIT_GetIntStatus(LPC_RIT);
}
/*********************************************************************//**
 * @brief		RIT interrupt handler sub-routine
 * @param[in]	None
 * @return 		None
 **********************************************************************/
void RIT_IRQHandler(void)
{
	RIT_GetIntStatus(LPC_RIT); //call this to clear interrupt flag
	LPC_GPIO0->FIOPIN ^= _BIT(10); //Toggle P0.10 led
}