You are on page 1of 4

9. Explain different types of clock sources and different types of oscillators used in MSP430.

MSP430 microcontroller has a powerful unified clock system (UCS) module which supports low
system cost and ultra-low power consumption. The UCS module generates three types of clock
signals and these clock signals are used to meet the major design targets of low system cost and
low power consumption

XT1CLK: Low-frequency or high-frequency oscillator


VLOCLK: Very low power, low-frequency oscillator
REFOCLK: low-frequency oscillator
DCOCLK: Digitally controlled oscillator XT2CLK: High-frequency oscillator

1. XT1CLK, VLOCLK, REFOCLK sources:

The oscillator circuit as shown in Figure 2.8.1 consists of XT1CLK, VLOCLK and REFOCLK
sources.
The XT1 oscillator generates an ultra-low-current consumption low-frequency XT1CLK clock
signal by
using externally connected 32.768-KHz watch crystal and generates high-frequency XT1CLK
signal by
using standard crystals, resonators. The XT1 oscillator supports for external clock sources in the
4-
MHz to 32-MHz range using bypass mode of operation.
2. DCOCLK (Digitally-Controlled Oscillator Clock) source:

The DCO is an integrated RC-type oscillator which generates DCOCLK signal. The
frequency of
DCOCLK varies with temperature, voltage, and from device to device. The DCO frequency can
be adjusted by user program using the DCOx, MODx, and RSELx bits.
The digital control of the oscillator allows frequency stabilization despite its RC-type
characteristics
using FLL hardware as shown in Figure 2.8.2. The XT1CLK can be used as a clock reference
into the
FLL which stabilizes the clock reference and generates DCOCLK. The DCOCLK signal is
further divided by 1,2,4,8, 6 or 32 using clock divider and generates the DCOCLKDIV signal.
3. XT2CLK source:

XT2CLK is a 4 MHz to 32 MHz range high-frequency oscillator that can be used with standard
crystals,
resonators, or external clock sources. XT2CLK can also be used as a clock reference into the
FLL to generate DCOCLK.
10. Interface LED’s to port P1.0 to P1.7 of MSP430 microcontroller and write a embedded C
program to blink LED’s.

#include<reg51.h>
sbit ToggleLed = P2^1; //pin connected to toggle Led
void Delay(const unsigned int uCount) //Function to provide delay
{
unsigned int uLoop1=0;
unsigned int uLoop2=0;
for(; uLoop1 < uCount; uLoop1++)
{
for(uLoop2=0; uLoop2 <65535; uLoop2++)
{}
}
}
int main()
{
ToggleLed=0; //configuring as output pin
while(1)
{
ToggleLed=1; //Make pin high
Delay(2);
ToggleLed=0; // Make pin low
Delay(2);
}
}

You might also like