On Wed, Apr 20, 2011 at 5:22 AM, Hiral Jhaveri <07bit...@nirmauni.ac.in> wrote: > Hello all, > I am working with Collection protocol in TinyOS-2.x > I have successfully simulated it with TOSSIM > 1] Is it possible to process the packet in the intermediate nodes before it > reaches to the root node ?? > Say, the root node has ID 1. And there are other two nodes 2 and 3. > Packet format is > { > nx_uint16_t mobile_id; > nx_uint16_t base_id; > }; > Now, node 3 sends packet with mobile_id = 3. When this is received by node > 2, I want it to make base_id = 2 before forwarding it to the root node. > How can this be done??
You can use the Intercept interface. > or > 2] At the root node, how to know the path followed by the packet before > reaching it?? Two ways - Piece together information based on (node,parent) on each packet. If you look at TestNetwork application, you will see that each node sends the next hop node id in the payload. You can add a field in the header to record the path. Then you can either hack the forwarding engine or use the Intercept interface to update this field as the message is forwarded. - om_p _______________________________________________ Tinyos-help mailing list Tinyos-help@millennium.berkeley.edu https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help