PRINTF():ed debugging output

This commit is contained in:
fros4943 2010-04-01 11:08:36 +00:00
parent cc11c9d3f2
commit 59357e8b75
1 changed files with 35 additions and 35 deletions

View File

@ -33,7 +33,7 @@
* *
* This file is part of the Contiki operating system. * This file is part of the Contiki operating system.
* *
* $Id: collect.c,v 1.45 2010/04/01 10:03:19 adamdunkels Exp $ * $Id: collect.c,v 1.46 2010/04/01 11:08:36 fros4943 Exp $
*/ */
/** /**
@ -152,7 +152,7 @@ update_rtmetric(struct collect_conn *tc)
collect_neighbor_etx(best) < collect_neighbor_etx(best) <
collect_neighbor_etx(n) - COLLECT_NEIGHBOR_ETX_SCALE)) { collect_neighbor_etx(n) - COLLECT_NEIGHBOR_ETX_SCALE)) {
rimeaddr_copy(&tc->parent, &best->addr); rimeaddr_copy(&tc->parent, &best->addr);
printf("Switched parent to %d.%d\n", PRINTF("Switched parent to %d.%d\n",
tc->parent.u8[0], tc->parent.u8[1]); tc->parent.u8[0], tc->parent.u8[1]);
} }
@ -310,7 +310,7 @@ send_queued_packet(void)
} else { } else {
#if COLLECT_ANNOUNCEMENTS #if COLLECT_ANNOUNCEMENTS
#if COLLECT_CONF_WITH_LISTEN #if COLLECT_CONF_WITH_LISTEN
printf("listen\n"); PRINTF("listen\n");
announcement_listen(1); announcement_listen(1);
ctimer_set(&c->transmit_after_scan_timer, ANNOUNCEMENT_SCAN_TIME, ctimer_set(&c->transmit_after_scan_timer, ANNOUNCEMENT_SCAN_TIME,
send_queued_packet, NULL); send_queued_packet, NULL);
@ -799,12 +799,12 @@ collect_send(struct collect_conn *tc, int rexmits)
rimeaddr_node_addr.u8[0], rimeaddr_node_addr.u8[1]); rimeaddr_node_addr.u8[0], rimeaddr_node_addr.u8[1]);
#if COLLECT_ANNOUNCEMENTS #if COLLECT_ANNOUNCEMENTS
#if COLLECT_CONF_WITH_LISTEN #if COLLECT_CONF_WITH_LISTEN
printf("listen\n"); PRINTF("listen\n");
announcement_listen(1); announcement_listen(1);
ctimer_set(&tc->transmit_after_scan_timer, ANNOUNCEMENT_SCAN_TIME, ctimer_set(&tc->transmit_after_scan_timer, ANNOUNCEMENT_SCAN_TIME,
send_queued_packet, NULL); send_queued_packet, NULL);
#else /* COLLECT_CONF_WITH_LISTEN */ #else /* COLLECT_CONF_WITH_LISTEN */
printf("bump neighbor value\n"); PRINTF("bump neighbor value\n");
announcement_set_value(&tc->announcement, RTMETRIC_MAX); announcement_set_value(&tc->announcement, RTMETRIC_MAX);
announcement_bump(&tc->announcement); announcement_bump(&tc->announcement);
#endif /* COLLECT_CONF_WITH_LISTEN */ #endif /* COLLECT_CONF_WITH_LISTEN */