Hii, I am using Moteworks to implement multihop network. I am trying to receive (Intercept) the data at the intermediate node, so that I can perform some aggregation. But data forwarded to the base station is different and constant. Below is my intercept function. I think I have some problem with the pointers.
///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// event result_t Intercept.intercept(TOS_MsgPtr pMsg, void* payload, uint16_t payloadLen) { if(TOS_LOCAL_ADDRESS==1) { TOS_MsgPtr temp_ptr = appmsg; appmsg = pMsg; pack = (struct XDataMsg *)payload; // or // pack = (struct XDataMsg *)appmsg->data; call Leds.yellowToggle(); post ReceivedTask(); } return SUCCESS; } //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
_______________________________________________ Tinyos-help mailing list Tinyos-help@Millennium.Berkeley.EDU https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help