This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Tivaware 2.1.0.12575 Assert Bug in TimerConfigure?

I enabled assert checking in Tivaware and got an Assert in TimerConfigure().

The assert in question starts at line #359 in "timer.c" and happens when I configure a timer for a split pair with both A and B timers configured as capture count up:

ASSERT(((ui32Config & 0xff000000) != TIMER_CFG_SPLIT_PAIR) ||
((((ui32Config & 0x000000ff) == TIMER_CFG_A_ONE_SHOT) ||
((ui32Config & 0x000000ff) == TIMER_CFG_A_ONE_SHOT_UP) ||
((ui32Config & 0x000000ff) == TIMER_CFG_A_PERIODIC) ||
((ui32Config & 0x000000ff) == TIMER_CFG_A_PERIODIC_UP) ||
((ui32Config & 0x000000ff) == TIMER_CFG_A_CAP_COUNT) ||
((ui32Config & 0x000000ff) == TIMER_CFG_A_CAP_TIME) ||
((ui32Config & 0x000000ff) == TIMER_CFG_A_PWM)) &&
(((ui32Config & 0x0000ff00) == TIMER_CFG_B_ONE_SHOT) ||
((ui32Config & 0x0000ff00) == TIMER_CFG_B_ONE_SHOT_UP) ||
((ui32Config & 0x0000ff00) == TIMER_CFG_B_PERIODIC) ||
((ui32Config & 0x0000ff00) == TIMER_CFG_B_PERIODIC_UP) ||
((ui32Config & 0x0000ff00) == TIMER_CFG_B_CAP_COUNT) ||
((ui32Config & 0x0000ff00) == TIMER_CFG_B_CAP_COUNT_UP) ||
((ui32Config & 0x0000ff00) == TIMER_CFG_B_CAP_TIME) ||
((ui32Config & 0x0000ff00) == TIMER_CFG_B_CAP_TIME_UP) ||
((ui32Config & 0x0000ff00) == TIMER_CFG_B_PWM))));

I think the Assert is missing 2 checks for timer A and should have been written as:

ASSERT(((ui32Config & 0xff000000) != TIMER_CFG_SPLIT_PAIR) ||
((((ui32Config & 0x000000ff) == TIMER_CFG_A_ONE_SHOT) ||
((ui32Config & 0x000000ff) == TIMER_CFG_A_ONE_SHOT_UP) ||
((ui32Config & 0x000000ff) == TIMER_CFG_A_PERIODIC) ||
((ui32Config & 0x000000ff) == TIMER_CFG_A_PERIODIC_UP) ||
((ui32Config & 0x000000ff) == TIMER_CFG_A_CAP_COUNT) ||
((ui32Config & 0x000000ff) == TIMER_CFG_A_CAP_COUNT_UP) || // Missing from OEM version
((ui32Config & 0x000000ff) == TIMER_CFG_A_CAP_TIME) ||
((ui32Config & 0x000000ff) == TIMER_CFG_A_CAP_TIME_UP) || // Missing from OEM version
((ui32Config & 0x000000ff) == TIMER_CFG_A_PWM)) &&
(((ui32Config & 0x0000ff00) == TIMER_CFG_B_ONE_SHOT) ||
((ui32Config & 0x0000ff00) == TIMER_CFG_B_ONE_SHOT_UP) ||
((ui32Config & 0x0000ff00) == TIMER_CFG_B_PERIODIC) ||
((ui32Config & 0x0000ff00) == TIMER_CFG_B_PERIODIC_UP) ||
((ui32Config & 0x0000ff00) == TIMER_CFG_B_CAP_COUNT) ||
((ui32Config & 0x0000ff00) == TIMER_CFG_B_CAP_COUNT_UP) ||
((ui32Config & 0x0000ff00) == TIMER_CFG_B_CAP_TIME) ||
((ui32Config & 0x0000ff00) == TIMER_CFG_B_CAP_TIME_UP) ||
((ui32Config & 0x0000ff00) == TIMER_CFG_B_PWM))));

Can someone confirm if this is a bug?

Thanks!

Dominic