17 #ifndef WISUNINTERFACE_H 18 #define WISUNINTERFACE_H 20 #include "MeshInterfaceNanostack.h" 43 uint8_t global_addr[16];
45 uint8_t link_local_addr[16];
47 uint8_t parent_addr[16];
73 WISUN_SECONDARY_PARENT,
74 WISUN_CANDIDATE_PARENT,
83 uint8_t link_local_address[16];
85 uint8_t global_address[16];
108 using MeshInterfaceNanostack::MeshInterfaceNanostack;
123 mesh_error_t set_network_name(
char *network_name);
134 mesh_error_t get_network_name(
char *network_name);
145 mesh_error_t validate_network_name(
char *network_name);
162 mesh_error_t set_network_regulatory_domain(uint8_t regulatory_domain = 0xff, uint8_t operating_class = 0xff, uint8_t operating_mode = 0xff);
175 mesh_error_t get_network_regulatory_domain(uint8_t *regulatory_domain, uint8_t *operating_class, uint8_t *operating_mode);
189 mesh_error_t validate_network_regulatory_domain(uint8_t regulatory_domain, uint8_t operating_class, uint8_t operating_mode);
204 mesh_error_t set_network_domain_configuration(uint8_t regulatory_domain, uint8_t phy_mode_id, uint8_t channel_plan_id);
217 mesh_error_t get_network_domain_configuration(uint8_t *regulatory_domain, uint8_t *phy_mode_id, uint8_t *channel_plan_id);
231 mesh_error_t validate_network_domain_configuration(uint8_t regulatory_domain, uint8_t phy_mode_id, uint8_t channel_plan_id);
264 mesh_error_t set_network_size(uint8_t network_size);
275 mesh_error_t get_network_size(uint8_t *network_size);
287 mesh_error_t validate_network_size(uint8_t network_size);
299 mesh_error_t set_channel_mask(uint32_t channel_mask[8]);
310 mesh_error_t get_channel_mask(uint32_t *channel_mask);
322 mesh_error_t validate_channel_mask(uint32_t channel_mask[8]);
339 mesh_error_t set_unicast_channel_function(mesh_channel_function_t channel_function, uint16_t fixed_channel = 0xffff, uint8_t dwell_interval = 0x00);
352 mesh_error_t get_unicast_channel_function(mesh_channel_function_t *channel_function, uint16_t *fixed_channel, uint8_t *dwell_interval);
366 mesh_error_t validate_unicast_channel_function(mesh_channel_function_t channel_function, uint16_t fixed_channel, uint8_t dwell_interval);
384 mesh_error_t set_broadcast_channel_function(mesh_channel_function_t channel_function, uint16_t fixed_channel = 0xffff, uint8_t dwell_interval = 0x00, uint32_t broadcast_interval = 0x00);
398 mesh_error_t get_broadcast_channel_function(mesh_channel_function_t *channel_function, uint16_t *fixed_channel, uint8_t *dwell_interval, uint32_t *broadcast_interval);
413 mesh_error_t validate_broadcast_channel_function(mesh_channel_function_t channel_function, uint16_t fixed_channel, uint8_t dwell_interval, uint32_t broadcast_interval);
428 mesh_error_t set_timing_parameters(uint16_t disc_trickle_imin = 0x00, uint16_t disc_trickle_imax = 0x00, uint8_t disc_trickle_k = 0x00, uint16_t pan_timeout = 0x00);
442 mesh_error_t get_timing_parameters(uint16_t *disc_trickle_imin, uint16_t *disc_trickle_imax, uint8_t *disc_trickle_k, uint16_t *pan_timeout);
457 mesh_error_t validate_timing_parameters(uint16_t disc_trickle_imin, uint16_t disc_trickle_imax, uint8_t disc_trickle_k, uint16_t pan_timeout);
469 mesh_error_t set_device_min_sens(uint8_t device_min_sens);
480 mesh_error_t get_device_min_sens(uint8_t *device_min_sens);
492 mesh_error_t validate_device_min_sens(uint8_t device_min_sens);
520 mesh_error_t set_own_certificate(uint8_t *cert, uint16_t cert_len, uint8_t *cert_key = NULL, uint16_t cert_key_len = 0);
530 mesh_error_t remove_own_certificates(
void);
553 mesh_error_t set_trusted_certificate(uint8_t *cert, uint16_t cert_len);
563 mesh_error_t remove_trusted_certificates(
void);
571 bool getRouterIpAddress(
char *address, int8_t len);
582 mesh_error_t enable_statistics(
void);
592 mesh_error_t reset_statistics(
void);
666 mesh_error_t nbr_info_get(
ws_nbr_info_t *nbr_ptr, uint16_t *count);
669 Nanostack::WisunInterface *get_interface()
const;
uint8_t rsl_out
parent RSSI Out measured RSSI value calculated using EWMA specified by Wi-SUN from range of -174 (0) ...
uint8_t join_state
Wi-SUN join state defined by Wi-SUN specification 1-5.
Wi-SUN mesh network interface class.
uint8_t version
RPL version number.
signed int nsapi_error_t
Type used to represent error codes.
uint8_t rsl_in
parent RSSI in measured RSSI value calculated using EWMA specified by Wi-SUN from range of -174 (0) t...
Struct ws_nbr_info_t Gives the neighbor information.
uint16_t primary_parent_rank
RPL Primary Parent Rank.
ws_nbr_type_e type
Neighbour type (Primary Parent, Secondary Parent, Candidate parent, child, other(Temporary neighbours...
Mesh physical layer statistics.
Struct ws_stack_state Wi-SUN stack information.
uint8_t instance_id
Router instance identifier.
const int8_t * cca_threshold_table
CCA threshold table.
uint8_t number_of_channels
Number of channels.
uint16_t rpl_rank
RPL Rank value for parents 0xffff for neighbors RANK is unknown.
uint32_t lifetime
Remaining lifetime Link lifetime for parents and ARO lifetime for children.
Struct ws_cca_threshold_table Wi-SUN CCA threshold table information.
uint8_t rsl_out
parent RSSI Out measured RSSI value calculated using EWMA specified by Wi-SUN from range of -174 (0) ...
uint8_t rsl_in
parent RSSI in measured RSSI value calculated using EWMA specified by Wi-SUN from range of -174 (0) t...
uint8_t device_min_sens
Device RF minimum sensitivity configuration.
uint8_t rpl_dodag_id[16]
Router dodag id.
uint16_t etx
Measured ETX value if known set to 0xFFFF if not known or Child.
Struct ws_rpl_info Wi-SUN router RPL information.
uint16_t current_rank
RPL DODAG node current Rank.
uint16_t pan_id
Network PAN ID.