Timer in 2073x

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
Anonymous
Not applicable

I have some simple questions about timers in 2073x.

How many HW timer does 2073x soc have?

How many SW timer does WICED Smart SDK 2.x provide?

From the SDK, i can see total four "timer".

Fine time and normal timer;

Application Timer: emconinfo_getAppTimerId(), emconinfo_setAppTimerId() in emconinfo.h

Connection Idle timer: blecm_startConnIdleTimer(), blecm_stopConnIdleTimer() in blecm.h

And in hello sensor app, i noticed below usage and don't understand.

void bleprofile_StopConnIdleTimer(void)

{

    if(emconinfo_getAppTimerId() >= 0)

    {

        blecm_stopConnIdleTimer();

        emconinfo_setAppTimerId(-1);

        ble_trace0("profile:idletimer stopped");

    }

}

I'm a little confused about these timers.

Can someone clarify?

thanks a lot

0 Likes
1 Solution

I ran this past the developers today, and here is what they came back with:

1.

There are actually two HW timers, but one is used by the firmware exclusively.

2.

All timers mux off of the same system timer.

3.

These are used by the stack, so disregard references to them within bleapp.h:

#define  BLEAPP_APP_TIMER_ADV                         0x1

#define  BLEAPP_APP_TIMER_CONN_IDLE            0x2

#define  BLEAPP_APP_TIMER_DIRECT_ADV          0x3

#define  BLEAPP_APP_TIMER_SCAN                       0x4

#define  BLEAPP_APP_TIMER_CONN                       0x5

Yes on your understanding as noted at the bottom of item 3 above.

With regards to the last portion of your questions, emconinfo_getAppTimerId() is used by the stack, disregard.

vik86 j.t

View solution in original post

0 Likes
2 Replies