Skip to content

Instantly share code, notes, and snippets.

@ksksue
Last active August 29, 2015 14:10
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ksksue/bcdb97dd44a9a2e1731a to your computer and use it in GitHub Desktop.
Save ksksue/bcdb97dd44a9a2e1731a to your computer and use it in GitHub Desktop.
#include "app_scheduler.h"
...
// YOUR_JOB: Modify these according to requirements (e.g. if other event types are to pass through
// the scheduler).
#define SCHED_MAX_EVENT_DATA_SIZE sizeof(app_timer_event_t) /**< Maximum size of scheduler events. Note that scheduler BLE stack events do not contain any data, as the events are being pulled from the stack in the event handler. */
#define SCHED_QUEUE_SIZE 10 /**< Maximum number of events in the scheduler queue. */
...
/**@brief Function for the Event Scheduler initialization.
*/
static void scheduler_init(void)
{
APP_SCHED_INIT(SCHED_MAX_EVENT_DATA_SIZE, SCHED_QUEUE_SIZE);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment