EasyManua.ls Logo

Texas Instruments MSP430 User Manual

Texas Instruments MSP430
413 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #97 background imageLoading...
Page #97 background image
97
/*
* TA0CTL, Timer_A3 Control Register
*
* TASSEL_2 -- SMCLK
* ID_3 -- Divider - /8
* MC_2 -- Continuous Mode
*/
TA0CTL = TASSEL_2 | ID_3 | MC_2;
We want to blink the Launchpad board’s LEDs at the rate of 250 milliseconds. Thus, we need to check
or compare if the counter register TA0R has gone past 50% of the full scale 16-bit value. This is an
event marker because with reference to this mark, we toggle the states of the LEDs. The idea shown
here is actually the concept with which PWMs are generated by compare-match principle inside timer
hardware and so it is worth understanding this idea.
if(TA0R >= 32768)
{
P1OUT |= BIT6;
P1OUT &= ~BIT0;
}
else
{
P1OUT |= BIT0;
P1OUT &= ~BIT6;
}

Table of Contents

Other manuals for Texas Instruments MSP430

Question and Answer IconNeed help?

Do you have a question about the Texas Instruments MSP430 and is the answer not in the manual?

Texas Instruments MSP430 Specifications

General IconGeneral
Program Memory TypeFlash
Clock SpeedUp to 25 MHz (depending on the specific device)
Flash MemoryUp to 512 KB (depending on the specific device)
RAMUp to 66 KB (depending on the specific device)
Operating Voltage1.8V - 3.6V (depending on the specific device)
ADC10-bit or 12-bit SAR ADC
Communication InterfacesUART, SPI, I2C, USB
DMAYes (depending on the specific device)
Operating Temperature-40°C to +85°C
Architecture16-bit RISC
Low Power ModesMultiple (LPM0 to LPM4)

Related product manuals