It appears that the values defined for RPL_NODE_IS_ROOT and
RPL_MAX_ROUTING_ENTRIES in the Makefile via CFLAGS are not recognized in
sc_rpl.c (my guess: they are only visible to the rpl module?)
Therefore RPL_MAX_ROUTING_ENTRIES is always set to 0, no matter how the
binary is compiled, thus resulting in the output "No routing table
available" for root nodes.
This PR proposes an approach to reduce the thread count of RPL.
The current RPL/Trickle stack needs about 5 threads to handle tasks
like updating the trickle timer, routing entries and the transmission of
DAOs.
This PR modifies RPL to use only one thread with a looped `msg_recv()` call.
The message is then multiplexed to the right task.
This PR removes code depending on a routing table with an entries
size > 0. Currently, all those functions and symbols are compiled into the binary,
even when there is no effective space in the routing table (as it is the
case for normal nodes in non-storing mode)
- suppressed cppcheck warning for `unassignedVariable` for
the encode/decode arrays in stream encode/decode tests
as these arrays are assigned by the according `base64_[en|de]code()` function.
``debug.h`` was included before ``ENABLE_DEBUG`` was set to 0 or 1. In consequence, setting ``ENABLE_DEBUG`` to 1 had no effect. This should be fixed now.
For some reason the call to aodv_packet_reader_handle_packet() got lumped in with the check if a received packet is ours. In consequence, all packets which were not sent by the node that received them (i.e. the important ones) were silently ignored, preventing any routes from being established.
This should be fixed now: foreign packets are now handled again, while own packets are ignored.
Also, I made the corresponding comment a bit less passive-aggressive.
Calling ipv6_iface_set_srh_indicator with storing mode breaks the
neighbour discovery code in **ip.c:480**.
Thus, it is not possible to use `send <n> test` from node to node.
Switch two calls to DEBUGF() to DEBUG() because they lead to compliling complcations and the additional output provided by DEBUG isn't really necessary here.
The dicision to drop a packet if no next hop exists is made by the
`rpl_get_next_hop` function, which is initialized as the routing
provider for rpl applications. Hence, it seems needless to do this in the
`rpl_send` function.
msg_send_int() sets `m->sender_pid = target_pid`. This was used to flag a
message as having been sent by an ISR.
This PR introduces a static inline function `msg_sent_by_int()` and a
specific define for this purpose.