Added net-debug.[ch] to provide debug functions even in the non-IP case

This commit is contained in:
Simon Duquennoy 2016-04-20 11:45:54 +02:00
parent 5b5f07ba52
commit abf08a7167
15 changed files with 166 additions and 73 deletions

View file

@ -30,7 +30,7 @@
/**
* \file
* A set of debugging tools
* A set of debugging tools for the IP stack
* \author
* Nicolas Tsiftes <nvt@sics.se>
* Niclas Finne <nfi@sics.se>
@ -92,19 +92,3 @@ uip_debug_ipaddr_print(const uip_ipaddr_t *addr)
#endif /* NETSTACK_CONF_WITH_IPV6 */
}
/*---------------------------------------------------------------------------*/
void
uip_debug_lladdr_print(const uip_lladdr_t *addr)
{
unsigned int i;
if(addr == NULL) {
PRINTA("(NULL LL addr)");
return;
}
for(i = 0; i < sizeof(uip_lladdr_t); i++) {
if(i > 0) {
PRINTA(":");
}
PRINTA("%02x", addr->addr[i]);
}
}
/*---------------------------------------------------------------------------*/