O'Reilly logo

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Microcontroller Programming and Interfacing Texas Instruments MSP430

Book Description

This book provides a thorough introduction to the Texas Instruments MSP430 microcontroller. The MSP430 is a 16-bit reduced instruction set (RISC) processor that features ultra low power consumption and integrated digital and analog hardware. Variants of the MSP430 microcontroller have been in production since 1993. This provides for a host of MSP430 products including evaluation boards, compilers, and documentation. A thorough introduction to the MSP430 line of microcontrollers, programming techniques, and interface concepts are provided along with considerable tutorial information with many illustrated examples. Each chapter provides laboratory exercises to apply what has been presented in the chapter. The book is intended for an upper level undergraduate course in microcontrollers or mechatronics but may also be used as a reference for capstone design projects. Also, practicing engineers already familiar with another microcontroller, who require a quick tutorial on the microcontroller, will find this book very useful.

Table of Contents

  1. Preface
  2. Timer Systems
    1. Introduction
    2. Motivation: Real-Time Location Systems (RTLS)
    3. Approach
    4. Background
    5. Time related signal parameters
      1. Frequency
      2. Period
      3. Duty Cycle
      4. Pulse Width Modulation
    6. MSP430 Clock System (1/2)
    7. MSP430 Clock System (2/2)
    8. MSP430 Unified Clock System
    9. Watchdog Timer
      1. Protecting from Software Failure
      2. Interval Timer
    10. Basic Timer 1
      1. Real Time Clock
    11. Input Capture and Output Compare Features
      1. Timing System Overview and Background Theory
      2. Applications
      3. MSP430 Timers
      4. MSP430 Free Running Counter
      5. Input Capture
      6. Output Compare
      7. Timer_B system
    12. Laboratory Exercise: Generation of Varying Pulse Width Modulated Signals to Control DC Motors
    13. Summary
    14. References and Further Reading
    15. Chapter Problems
  3. Resets and Interrupts
    1. Motivation
    2. Background
    3. MSP430 Resets/Interrupts Overview
    4. MSP430 Resets
    5. Interrupts
      1. Interrupt Handling Process
      2. Interrupt Priority
      3. Interrupt Service Routine (ISR) (1/2)
      4. Interrupt Service Routine (ISR) (2/2)
    6. Laboratory Exercise
    7. References and Further Reading
    8. Chapter Problems
  4. Analog Peripherals
    1. Motivation
    2. Background
    3. Analog-to-Digital Conversion
      1. Sampling
      2. Quantization
      3. Encoding
    4. Digital to Analog Converter
    5. MSP430 Analog-to-Digital Converter
      1. Comparator
      2. MSP430 12-bit Analog-to-Digital Converter
      3. Programming the ADC12 converter
    6. MSP430 Digital-to-Analog Converter
    7. Laboratory Exercise
    8. References and Further Reading
    9. Chapter Problems
  5. Communication Systems
    1. Motivation
    2. Serial communication concepts
    3. MSP430 UART
      1. UART features
      2. UART overview
      3. Character format
      4. Baud rate selection
      5. UART associated interrupts
      6. UART registers
      7. UART code examples
    4. Serial Peripheral Interface—SPI
      1. SPI Operation
      2. MSP430 SPI features
      3. MSP430 SPI hardware configuration
      4. MSP430 SPI Registers
      5. SPI code examples
    5. Inter-Integrated Communication - I2C Module
      1. MSP430 as a slave device
      2. MSP430 as a master device
      3. I2C code examples
    6. USB Module
    7. RF communication using MSP430
    8. Laboratory Exercise
    9. Conclusion
    10. References and Further Reading
    11. Chapter Problems
  6. System Level Design
    1. Submersible Robot
      1. Requirements
      2. Structure chart
      3. Circuit Diagram
      4. UML Activity Diagram
      5. Microcontroller Code
      6. Project Extensions
    2. Weather Station
      1. Requirements
      2. Structure chart
      3. Circuit diagram
      4. UML activity diagrams
      5. Microcontroller code
    3. Motor Speed Control
    4. Circuit diagram
      1. Requirements
      2. Structure chart
      3. UML activity diagrams
      4. Microcontroller code
    5. Autonomous Maze Navigating Robot
      1. Description
      2. Requirements
      3. Circuit diagram
      4. Structure chart
      5. UML activity diagrams
      6. Microcontroller code
    6. Summary
    7. References
    8. Chapter Problems
  7. Programming
    1. Overview
    2. The Big Picture
    3. Anatomy of a Program
      1. Comments
      2. Include files
      3. Functions
      4. Program constants
      5. Variables
      6. Main program
    4. Fundamental programming concepts
      1. Operators
      2. Programming constructs
      3. Decision processing
    5. References
  8. Authors' Biographies
  9. Index