View Single Post
  #2   Spotlight this post!  
Unread 28-01-2008, 18:15
kaszeta's Avatar
kaszeta kaszeta is offline
Registered User
FRC #0095 (Grasshoppers)
Team Role: Mentor
 
Join Date: Feb 2004
Rookie Year: 2002
Location: Lebanon, NH
Posts: 334
kaszeta is a glorious beacon of lightkaszeta is a glorious beacon of lightkaszeta is a glorious beacon of lightkaszeta is a glorious beacon of lightkaszeta is a glorious beacon of light
Re: Timers and MPLab

Quote:
Originally Posted by joshyboy9987 View Post
So, this is my first year using MPLab instead of EasyC and I was wondering if there was a way to access a hardware timer at all. I know it can be done, cuz EasyC has a function to do it, but I couldn't find anything on the forums.
It's relatively easy. Which version of the code are you using (Kevin's new code, or the 2007 default code)?

The basics are in http://www.ifirobotics.com/docs/time...004-jan-14.pdf

But basically you setup the timer, create an ISR that updates some timer variables, and a set of functions that let you read the timer values.