Implementation of software-defined 6LoWPANs in contiki OS