André: The code is in tos/chips/msp430/timer. Start from LocalTimeHybridMicroC.nc, and follow the wirings from there. The most important part is in Msp430HybridAlarmCounterP.nc, which shouldn't be too hard to port to AVR.
Janos On Thu, Sep 6, 2012 at 12:00 PM, André Rodrigues <[email protected]> wrote: > Hi Janos > > I have read the following email, and that technique could be usefull for my > work, so I would like to have access to that code, where can I find it? > > Basically, I would like to measure the time in scenarios where the processor > could be in sleep mode, with more precision than the 32khz cristal enables. > > Thanks, and Regards, > > André > > > ----- Original Message ----- From: "Miklos Maroti" > <[email protected]> > To: "Christian Renner" <[email protected]> > Cc: "Janos Sallai" <[email protected]>; > <[email protected]> > Sent: Friday, July 08, 2011 8:54 AM > Subject: Re: [Tinyos-help] measuring time in microseonds > > > Hi Christian, > > Janos Sallay has written a combined timer that uses the 32 khz crystal > and the MCU to get a fine granularity timer. He has done that for the > MSP430 platform, but I am sure it works with some modification on > ATMEGAs. > > Best, > Miklos > > On Thu, Jul 7, 2011 at 6:01 PM, Christian Renner > <[email protected]> wrote: >> >> Hi everybody, >> >> I was trying to measure time deltas in microseconds (IRIS platform) >> using the component LocalTimeMicroC. Unfortunately, the component uses >> Timer1, which is not running when the MCU is sleeping. What I thus get >> is the local time in microseconds (actually 0.9-something of that time, >> for the MCU is running at only 7.37 Mhz) minus the sleeping time of the >> processor. In my case, preventing the MCU from sleeping is no option. >> >> To cut a long story short: Is there any way to realize a (near-to) >> microsecond 32bit counter/time source while not preventing the MCU from >> entering a sleep state? I'd be happy about any hint or comment. >> >> >> Best >> Christian >> >> -- >> __Christian_Renner________________________________________________________ >> Hamburg University of Technology [email protected] >> Institute of Telematics (E-17) Tel.: (+49) 40 42878-3746 >> Schwarzenbergstrasse 95 Fax: (+49) 40 42878-2581 >> 21073 Hamburg, Germany http://www.ti5.tu-harburg.de/staff/renner >> _______________________________________________ >> 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 _______________________________________________ Tinyos-help mailing list [email protected] https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help
