Question

I'm trying to make use of the 6LoWPAN implementation provided by Contiki OS.

My problem is that Rime is just working without having the flag UIP_CONF_IPV6 set. As soon as I set the flag in order to activate IPv6 support the compiler reports 'multiple definition' of the functions rime_sniffer_add() and rime_sniffer_remove() which are located in rime.c as well as in sicslowpan.c.

Has someone managed to solve this issue or a working example?

Was it helpful?

Solution 2

In case someone's interested in 6LoWPAN using Contiki:

The right way is to use RPL which is basically designed for IPv6 and 6LoWPAN.
Refer to Contiki's udp_rpl example in order to set up a server/client-communication. The appropriate flags will enable 6LoWPAN header compression.

OTHER TIPS

I would like to add to this, although it's an old question, but it could use a clearer explanation.

You can't use Rime and 6LoWPAN at the same time in Contiki, because the network stack supports a single network driver (if you look in netstack.h).

The default driver is rime. If you define the UIP_CONF_IPV6 flag, it defines the WITH_UIP6 flag, which in turn sets the network driver to sicslowpan.

Upon receiving a message, the MAC driver (in this case, llsec) directly calls the input() function defined by the network driver. There is no demultiplexing of packet headers, so, again, it's either rime, or sicslowpan, as defined at compile time.

Now - you can send messages using rime. As far as I can tell from the code, those sniffers are used for side functionality, like enabling more detailed powertrace for rime or 6lowpan. This is not essential, so you can comment out the sniffers. But, then again, even if you can compile both rime and 6lowpan at once, and can send messages, you won't receive anything (tried and tested...).

If you want to do broadcast with 6lowpan, use the multicast address for broadcast, use icmp or udp.

Hope this helps. Misel

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top