Fwd: [Tinyos Core WG] T2 Mica* Timers

David Gay dgay42 at gmail.com
Wed Feb 21 15:56:32 PST 2007


This might be useful for any of you using mica2's/micaz's.

David

---------- Forwarded message ----------
From: David Gay <dgay42 at gmail.com>
Date: Feb 21, 2007 3:53 PM
Subject: Re: [Tinyos Core WG] T2 Mica* Timers
To: David Moss <dmm at rincon.com>
Cc: Martin Turon <mturon at xbow.com>, jch at rincon.com


On 2/12/07, David Moss <dmm at rincon.com> wrote:
> Thanks for your input, David.  We'll discuss next steps on
> our end given your advice, and see what we can do.

I wrote a quick-hack version of a T2 timer based on my comments, which
appears to work for a demo app I wrote recently that was crashing
before.

I've attached the code if you want to look at it. Some comments:
- it's got no comments ;-) (I wrote it rather quickly ;-))
- it doesn't handle wrap 32-bit time wrap around (so needs fixing to
be a full solution)
- it doesn't use the HPL (should be easily fixed)
- MINDT should probably be 2 (I had increased it while looking for a problem)
- oopsT0 and oopsNow should never be called (indicates some problem)

Could you try this and let me know if it helps with your problems? If
I have time, I'll clean it up and add wrap-around support.

To use: put the NA.nc and AlarmCounterMilliP.nc files in tos/platforms/mica.

David
-------------- next part --------------
A non-text attachment was scrubbed...
Name: NA.nc
Type: application/x-netcdf
Size: 3409 bytes
Desc: not available
Url : http://mail.millennium.berkeley.edu/pipermail/tinyos-2.0wg/attachments/20070221/18f0e8bc/NA.nc
-------------- next part --------------
A non-text attachment was scrubbed...
Name: AlarmCounterMilliP.nc
Type: application/x-netcdf
Size: 1210 bytes
Desc: not available
Url : http://mail.millennium.berkeley.edu/pipermail/tinyos-2.0wg/attachments/20070221/18f0e8bc/AlarmCounterMilliP.nc


More information about the Tinyos-2.0wg mailing list