diff --git a/core/dev/cc2420.c b/core/dev/cc2420.c index 474c31b49..7f8a0a76c 100644 --- a/core/dev/cc2420.c +++ b/core/dev/cc2420.c @@ -28,7 +28,7 @@ * * This file is part of the Contiki operating system. * - * @(#)$Id: cc2420.c,v 1.15 2007/05/07 12:02:14 bg- Exp $ + * @(#)$Id: cc2420.c,v 1.16 2007/05/08 08:27:34 bg- Exp $ */ /* * This code is almost device independent and should be easy to port. @@ -74,6 +74,7 @@ static void neigbour_update(u16_t mac, int retransmissions); signed char cc2420_last_rssi; u8_t cc2420_last_correlation; +u8_t cc2420_is_input; static u8_t receive_on; @@ -491,7 +492,9 @@ PROCESS_THREAD(cc2420_process, ev, data) && uip_ipaddr_cmp(&BUF->destipaddr, &uip_hostaddr)) cc2420_send_data_ack(h.src); leds_toggle(LEDS_GREEN); + cc2420_is_input = 1; tcpip_input(); + cc2420_is_input = 0; leds_toggle(LEDS_GREEN); } } diff --git a/core/dev/cc2420.h b/core/dev/cc2420.h index 7a2651902..742151bec 100644 --- a/core/dev/cc2420.h +++ b/core/dev/cc2420.h @@ -28,7 +28,7 @@ * * This file is part of the Contiki operating system. * - * @(#)$Id: cc2420.h,v 1.4 2007/04/04 11:46:47 bg- Exp $ + * @(#)$Id: cc2420.h,v 1.5 2007/05/08 08:27:58 bg- Exp $ */ #ifndef CC2420_H @@ -110,6 +110,7 @@ extern struct uip_fw_netif cc2420if; extern signed char cc2420_last_rssi; extern u8_t cc2420_last_correlation; +extern u8_t cc2420_is_input; extern volatile u8_t cc2420_ack_received; void cc2420_init(void);