This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts
This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Question of nRF51822 BLE Stack API ....

static conn_mw_handler_t conn_mw_handler_get (uint8_t opcode)

Inside the function,

 for (i = 0; i <conn_mw_item_len; i ++) 
 {
     if (opcode == conn_mw_item [i] .opcode) 
     {
         fp_handler = conn_mw_item [i] .fp_handler; 
         break; 
     } 
 } 

After the comparison conn_mw_item [i] .opcode value, in the above source, and select "function pointer" value. This is the selected "function pointer value" fp_handler function.

err_code = fp_handler (p_rx_buf, rx_buf_len, p_tx_buf, p_tx_buf_len);

/ ** @ brief Connectivity middleware handlers table. * / static const conn_mw_item_t conn_mw_item [] = {

conn_mw_item [] = { has been defined within the various "function pointer set value".

and how each plays a role defined in conn_mw_item [] "function pointer", yet want to provide this technical information

Related