Developing with ZBOSS for Zigbee
APS functions visible to applications

Modules

 APS common constants
 
 APS data service
 
 APS management service
 
 APS user payload
 

Data Structures

struct  zb_intrp_data_req_s
 INTRP-DATA.request structure. More...
 
struct  zb_intrp_data_ind_s
 INTRP-DATA.indication parameters. More...
 
struct  zb_mchan_intrp_data_confirm_s
 A multi-channel INTRP-DATA.confirm representation structure. More...
 

Macros

#define ZB_INTRP_BROADCAST_SHORT_ADDR   0xffffU
 Inter-PAN broadcast short network address.
 

Typedefs

typedef struct zb_intrp_data_req_s zb_intrp_data_req_t
 INTRP-DATA.request structure. More...
 
typedef struct zb_intrp_data_ind_s zb_intrp_data_ind_t
 INTRP-DATA.indication parameters. More...
 
typedef struct zb_mchan_intrp_data_confirm_s zb_mchan_intrp_data_confirm_t
 A multi-channel INTRP-DATA.confirm representation structure.
 
typedef zb_uint8_t(* zb_af_inter_pan_handler_t) (zb_uint8_t param, zb_uint8_t current_page, zb_uint8_t current_channel)
 

Enumerations

enum  zb_intrp_addr_mode_e { ZB_INTRP_ADDR_GROUP = 0x01, ZB_INTRP_ADDR_NETWORK = 0x02, ZB_INTRP_ADDR_IEEE = 0x03 }
 Valid values for inter-PAN destination address mode. More...
 

Functions

void zboss_enable_interpan_with_chan_change (void)
 Enable interpan procedure. This allows to send interpan frames at multiple channels and register handler to receive interpan frames.
 
zb_ret_t zb_intrp_data_request_with_chan_change (zb_bufid_t buffer, zb_channel_page_t channel_page_mask, zb_uint32_t chan_wait_ms, zb_callback_t cb)
 Make INTRP-DATA request at multiple channels with time given as chan_wait_ms to wait for response packets. Can be used after zboss_enable_interpan_with_chan_change() was called. More...
 
void zb_af_interpan_set_data_indication (zb_af_inter_pan_handler_t cb)
 Register inter-pan indication callback, called when inter-pan packet is received. Can be used after zboss_enable_interpan_with_chan_change() was called. More...
 
void zb_intrp_data_request (zb_uint8_t param)
 Make INTRP-DATA request. More...
 

Detailed Description

Typedef Documentation

◆ zb_af_inter_pan_handler_t

typedef zb_uint8_t(* zb_af_inter_pan_handler_t) (zb_uint8_t param, zb_uint8_t current_page, zb_uint8_t current_channel)

Inter-pan packet handler

Parameters
param- index of buffer with inter-pan packet command
current_page- channel page at which packet was received
current_channel- channel at which packet was received
Returns
status (see zb_bool_t)

◆ zb_intrp_data_ind_t

INTRP-DATA.indication parameters.

See also
SE spec, subclause B.3.3.

◆ zb_intrp_data_req_t

INTRP-DATA.request structure.

This structure passed to zb_intrp_data_request() in the packet buffer parameter.

See also
SE spec, clause B.3.

Enumeration Type Documentation

◆ zb_intrp_addr_mode_e

Valid values for inter-PAN destination address mode.

See also
SE spec, subclause B.3.1.
Enumerator
ZB_INTRP_ADDR_GROUP 

16-bit group address

ZB_INTRP_ADDR_NETWORK 

16-bit NWK address

ZB_INTRP_ADDR_IEEE 

64-bit extended device address

Function Documentation

◆ zb_af_interpan_set_data_indication()

void zb_af_interpan_set_data_indication ( zb_af_inter_pan_handler_t  cb)

Register inter-pan indication callback, called when inter-pan packet is received. Can be used after zboss_enable_interpan_with_chan_change() was called.

Parameters
cb- callback function to be called when inter-pan packet is received.
Note
If packet is processed in the callback function and no longer shall be processed by the stack, callback function shall free buffer and return ZB_TRUE. Return ZB_FALSE otherwise. Buffer has data put in the beginning of the buffer with inter-pan header truncated and contains zb_intrp_data_ind_t given as buffer's parameter.

◆ zb_intrp_data_request()

void zb_intrp_data_request ( zb_uint8_t  param)

Make INTRP-DATA request.

Assumes buffer contains data in its main part, and INTRP-DATA.request parameters in buffer's parameter (represented as zb_intrp_data_req_s structure).

Parameters
param- reference (index) of the packet buffer.
See also
SE spec, subclause B.5.1.

◆ zb_intrp_data_request_with_chan_change()

zb_ret_t zb_intrp_data_request_with_chan_change ( zb_bufid_t  buffer,
zb_channel_page_t  channel_page_mask,
zb_uint32_t  chan_wait_ms,
zb_callback_t  cb 
)

Make INTRP-DATA request at multiple channels with time given as chan_wait_ms to wait for response packets. Can be used after zboss_enable_interpan_with_chan_change() was called.

Assumes buffer contains data in its main part, and INTRP-DATA.request parameters in buffer's parameter (represented as zb_intrp_data_req_s structure).

Parameters
buffer- reference (index) of the packet buffer.
channel_page_mask- Channel Page structure - binary encoded channel page and channels mask as list of channels to send packet at.
chan_wait_ms- time in milliseconds to wait at channel after the packet is sent.
cb- user callback function called after the procedure is finished.
Returns
Returns RET_OK if procedure has started successfully, RET_BUSY if procedure is on-going, RET_ERROR if failed to start or procedure was not enabled, RET_INVALID_PARAMETER if one of function's arguments is invalid.
Note
cb buffer's parameter contains status which can be obtained using zb_buf_get_status function, RET_OK if packet was successfully sent at at least one channel, RET_ERROR otherwise. zb_mchan_intrp_data_confirm_t is put as buffer's parameter. User is to free the buffer in the callback, if no callback is given, buffer is freed internally.