nRF5 SDK v13.0.0
Data Structures | Typedefs | Enumerations | Functions
MAC task scheduler

Module for MAC task scheduling. More...

Data Structures

struct  mac_abstract_req_t
 MAC request descriptor. More...
 
struct  mac_scheduler_mem_t
 scheduler memory. More...
 

Typedefs

typedef void(* mac_task_handler_t )(void)
 MAC task handler prototype. More...
 
typedef void(* mac_req_handler_t )(mac_abstract_req_t *)
 MAC external requests queue task handler prototype. More...
 

Enumerations

enum  mac_req_id_t {
  MAC_PURGE_REQ_ID,
  MAC_DISASSOCIATE_REQ_ID,
  MAC_GET_REQ_ID,
  MAC_GTS_REQ_ID,
  MAC_RESET_REQ_ID,
  MAC_RX_ENABLE_REQ_ID,
  MAC_SCAN_REQ_ID,
  MAC_SET_REQ_ID,
  MAC_POLL_REQ_ID,
  MAC_START_REQ_ID,
  MAC_DATA_REQ_ID,
  MAC_ORPHAN_RESP_ID,
  MAC_REQS_AMOUNT
}
 Identifiers for external requests.
 
enum  mac_task_id_t {
  MAC_CSMA_CA_TASK_ID,
  MAC_START_TASK_ID,
  MAC_FP_TX_TASK_ID,
  MAC_DATA_DIR_CONF_ID,
  MAC_FP_RX_TASK_ID,
  MAC_ORPHAN_IND_ID,
  MAC_DISASSOC_IND_ID,
  MAC_SYNC_LOSS_IND_ID,
  MAC_GET_CONF_ID,
  MAC_SET_CONF_ID,
  MAC_REQ_QUEUE_TASK_ID,
  MAC_MEM_ALLOCATOR_TASK_ID,
  MAC_POLL_TASK_ID,
  MAC_SCAN_CONF_ID,
  MAC_TASKS_AMOUNT
}
 Identifiers for internal handlers. More...
 

Functions

void mac_init (void)
 Initialize MAC scheduler. More...
 
void mac_task_handler (void)
 MAC task handler. More...
 
void mac_request_schedule (mac_abstract_req_t *p_req)
 Scheduler request from some MAC primitive. More...
 
void mac_internal_task_post (mac_task_id_t id)
 Internal function of MAC API. More...
 
void mac_close_request (mac_abstract_req_t *p_req)
 Internal function of MAC API. More...
 

Detailed Description

Module for MAC task scheduling.

Typedef Documentation

typedef void(* mac_req_handler_t)(mac_abstract_req_t *)

MAC external requests queue task handler prototype.

Handler which will be called by the MAC scheduler inside corresponding task handler.

typedef void(* mac_task_handler_t)(void)

MAC task handler prototype.

Handler which will be called by the MAC scheduler.

Enumeration Type Documentation

Identifiers for internal handlers.

These handlers are used for private MAC task scheduling.

Function Documentation

void mac_close_request ( mac_abstract_req_t p_req)

Internal function of MAC API.

         Notifies mac scheduler that incoming request has been completely
         served and may be safely removed from MAC task queue.
Parameters
[in]p_reqPointer to a request structure.
void mac_init ( void  )

Initialize MAC scheduler.

Clean up MAC request's queue.

void mac_internal_task_post ( mac_task_id_t  id)

Internal function of MAC API.

         This function is used to post tasks between MAC primitives.
Parameters
[in]idMAC task ID.
void mac_request_schedule ( mac_abstract_req_t p_req)

Scheduler request from some MAC primitive.

Place request to MAC scheduler queue for a further handling.

Parameters
[in]p_reqPointer to a request structure.
void mac_task_handler ( void  )

MAC task handler.

Handler invokes a MAC primitives routine for a request according to the requests identification.


Documentation feedback | Developer Zone | Subscribe | Updated