lpcware

Wrong LPC11xx Chip_TIMER_ClearCapture function

Discussion created by lpcware Employee on Jun 15, 2016
Latest reply on Jun 15, 2016 by lpcware
Content originally posted in LPCWare by R2D2 on Tue Jul 14 03:25:34 MST 2015
timer_11xx.h of lpcopen_v2_00a_lpcxpresso_nxp_lpcxpresso_11c24.zip
is including a wrong clear capture interrupt function:

STATIC INLINE void Chip_TIMER_ClearCapture(LPC_TIMER_T *pTMR, int8_t capnum)
{
pTMR->IR = [color=#f00](0x10 << capnum);[/color]
}

Corrected:

STATIC INLINE void Chip_TIMER_ClearCapture(LPC_TIMER_T *pTMR, int8_t capnum)
{
pTMR->IR =[color=#090] TIMER_CAP_INT(capnum);[/color]
}

BTW: the new 2015 version lpcopen_2_17_lpcxpresso_nxp_lpcxpresso_1125.zip is including the same error  :~  :((  :quest:

So probably all LPC11 versions are including this surprise...

Outcomes