On Feb 20, 2010, at 4:30 PM, [email protected] wrote: > All: > > I am trying to figure out what protocols CTP is on top of. I'm still > not very familiar with the tinyOS tree but I need to figure out what > the maximum size for the payload of a CTP packet is and whether this > is static or variable. I am working on a higher level library that > needs to be sure it sends data one packet at a time. I've read > through a couple of the CTP papers but this isn't directly clear from > them. If someone knows this right offhand or can point me in the > right direction in TinyOS tree I'd appreciate it.
CTP normally sits on top of AM. The CTP data header is 8 bytes. So a packet can carry TOSH_DATA_LENGTH - 8 bytes. As the default TOSH_DATA_LENGTH is 28, this means 20 bytes. Much better than assuming 20 bytes, though, is using the command Packet.maxPayloadLength(). That way, if something underneath changes your code won't have a hardcoded constant in it. Phil _______________________________________________ Tinyos-help mailing list [email protected] https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help
