gnrc_rpl_of_t Struct Reference

Objective function representation. More...

Detailed Description

Objective function representation.

Definition at line 238 of file structs.h.

#include <net/gnrc/rpl/structs.h>

Data Fields

uint16_t ocp
 objective code point
uint16_t(* calc_rank )(gnrc_rpl_parent_t *parent, uint16_t base_rank)
 calculate the rank
gnrc_rpl_parent_t *(* which_parent )(gnrc_rpl_parent_t *, gnrc_rpl_parent_t *)
 retrieve the better parent
int(* parent_cmp )(gnrc_rpl_parent_t *parent1, gnrc_rpl_parent_t *parent2)
 Compare two gnrc_rpl_parent_t. More...
gnrc_rpl_dodag_t *(* which_dodag )(gnrc_rpl_dodag_t *, gnrc_rpl_dodag_t *)
 compare for dodags
void(* reset )(gnrc_rpl_dodag_t *)
 resets the OF
void(* parent_state_callback )(gnrc_rpl_parent_t *, int, int)
 retrieves the state of a parent
void(* init )(void)
 OF specific init function.
void(* process_dio )(void)
 DIO processing callback (acc. More...

Field Documentation

◆ parent_cmp

int(* gnrc_rpl_of_t::parent_cmp) (gnrc_rpl_parent_t *parent1, gnrc_rpl_parent_t *parent2)

Compare two gnrc_rpl_parent_t.

Compares two parents based on the rank calculated by the objective function. This function is used to determine the parent list order. The parents are ordered from the preferred parent to the least preferred parent.

[in]parent1First parent to compare.
[in]parent2Second parent to compare.
Zero if the parents are of equal preference.
Positive, if the second parent is preferred.
Negative, if the first parent is preferred.

Definition at line 258 of file structs.h.

◆ process_dio

void(* gnrc_rpl_of_t::process_dio) (void)

DIO processing callback (acc.

to OF0 spec, chpt 5)

Definition at line 263 of file structs.h.

The documentation for this struct was generated from the following file: