Hi,

Sure thing, let us take for instance the Alarm32khzC component which should
provide the interface Alarm<T32khz,uint32_t>.
The precision_tag (T32khz) describes number of clock ticks per second that
is:

For TMilli it is 1024
For T32khz it should be 32768
... and so on

I am thinking of if as if it was a smallest countable amount of time which
might be archived using this Component.

Assuming that I execute the following code:

//..... Application file (with wiring) :
components new Alarm32khzC() as Alarm;  // provides Alarm<T32khz,uint32_t>.
App.Alarm -> Alarm;

//..... App component file :
// [...]
uses interface Alarm<T32khz,uint32_t> as Alarm;
// [...]
event void Boot.booted() {
call Alarm.start(10000);
}
// [...]
async event void Alarm.fired(){
call Leds.led0Toggle();
call Leds.led1Toggle();
call Leds.led2Toggle();
}

Leds should be "on" almost immediately after start of the mote ( to be exact
after 10000/32768 [s] + small delay for reaction). It is not the case, they
are turning on after [!] ~10 second, as if it was working with precision_tag
TMilli.

Regarding the tutorial, I was going through it but I admit it was quite
brief. Maybe I miss something very platform specific.

All in all, thank you for replay. I am looking forward for comments.
Roman Klis

2011/2/2 Sergio Valcarcel <[email protected]>

> Hi Roman,
> Please, could you explain a little bit more?
> For instance, what do you mean with "it does not work as intended"?
>
> Are you familiar with the corresponding TEP?
> http://www.tinyos.net/dist-2.0.0/tinyos-2.0.0beta1/doc/html/tep102.html
>
> Cheers!
> Sergio
>
> On Wed, Feb 2, 2011 at 3:25 PM, Romek Kliś <[email protected]> wrote:
> > Hi!
> >
> > I am trying to get to work the 32kHZ timer on the Intelmote2. The class
> > which is supposed to provide all the necessary interfaces is called:
> >
> > Alarm32khzC
> >
> > Apparently it seems that it does not work as intended, or I am using it
> in a
> > wrong way. Does any one of you have experience in use of 32kHZ timer on
> > intel mote 2?
> >
> > Best regards
> > Roman Klis
> >
> > _______________________________________________
> > Tinyos-help mailing list
> > [email protected]
> > https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help
> >
>
_______________________________________________
Tinyos-help mailing list
[email protected]
https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

Reply via email to