Knight KE / Mbed OS Game_Master
Embed: (wiki syntax)

« Back to documentation index

thread_lowpower_api.h File Reference

thread_lowpower_api.h File Reference

Nanostack Thread lowpower probe implementation. More...

Go to the source code of this file.

Typedefs

typedef int( thread_lowpower_resp_cb )(uint8_t *destination_address, int8_t interface_id, uint8_t *metrics_ptr, uint16_t metrics_len)
 callback function that returns the received metrics

Functions

int thread_lowpower_metrics_management_request_send (int8_t interface_id, uint8_t *address, uint8_t series_id, uint8_t series_flags, uint16_t timeout, uint8_t *metrics_ptr, uint8_t metrics_len, thread_lowpower_resp_cb response_cb)
 Send lowpower data request for requesting low power metrics.
int thread_lowpower_test_probe_send (int8_t interface_id, uint8_t *destination_address, uint8_t *metrics_ptr, uint8_t metrics_len, thread_lowpower_resp_cb response_cb)
 DEPRECATED Send lowpower data request for requesting low power metrics.

Detailed Description

Nanostack Thread lowpower probe implementation.

Responsible for tasks like request link metrics by sending data requests.

Definition in file thread_lowpower_api.h.


Typedef Documentation

typedef int( thread_lowpower_resp_cb)(uint8_t *destination_address, int8_t interface_id, uint8_t *metrics_ptr, uint16_t metrics_len)

callback function that returns the received metrics

Parameters:
destination_addressaddress to which the lowpower query is sent
interface_idinterface_id of destination
metrics_ptrPointer to metrics
metrics_lenLength of metrics_ptr
Returns:
metrics_ptr if response received, NULL if no response is received
metrics_len length of the response received, 0 if NULL response is received

Definition at line 52 of file thread_lowpower_api.h.


Function Documentation

int thread_lowpower_metrics_management_request_send ( int8_t  interface_id,
uint8_t *  address,
uint8_t  series_id,
uint8_t  series_flags,
uint16_t  timeout,
uint8_t *  metrics_ptr,
uint8_t  metrics_len,
thread_lowpower_resp_cb  response_cb 
)

Send lowpower data request for requesting low power metrics.

Parameters:
interface_idInterface ID of the Thread network.
addressdestination ll64 address
series_idid of the query or series id
series_flagsquery type 0 for single probe
timeoutTimeout for the query 0 for single probe
metrics_ptrarray of metrics to be measured
metrics_lenlength of the metrics array
response_cbcallback function called to return values after execution
Returns:
0 if data request successfully initiated.

Definition at line 47 of file thread_lowpower_private_api.c.

int thread_lowpower_test_probe_send ( int8_t  interface_id,
uint8_t *  destination_address,
uint8_t *  metrics_ptr,
uint8_t  metrics_len,
thread_lowpower_resp_cb  response_cb 
)

DEPRECATED Send lowpower data request for requesting low power metrics.

use thread_lowpower_metrics_management_request_send instead

Parameters:
interface_idInterface ID of the Thread network.
destination_addressdestination ll64 address
metrics_ptrarray of metrics to be measured
metrics_lenlength of the metrics array
response_cbcallback function called to return values after execution
Returns:
0 if data request successfully initiated.

Definition at line 39 of file thread_lowpower_private_api.c.