You are currently viewing How to Interface LEDs with MSP430F5529 MSP430 Development Board

How to Interface LEDs with MSP430F5529 MSP430 Development Board

Spread the love

This blog post summarize Interface LED with MSP430F5529 MSP430 development board

The MSP430 Development kit is specifically designed to help students to master the required skills in the area of embedded systems. This kit designed in such a way that all the possible features of the microcontroller will be easily used by the students. The kit supports with Code Composer Studio v4 and later through USB port.

Texas Instrument MicrocontrollerMSP430 Development kit is proposed to smooth the progress of developing and debugging of various designs encompassing of speed 16-bit Microcontrollers. It integrates on board PS2, UART, ADC, PWM, Temperature Sensor, Relay, Buzzer, I2c Seven Segment, I2C Serial EEPROM, I2C RTC, Temperature Sensor LM35, Stepper Motor Driver, Matrix Keypad, Switch, LED, Traffic Light Controller, LCD & GLCD Display to create a stand-alone versatile test platform. User can easily engage in Development in this platform, or use it as reference to application primer.

LED (Light Emitting Diodes)

Light Emitting Diodes (LED) is the most commonly used one components, usually to display the pins digital states. Typical uses of LEDs include timers, alarm devices & confirmation of user input such as a keystroke or mouse click.

Interfacing LED with MSP430F5529

Figure shows how to interface the LED to microcontroller. As you can see the Cathode is connected through a resistor to GND & the Anode is connected to the Microcontroller pin. So when the Port Pin is HIGH the LED is ON & when the Port Pin is LOW the LED is turned OFF.

The MSP430 Development kit has eight numbers of LEDs, connected with the following lines

☞MSB P6.7 P6.6 P6.5 P6.4

☞LSB P7.7 P7.6 P7.5 P7.4

Pin Assignment with MSP430F5529

Circuit Diagram to Interface LED with MSP430F5529

C Program to ON and OFF LED using MSP430F5529


Title : Program for ON & OFF LEDs


#define LED 4
#define Switch 24
#define DEBUG 0 void MSP430F5529_Clock_Init();
void DelayMs(int Ms);

int main(void)

// Stop watchdog timer P6DIR |= 0xF0;
// Set P6.4-P6.7 to Output direction P7DIR |= 0xF0;
// Set P7.4-P7.7 to Output direction


P6OUT = 0x00;
P7OUT = 0x00;

P6OUT = 0xF0;
P7OUT = 0xF0;



void DelayMs(int Ms)

int i; while(Ms>0)


Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.