diff --git a/examples/rime/example-broadcast.c b/examples/rime/example-broadcast.c index 6d258d4cd..a7d2b2232 100644 --- a/examples/rime/example-broadcast.c +++ b/examples/rime/example-broadcast.c @@ -28,7 +28,7 @@ * * This file is part of the Contiki operating system. * - * $Id: example-broadcast.c,v 1.1 2009/10/18 17:49:24 adamdunkels Exp $ + * $Id: example-broadcast.c,v 1.2 2009/11/19 17:29:41 nifi Exp $ */ /** @@ -52,9 +52,10 @@ PROCESS(example_broadcast_process, "BROADCAST example"); AUTOSTART_PROCESSES(&example_broadcast_process); /*---------------------------------------------------------------------------*/ static void -broadcast_recv(struct broadcast_conn *c) +broadcast_recv(struct broadcast_conn *c, const rimeaddr_t *from) { - printf("broadcast message received '%s'\n", (char *)packetbuf_dataptr()); + printf("broadcast message received from %d.%d: '%s'\n", + from->u8[0], from->u8[1], (char *)packetbuf_dataptr()); } static const struct broadcast_callbacks broadcast_call = {broadcast_recv}; static struct broadcast_conn broadcast;