Hi jan, i believe that Boomerang use TinyOS-1.x version. See the next table:
señal port MSP430 port U2 port U28 GIO0 20 10 GIO1 21 7 GIO2 23 3 GIO3 26 4 For you can use GIO0 and GIO1 you must joint resistor R14 and R16 that by default in open circuit. You can see in the file hardware.h (/tinyos-1.x/tos/platform/telosb) the next four lines: //GIO pins TOSH_ASSIG_PIN(GIO0, 2, 0); //port two and bit 0 of MSP430 TOSH_ASSIG_PIN(GIO1, 2, 1); TOSH_ASSIG_PIN(GIO2, 2, 3); TOSH_ASSIG_PIN(GIO3, 2, 6); GIOx the name, you can use other that you like more. The way for use pins is know port and bit and assign and name. You must take care because GIO0 and GIO1 share the pin with ADCx. For configure your pins of input use TOSH_MAKE_GIOx_INPUT();, for output TOSH_MAKE_GIOx_OUTPUT(); in your component init command for example. If you use GIO0 and GIO1 the best is that configure ADC2 and ADC3 inputs for not have problems with GIO0 and 1 in the same file. Change TOSH_MAKE_ADC_ OUTPUT by TOSH_MAKE_ADC_ INPUT. You can find the file msp430hardware.h and at the end you can see all the generate macros by one instrucction TOSH_ASSIG_PIN. Later you have functions for read pin, set, clear, configure input or output, etc I wish that help you. A greeting, Juan Antonio. PD: next once use reply all for the messare will arrive to mail list of tinyos-help. 2007/3/13, Jan Soukup <[EMAIL PROTECTED]>:
Hi Juan, I'm using TinyOS version Boomerang 2.0.4. Anyway I realized that I can use analog inputs instead of digital (I want to read PWM signal from the accelerometer). But still don't know how to proceed. Any clue? Is there any event to signal the rise and fall edge of the input signal? Pleas anyone can help? Thanks, jan. ______________________________________________________________ > Od: [EMAIL PROTECTED] > Komu: "Jan Soukup" <[EMAIL PROTECTED]> > CC: tinyos-help@millennium.berkeley.edu > Datum: 13.03.2007 00:48 > Předmět: Re: [Tinyos-help] Digital I/O's > >Hello, > >if you use a TinyOS-1.x i can help you, the version 2.x i finish to install >yesterday and yet i not know very much. > >A greeting, >Juan Antonio. > > >2007/3/13, Jan Soukup <[EMAIL PROTECTED]>: >> >> Hi, >> >> I wonder how can I use the digital I/O pins on the expansion connector of >> the Tmote Sky? >> I know, that I have to populate R14 and R16 to use GIO0 and GIO1. But what >> else? How can I set it to be an input and read data from it? >> Is there any example of using it? >> >> Thanks a lot. Jan >> >> _______________________________________________ >> Tinyos-help mailing list >> Tinyos-help@Millennium.Berkeley.EDU >> https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help >> > >
_______________________________________________ Tinyos-help mailing list Tinyos-help@Millennium.Berkeley.EDU https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help