#include "contiki.h"
#include "contiki-net.h"
#include "net/rpl/rpl.h"
#include "net/rpl/rpl-private.h"
#include "simple-rpl.h"
#include <string.h>
#include "net/ip/uip-debug.h"
Macros | |
#define | _DEBUG_ DEBUG_NONE |
#define | RPL_DAG_GRACE_PERIOD (CLOCK_SECOND * 20 * 1) |
Functions | |
static void | create_dag_callback (void *ptr) |
static void | route_callback (int event, uip_ipaddr_t *route, uip_ipaddr_t *ipaddr, int numroutes) |
static uip_ipaddr_t * | set_global_address (void) |
const uip_ipaddr_t * | simple_rpl_global_address (void) |
void | simple_rpl_global_repair (void) |
void | simple_rpl_init (void) |
void | simple_rpl_init_dag (void) |
int | simple_rpl_init_dag_immediately (void) |
void | simple_rpl_local_repair (void) |
const uip_ipaddr_t * | simple_rpl_parent (void) |
const uip_ipaddr_t * | simple_rpl_root (void) |
Variables | |
static struct ctimer | c |
static struct uip_ds6_notification | n |
static uint8_t | to_become_root |
#define _DEBUG_ DEBUG_NONE |
#define RPL_DAG_GRACE_PERIOD (CLOCK_SECOND * 20 * 1) |
Referenced by create_dag_callback(), and simple_rpl_init_dag().
|
static |
References c, ctimer_set(), rpl_dag::grounded, INFINITE_RANK, ipaddr, rpl_dag::joined, NULL, rpl_dag::preference, printf, rpl_dag::rank, RPL_DAG_GRACE_PERIOD, rpl_get_any_dag(), simple_rpl_global_address(), simple_rpl_init_dag_immediately(), simple_rpl_root(), to_become_root, uip_ip6addr_t::u8, uip_ipaddr_cmp, rpl_dag::used, and rpl_dag::version.
Referenced by route_callback(), and simple_rpl_init_dag().
|
static |
References c, create_dag_callback(), ctimer_set(), NULL, printf, to_become_root, UIP_DS6_NOTIFICATION_DEFRT_ADD, and uip_is_addr_unspecified.
Referenced by simple_rpl_init().
|
static |
References ADDR_AUTOCONF, uip_ds6_netif::addr_list, ADDR_PREFERRED, ADDR_TENTATIVE, i, ipaddr, uip_ds6_addr::ipaddr, uip_ds6_addr::isused, printf, uip_ds6_addr::state, state, uip_debug_ipaddr_print(), uip_ds6_addr_add(), UIP_DS6_ADDR_NB, uip_ds6_if, uip_ds6_set_addr_iid(), uip_ip6addr, and uip_lladdr.
Referenced by simple_rpl_init().
const uip_ipaddr_t* simple_rpl_global_address | ( | void | ) |
References uip_ds6_netif::addr_list, ADDR_PREFERRED, i, ipaddr, uip_ds6_addr::ipaddr, uip_ds6_addr::isused, NULL, uip_ds6_addr::state, state, UIP_DS6_ADDR_NB, uip_ds6_if, and uip_is_addr_link_local.
Referenced by create_dag_callback(), and make_routes_roomfor().
void simple_rpl_global_repair | ( | void | ) |
References printf, RPL_DEFAULT_INSTANCE, and rpl_repair_root().
void simple_rpl_init | ( | void | ) |
References n, route_callback(), set_global_address(), to_become_root, and uip_ds6_notification_add().
void simple_rpl_init_dag | ( | void | ) |
References c, create_dag_callback(), ctimer_set(), dis_output(), NULL, RPL_DAG_GRACE_PERIOD, to_become_root, and uip_ds6_defrt_add().
Referenced by PROCESS_THREAD().
int simple_rpl_init_dag_immediately | ( | void | ) |
References uip_ds6_netif::addr_list, ADDR_PREFERRED, rpl_instance::def_route, i, rpl_dag::instance, ipaddr, uip_ds6_addr::ipaddr, uip_ds6_addr::isused, NULL, prefix, printf, RPL_DEFAULT_INSTANCE, rpl_get_any_dag(), rpl_remove_routes(), rpl_set_prefix(), rpl_set_root(), uip_ds6_addr::state, state, uip_ds6_addr_lookup(), UIP_DS6_ADDR_NB, uip_ds6_defrt_rm(), uip_ds6_if, uip_ip6addr, and uip_is_addr_link_local.
Referenced by create_dag_callback().
void simple_rpl_local_repair | ( | void | ) |
References RPL_DEFAULT_INSTANCE, rpl_get_instance(), and rpl_local_repair().
const uip_ipaddr_t* simple_rpl_parent | ( | void | ) |
References NULL, rpl_dag::preferred_parent, rpl_get_any_dag(), and rpl_get_parent_ipaddr().
Referenced by PROCESS_THREAD().
const uip_ipaddr_t* simple_rpl_root | ( | void | ) |
References rpl_dag::dag_id, NULL, and rpl_get_any_dag().
Referenced by create_dag_callback(), and make_routes_roomfor().
|
static |
Referenced by create_dag_callback(), route_callback(), and simple_rpl_init_dag().
|
static |
Referenced by _tcc_build_waves(), delay_cycles(), dir_register(), echo_reply_input(), enter_wifi_firmware_download(), f_getfree(), f_mkdir(), fwc_add(), fwc_lookup(), ifft(), ip64_addrmap_create(), IperfCalculateBandwidthKbps(), list_length(), mmem_free(), neighbor_queue_from_addr(), numtostring(), packet_sent(), pbuf_memcmp(), read(), send_packet(), simple_rpl_init(), transmit_packet_list(), udi_cdc_data_received(), uip_ds6_route_next(), uip_ds6_select_src(), and uip_over_mesh_set_gateway_netif().
|
static |
Referenced by create_dag_callback(), route_callback(), simple_rpl_init(), and simple_rpl_init_dag().