[Tinyos-help] TinyOS: MultiHop

Pablo Gil Montaño pgilmon at yahoo.es
Mon Jan 29 05:49:03 PST 2007


Hi Hamdi,

in "TOS_MsgPtr pMsg" you must provide a pointer to a TOS_Msg field, which is defined in tinyos-1.x/tos/types/AM.h. In order to fill this TOS_Msg you mus previously call to 

command void* Send.getBuffer[uint8_t id](TOS_MsgPtr msg, uint16_t* length);

to get a pointer to the payload and fill the message. For instance, you can do a cast from the void* returned by previous command to the type of message you want to send, and then fill the message by using the pointer to your message type.

Regards,

Pablo Gil



----- Mensaje original ----
De: Hamdi Roumani <cs233017 at cse.yorku.ca>
Para: tinyos-help at Millennium.Berkeley.EDU
Enviado: viernes, 26 de enero, 2007 11:49:47
Asunto: [Tinyos-help] TinyOS: MultiHop

Hello,

I'd like to use MultiHopEngine .. particularly the send and recieve  
interfaces.  I'm not exactly sure how to do this though:

command result_t Send.send[uint8_t id](TOS_MsgPtr pMsg, uint16_t PayloadLen)

what excatly needs to go in the TOS_MsgPtr for example?

Also, is this a good algorithm to use for MultiHop protocols? or is  
there a simple alternative.

Thanks!
-- 
Regards,
Hamdi





----------------------------------------------------------------
This message was sent using IMP, the Internet Messaging Program.

_______________________________________________
Tinyos-help mailing list
Tinyos-help at Millennium.Berkeley.EDU
https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help




-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.millennium.berkeley.edu/pipermail/tinyos-help/attachments/20070129/487967ba/attachment.htm


More information about the Tinyos-help mailing list