Hi Harish,
a) is a bug, though we did not have any better strategy when initially
writing those components. (The problem being: if the radio module
uses timers, who is responsible for initializing the timer module?
The radio module, timer module, or application?) You can remove that
code as long as you initialize the timer system somewhere
(application).
We have addressed both a) and b) in Moteiv Bommerang for Tmote
platforms, which you can download for free from www.moteiv.com. a)
System libraries use a convention to wire themselves into an
initialization sequence. b) You can call CC2420RadioC.SplitControl,
its StdControl interface is still provided but deprecated.
Cory
On 5/10/06, Harish Prabhu <[EMAIL PROTECTED]> wrote:
Hi Joe or Cory,
I have two queries about the CC2420 Radio implementation in TinyOS :
a) Timer component is stopped when Radio is stopped
--------------------------------------------------------------------------------
Imagine an application which needs to stop the radio for some amount of
time every minute.
If we use a timer to achieve this, it won't work because the Timer
component is also stopped
in the process of stopping the radio.
Calling GenericComm's StdControl.stop leads to a call to AMStandard's
Control.stop which in turn calls
TimerControl.stop.
Also, CC2420RadioM calls TimerControl.stop in SplitControl.stop.
My question is :
Is stopping the Timer Component intended for any particular reason ?
Can I, for purposes of my application,
remove the calls to TimerControl from these components ?
b) No notification to application that Radio startDone has happened.
-----------------------------------------------------------------------------------------------
If I start the radio after stopping it using StdControl of GenericComm,
SplitControl gets called,
but without waiting for startDone.
In the absence of this, the application has to give a short delay (so
that the task gets scheduled and the oscillator stabilizes)
before resuming radio communication.
In the initial startup, when there are lot of components to initialize,
this delay is
inadvertently provided. But in my case I have to wait for some time.
This time has to include oscillator stabilzation time + time for
the tasks to get scheduled and executed
Would'nt it be better if we get a startDone kind of event from
GenericComm or CC2420Radio to not implement StdControl over
SplitControl?
Regards,
Harish
_______________________________________________
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