Pumpkin, Inc.

Pumpkin User Forums

TAR time counter

For issues specific to TI's MSP430 line of ultra-low-power microcontrollers, including compilers (e.g. Quadravox AQ430), IDEs (e.g. IAR Embedded Workbench) and development tools (e.g. TI MSP-FET430 Flash Emulation Tool).

TAR time counter

Postby grovesy » Wed Jul 28, 2004 12:30 am

Hi, I am creating a program in C where the exact time (well more accurate then just the second) is recorded when an interrupt happens. So to do this I want to read the TAR (as i believe this is where the clock counter is stored)

My code is currently:

#include <msp430x12x2.h>

int temp; // Temp store for counter value

void main(void)
WDTCTL = WDTPW + WDTHOLD; // Stop watchdog timer
TACTL = TASSEL_1 + TACLR; //Start timer_A

temp = TAR;

So the idea of my code is just for testing, and i add a watcher to the 'temp' value to see it change. But for some reason it always stays on 0!

Any ideas what i'm doing wrong?


Posts: 1
Joined: Tue Jul 27, 2004 11:00 pm

Re: TAR time counter

Postby aek » Wed Jul 28, 2004 7:59 am

For MSP430 questions that aren't related to Salvo, I'd suggest posting to the Yahoo MSP430 group.


Posts: 1888
Joined: Sat Aug 26, 2000 11:00 pm

Return to TI's MSP430

Who is online

Users browsing this forum: No registered users and 1 guest