Quantcast
Channel: Forums - Recent Threads
Viewing all articles
Browse latest Browse all 262198

WEBENCH® Tools/CC2530: I doesn't get interrupt while using HAL_KEY api....

$
0
0

Part Number:CC2530

Tool/software: WEBENCH® Design Tools

I doesn't get interrupt while using HAL_KEY API

I also defined HAL_KEY_TRUE in preprocessor  pls help

void DEEPInitEndDevice( void )
{

P0SEL &= 0x3F; //LED configuration
P0DIR |= 0xC0;
P0_7=0;

HalKeyInit();
HalKeyConfig(TRUE,DEEP_KEY_CallBack);
}

HAL_ISR_FUNCTION( halKeyPort0Isr, P0INT_VECTOR )
{
HAL_ENTER_ISR();

if (P0IFG & BV(1))
{
P0IFG = ~(BV(1));
DEEP_KEY_CallBack(0,0);
}

P0IFG = 0x00;
IRCON &= 0xDF;

CLEAR_SLEEP_MODE();
HAL_EXIT_ISR();
}


static void DEEP_KEY_CallBack(uint8 keys, uint8 state)
{
P0_7=1; //Turn on LED when button was pressed

}

pls help....


Viewing all articles
Browse latest Browse all 262198

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>