nRF5 SDK for Thread and Zigbee v1.0.0
Choose documentation:
Generic configuration commands

Functions

static void cmd_zb_eui64 (nrf_cli_t const *p_cli, size_t argc, char **argv)
 Get the EUI64 address of the Zigbee device. More...
 
static void cmd_zb_state (nrf_cli_t const *p_cli, size_t argc, char **argv)
 Set or get Zigbee role of the device. More...
 
static void cmd_zb_zigbee (nrf_cli_t const *p_cli, size_t argc, char **argv)
 Start the commissioning process. More...
 
static void cmd_zb_short (nrf_cli_t const *p_cli, size_t argc, char **argv)
 Get the short 16-bit address of the Zigbee device. More...
 
static void cmd_zb_extpanid_set_cb (zb_uint8_t param)
 Callback which is called on extpanid set. More...
 
static void cmd_zb_extpanid_get_cb (zb_uint8_t param)
 Callback which is called on extpanid get. More...
 
static void cmd_zb_extpanid (nrf_cli_t const *p_cli, size_t argc, char **argv)
 Set or get the Zigbee Extended Pan ID value. More...
 
static void cmd_zb_channel (nrf_cli_t const *p_cli, size_t argc, char **argv)
 Set or get 802.15.4 channel. More...
 
static void cmd_zb_fem (nrf_cli_t const *p_cli, size_t argc, char **argv)
 Activate or deactivate FEM. More...
 
 NRF_CLI_CMD_REGISTER (state, NULL,"state", cmd_zb_state)
 Command set array.
 
 NRF_CLI_CMD_REGISTER (eui64, NULL,"eui64", cmd_zb_eui64)
 
 NRF_CLI_CMD_REGISTER (short, NULL,"short", cmd_zb_short)
 
 NRF_CLI_CMD_REGISTER (extpanid, NULL,"extpanid", cmd_zb_extpanid)
 
 NRF_CLI_CMD_REGISTER (zigbee, NULL,"zigbee", cmd_zb_zigbee)
 
 NRF_CLI_CMD_REGISTER (channel, NULL,"channel", cmd_zb_channel)
 
 NRF_CLI_CMD_REGISTER (fem, NULL,"fem", cmd_zb_fem)
 

Variables

static zb_nwk_device_type_t m_default_role = ZB_NWK_DEVICE_TYPE_ROUTER
 
static zb_bool_t m_stack_is_started = ZB_FALSE
 

Detailed Description

Function Documentation

static void cmd_zb_channel ( nrf_cli_t const *  p_cli,
size_t  argc,
char **  argv 
)
static

Set or get 802.15.4 channel.

channel <n>
Precondition
Setting only before starting zigbee.

If the optional argument is not provided, get the current number and bitmask of the channel.

If the optional argument is provided:

  • If n is in [11:26] range, set to that channel.
  • Otherwise, treat n as bitmask (logical or of a single bit shifted by channel number).

Example:

uart_cli:~$ channel 0x110000
Setting channel bitmask to 110000
Done
static void cmd_zb_eui64 ( nrf_cli_t const *  p_cli,
size_t  argc,
char **  argv 
)
static

Get the EUI64 address of the Zigbee device.

uart_cli:~$ eui64
0b010eaafd745dfa
Done
static void cmd_zb_extpanid ( nrf_cli_t const *  p_cli,
size_t  argc,
char **  argv 
)
static

Set or get the Zigbee Extended Pan ID value.

extpanid [<h:id>]
Precondition
Setting only before starting zigbee. Reading only after starting zigbee.

If the optional argument is not provided, gets the extended PAN ID of the joined network.

If the optional argument is provided, gets the extended PAN ID to id.

static void cmd_zb_extpanid_get_cb ( zb_uint8_t  param)
static

Callback which is called on extpanid get.

Parameters
[in]paramReference to Zigbee stack buffer.
static void cmd_zb_extpanid_set_cb ( zb_uint8_t  param)
static

Callback which is called on extpanid set.

Parameters
[in]paramReference to Zigbee stack buffer.
static void cmd_zb_fem ( nrf_cli_t const *  p_cli,
size_t  argc,
char **  argv 
)
static

Activate or deactivate FEM.

fem <enable|disable>

The configuration of the FEM is the default one (defined at compile time, see the define NRF_802154_FEM_DEFAULT_SETTINGS).

For more information, see the description of the FEM on the 802.15.4 radio driver Wiki.

static void cmd_zb_short ( nrf_cli_t const *  p_cli,
size_t  argc,
char **  argv 
)
static

Get the short 16-bit address of the Zigbee device.

uart_cli:~$ short
0000
Done
static void cmd_zb_state ( nrf_cli_t const *  p_cli,
size_t  argc,
char **  argv 
)
static

Set or get Zigbee role of the device.

state [<role>]
Precondition
Setting only before starting zigbee. Reading only after starting zigbee.

If the optional argument is not provided, get the state of the device.
Returns:

  • zc if it is a coordinator,
  • zr it it is a router,
  • zed if it is an end device.

If the optional argument is provided, set the device role to role. Can be either zc or zr.

Note
Zigbee End Device is not currently supported on the CLI Agent.
static void cmd_zb_zigbee ( nrf_cli_t const *  p_cli,
size_t  argc,
char **  argv 
)
static

Start the commissioning process.

uart_cli:~$ zigbee start
Started coordinator
Done