[Tinyos-help] General IO

Guillermo De Cesco decescog at gmail.com
Wed Sep 24 12:45:47 PDT 2008


Hi,

Talking in tmote TinyOS 2.0
You have to wire to component HplMsp430GeneralIOC, and use de adapter new
Msp430GpioC(), like this:

        HplMsp430GeneralIOC,
        new Msp430GpioC() as OutputPin  //Adapter
        YOURAPP;

        OutputPin  -> HplMsp430GeneralIOC.Port26;//GIO3
        YOURAPP.GeneralIO -> OutputPin  ;

Where you use GeneralIO in your application module.
Then in the init command you should set it to an output

command error_t Init.init(){
     call GeneralIO.makeOutput();
}

ready to use

hope it works for you

-Bill
-------------- next part --------------
An HTML attachment was scrubbed...
URL: https://www.millennium.berkeley.edu/pipermail/tinyos-help/attachments/20080924/fb0f685c/attachment.htm 


More information about the Tinyos-help mailing list