3. You should use SendMsg module like this:
in Configuration:

 components
        [...]
        , GenericComm
        [...]

[...]
SendM.SendMessage -> GenericComm.SendMsg[131];
[...]

in Implementation:

[...]
uses{
        interface SendMsg as SendMessage;
}

implementation{
      TOS_Msg msg_envelope;
      YOUR_MESSAGE_STRUCT * msg_payload;

[...]

  command result_t StdControl.init(){   
      [...]
        msg_payload = (YOUR_MESSAGE_STRUCT*) msg_envelope.data;
     [...]
   }


   [...]
       msg_payload->YOUR_DATA_FIELD = <VALUE>;
      [...]
       res = call SendMessage.send(TOS_BCAST_ADDR,sizeof(msg_payload),&msg_envelope);
     // sends BROADCAST your message (max 29 byte )
   [...]




Andrea

Colin Couper wrote:
I have a number of questions concerning TinyOS.  I am using the moteiv
tmote sky as my module.

1.  Is there a progam module that will take the user button and
register a press so that I can then send it over the radio.

2.I can't get the OscilloscopeRF program to work - I get no data on my
Java display but I am receiving packets. I tried the version that
moteiv have but it won't compile!  Anyone got any ideas?

3.  What is the program for sending data over the radio?

4.  How do I make use of the Analogue inputs on the expansion
connector - ie. how do I take the input and make use of it?

Thanks for the help in advance

Colin

_______________________________________________
Tinyos-help mailing list
[email protected]
https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help


  
_______________________________________________
Tinyos-help mailing list
[email protected]
https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

Reply via email to