FW: [Tinyos-help] Packet structure with TinyOS-1.x

Edgar Charry echarry at hotmail.com
Tue Mar 18 00:41:47 PDT 2008





Hi Michael, Thanks for your fast reply.I've been running in a lot of things, so i coudn't answer you back.To the problem: basically then, if the packet receives a 0x7D, the code checks if its subsequent byte is 0x5E or 0x5D to discover if its a 7E or 7D being transmitted. I still haven't been through the "CD00" value below however. Also, somehow and sometimes only, reading through the Labview VISA, my packets are not being received correctly. The read packet bounces and i get the wrong data.My buffer is set to the default (4096), so i think it's not a problem of buffer. Neither the 115200bps baud rate.  I suspect XSniffer filters this half-packets off, just to display the right data.Have you experienced such a thing? Any ideas to implement flow control?Cheers and thanks,Edgar Charry> Date: Thu, 13 Mar 2008 11:31:17 -0600> From: schip at santafe.edu> To: echarry at hotmail.com> CC: tinyos-help at millennium.berkeley.edu> Subject: Re: [Tinyos-help] Packet structure with TinyOS-1.x> > The mystery 5D is actually an "escaped" 7D (hmm or 7E -- I don't remember> which off-hand). The trailing 7E's are the "framing" bytes at the end and> beginning of each message (thus leading to the need for escaping them> elsewhere) and the last 42 is radio message type, so your framing is> off a bit. I think the remaining ??? values are the CRC and other> internal message structure. See this page for excruciating detail:> > http://www.octavetech.com/pubs/TB5-01%20Deciphering%20TinyOS%20Serial%20Packets.pdf> > MS> > Edgar Charry wrote:> > Hello everyone,> > > > I am experimenting problems with the packet structure. I'm using the > > TinyOS1.x operating system.> > The TOS_Msg struc is intact, but i've changed the xsensor header a bit. > > However i cannot recognized some bytes that my programm is listening > > (and shouldn't be received). They are marked with a "???" below. Can > > anyone PLEASE give me any sort of explanation? As strenght and ack bytes > > are not sent, don't really know what they are (or where the CRC is).> > > > My packet struc should be 5 bytes of TinyOS Header :> > a. Dest Add - 2, AM Group - 1, AM Type - 1, Length - 1> > > > another 6 bytes of xsensor header (which i changed to count the packets > > supposed to be transmitted and the transmitted in fact):> > b. packet_id - 2, tx_id - 2, node_id = 1, rsvd -1> > > > and the payload that should contain 8 bytes:> > c. thermistor - 2, adc2 - 2, adc3 - 2, adc4 - 2.> > > > and:> > d. 2 bytes of crc.> > > > Leading to a total of: 21 bytes.> > > > However listening to the UART Port using Labview i read 27 bytes everytime.> > Below:> > > > FFFF 007D 5D0E A200 A200 0700 DB01 A701 5B02 1702 CD00 C5B3 7E7E 42:> > > > FFFF: Dest Add |> > 00: AMGroup |> > 7D: AMType|> > 5D = ????> > 0E: length (which is 14bytes and is correct)|> > A200: packet id|> > A200: tx id|> > 07: node id|> > 00: reserved|> > DB01:Thermistor|> > A701:ADC2|> > 5B02:ADC3|> > 1702:ADC4|> > CD00:???> > C5B3:???> > 7E7E:???> > 42:???> > > > Thanks many times for any kind of guidance!> > Edgar Charry> > > > ------------------------------------------------------------------------> > Express yourself instantly with MSN Messenger! MSN Messenger > > <http://clk.atdmt.com/AVE/go/onm00200471ave/direct/01/>> > > > > > ------------------------------------------------------------------------> > > > _______________________________________________> > Tinyos-help mailing list> > Tinyos-help at millennium.berkeley.edu> > https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help> > -- > Platform: WinXP/Cygwin> TinyOS version: 1.x, Boomerang> Programmer: MIB510> Device(s): Mica2, MicaZ, Tmote> Sensor board: homebrew> 

Get news, entertainment and everything you care about at Live.com. Check it out! 
_________________________________________________________________
Connect to the next generation of MSN Messenger 
http://imagine-msn.com/messenger/launch80/default.aspx?locale=en-us&source=wlmailtagline
-------------- next part --------------
An HTML attachment was scrubbed...
URL: https://www.millennium.berkeley.edu/pipermail/tinyos-help/attachments/20080318/2f3a94a2/attachment.html


More information about the Tinyos-help mailing list