mirror of
https://github.com/oliverschmidt/contiki.git
synced 2025-01-21 23:31:11 +00:00
Allow user configuration of RPL Lifetime and Lifetime Unit
This commit is contained in:
parent
9c8f1d5356
commit
aaf5deabe2
@ -113,10 +113,18 @@
|
||||
#define RPL_ZERO_LIFETIME 0
|
||||
|
||||
/* Default route lifetime unit. */
|
||||
#ifndef RPL_CONF_DEFAULT_LIFETIME_UNIT
|
||||
#define RPL_DEFAULT_LIFETIME_UNIT 0xffff
|
||||
#else
|
||||
#define RPL_DEFAULT_LIFETIME_UNIT RPL_CONF_DEFAULT_LIFETIME_UNIT
|
||||
#endif
|
||||
|
||||
/* Default route lifetime as a multiple of the lifetime unit. */
|
||||
#ifndef RPL_CONF_DEFAULT_LIFETIME
|
||||
#define RPL_DEFAULT_LIFETIME 0xff
|
||||
#else
|
||||
#define RPL_DEFAULT_LIFETIME RPL_CONF_DEFAULT_LIFETIME
|
||||
#endif
|
||||
|
||||
#define RPL_LIFETIME(instance, lifetime) \
|
||||
((unsigned long)(instance)->lifetime_unit * (lifetime))
|
||||
|
Loading…
x
Reference in New Issue
Block a user