Home
Texas Instruments
Microcontrollers
MSP430
Texas Instruments MSP430 Student Guide
5
of 1
of 1 rating
398 pages
Give review
Manual
Specs
To Next Page
To Next Page
To Previous Page
To Previous Page
Loading...
Timer Details: Confi
guring TIMER_A
Routing the OUT signal t
o a pin, as shown here,
lets us drive ext
ernal hardware directly from t
he
output of the timer
.
(In
fact, we’ll use thi
s
feature to let the tim
er directly drive an LED during one
of the upcoming lab exer
c
ises.)
MSP430 Workshop
-
Timer
s
6 -
27
272
274
Table of Contents
Chapter Topics
4
Table of Contents
4
Administrative Topics
5
Workshop Agenda
6
TI Products
8
Ti's Entire Portfolio
8
Wireless Products
9
Ti's Embedded Processors
10
MSP430 Family
12
Msp430 Cpu
15
MSP430 Memory
19
Memory Map
19
Ram
20
Tlv
20
Fram
21
MSP430 Peripherals
24
Gpio
24
Timers
25
Clocking and Power Management
26
Analog
27
Communications (Serial Ports, USB, Radio)
28
Hardware Accelerators
29
Ulp
31
Profile Your Activities
32
Launchpad's
36
Chapter Topics
40
Programming C with CCS
41
TI Support Ecosystem
41
Run-Time Software
42
Low-Level C Header Files
42
Msp430Ware (Driverlib)
42
Energia
43
Ti-Rtos
43
Development Tools
44
Integrated Development Environments (IDE)
44
Other MSP430 Tools
45
Support & Community
46
Wiki
46
Forums
47
Examining Ccsv5
48
Functional Overview
48
Editing
48
Debugging
50
Target Config & Emulation
50
Perspectives
51
Workspaces & Projects
52
Some Final Notes about Ccs/Eclipse
53
Creating a Project
54
Adding Files to a Project
55
Portable Projects
55
Licensing/Pricing
56
Changing a CCS User Licence
57
Writing MSP430 C Code
58
Build Config & Options
58
Processor Options
58
Debug Options
59
Optimize Options (Aka Release Options)
59
Build Configurations
60
Data Types
61
Device Specific Files (.H and .CMD)
62
MSP430 Compiler Intrinsic Functions
64
Lab 2 - Ccsv5 Projects
65
Lab Outline
66
Lab 2 - Ccsv5 Projects
67
Lab 2A - Creating a New CCS Project
67
Intro to Workshop Files
67
Start Code Composer Studio and Open a Workspace
68
00430
69
CCS Edit" Perspective
70
Create a New Project
71
Build the Code (Ignore Advice)
74
Debug the Code
75
Fix Your Project
79
Build, Load, Connect and Run
80
Lab 2B - My First Blinky
81
Create and Examine Project
81
Build, Load, Run
82
Restart, Single-Step, Run to Line
83
Lab 2C - Putting the OOB Back into Your Device
85
(Optional) Lab 2D - Msp430Flasher
86
Programming the UE OOB Demo Using Msp430Flasher
86
Programming Blinky with Msp430Flasher
89
Cleanup
90
Chapter Topics
92
Msp430Ware (Driverlib)
93
Installing Msp430Ware
93
Driverlib
94
Driverlib Modules
95
Programming Methods - Summary
95
Using GPIO with Msp430Ware
93
Msp430 Gpio
96
GPIO Basics
96
Input or Output
97
GPIO Output
98
GPIO Input
99
Drive Strength
100
Flexible Pin Useage (Muxing)
101
Pin Selection
102
Port Mapping
103
Summary
104
Before We Get Started Coding
106
Include Files
106
Disable Watchdog Timer
107
Pin Unlocking (Wolverine Only)
108
Lab 3
109
Lab 3 Worksheet
111
Msp430Ware Driverlib
111
GPIO Output
111
Lab 3A - Blinking an LED
112
Add Msp430Ware Driverlib
114
Add the Code to Main.C
116
Debug
117
Lab 3B - Reading a Push Button
119
GPIO Input Worksheet
119
File Management
120
Add Setup Code (to Reference Push Button)
122
Modify Loop
123
Verify Code
124
Optional Exercises
124
Chapter 3 Appendix
125
Chapter Topics
128
Operating Modes (Reset → Active)
129
BOR → por → PUC → Active (AM)
130
Clocking
132
What Clocks Do You Need
132
Mclk, Smclk, Aclk
134
Oscillators (Clock Sources)
135
Clock Details (by Device Family)
137
Using Msp430Ware to Configure Clocking
142
Additional Clock Features
144
DCO Setup and Calibration
147
How the DCO Works
148
Factory Callibration (G2Xx, Fr5Xx)
152
Runtime Calibration
154
VLO 'Calibration
157
Other Initialization (WDT, PMM)
158
Watchdog Timer
159
PMM with LDO, SVM, SVS, and BOR
160
Operating Voltages
162
Initialization Summary (Template)
166
Lab Topics
168
Lab 4 Worksheet
170
Lab 4A - Program the MSP430 Clocks
173
File Management
173
Do Clock Code
173
Table of Contents
174
Initialization Code - Three more Simple Changes
176
Debugging the Clocks
177
Extra Credit (I.e. Optional Step) - Change the Rate of Blinking
179
(Optional) Lab 4B - Exploring the Watchdog Timer
180
First, a Couple of Questions
180
Play with Last Lab Exercise
180
File Management
181
Edit the Source File
181
Keep It Running
183
Extra Credit - Try Driverlib's Watchdog Example (#3)
183
(Optional) Lab 4C - Using Crystal Oscillators
184
Chapter 04 Appendix
186
Define HF_CRYSTAL_FREQUENCY_IN_HZ
187
Define LF_CRYSTAL_FREQUENCY_IN_HZ
187
Define MCLK_FLLREF_RATIO
188
Ucs_Clocksignalinit
188
Ucs_Clock_Divider_1
188
Ucs_Initfllsettle
188
Chapter Topics
192
Interrupts
193
Interrupts, the Big Picture
193
Polling Vs Interrupts
193
Processor States and Interrupts
195
Threads: Foreground and Background
196
How Interrupts Work
197
Interrupt Must Occur
199
Interrupt Is Flagged (and Must be Enabled)
200
Cpu's Hardware Response
202
Your Software ISR
204
Interrupts: Priorities & Vectors
207
Interrupts and Priorities
207
Interrupt Vector (IV) Registers
208
Interrupt Vector Table
209
Dedicated ISR (Interrupt Service Routine)
212
Grouped ISR (Interrupt Service Routine)
214
Enabling Interrupts
216
Miscellaneous Topics
219
Interrupt Service Routines - Coding Suggestions
219
GPIO Interrupt Summary
220
Interrupt Processing Flow
220
Interrupts and TI-RTOS Scheduling
221
Threads - Foreground and Background
221
TI-RTOS Thread Types
223
Summary: TI-RTOS Kernel
226
Lab Topics
228
Interrupts
229
Lab 5 - Interrupts
229
Lab 5 Worksheet
229
General Interrupt Questions
229
Interrupt Flow
229
Interrupt Priorities & Vectors
230
Lab 5A - Push Your Button
232
File Management
232
Configure/Enable GPIO Interrupt
235
Add a Simple Interrupt Service Routine (ISR)
238
Sidebar - Vector Errors
238
(Optional) Lab 5B - Can You Make a Watchdog Blink
241
Import and Explore the WDT_A Interval Timer Example
241
Run the Code
243
Change the LED Blink Rate
243
Appendix
244
Chapter Topics
248
Overview of MSP430 Timers
249
TIMER_A/B Nomenclature
250
Timer Summary
251
Timer Basics: How Timers Work
252
Counter
252
Frequency, Time-Period, Resolution
253
Capture
254
Compare
255
Timer Details: Configuring TIMER_A
258
Counter: Timer_A_Configure
259
Timer Counting Modes
260
2A. Capture: Timer_A_Initcapture()
265
2B. Compare: Timer_A_Initcompare()
267
Summary of Timer Setup Code - Part 2
269
Output Modes
270
PWM Anyone
275
Clear Interrupt Flags and Timer_A_Starttimer()
276
Interrupt Code (Vector & ISR)
277
Differences between Timer's a and B
279
Lab Topics
282
Lab 6A - Simple Timer Interrupt
283
Lab 6A Worksheet
283
File Management
287
Setup the Timer
288
Debug/Run
289
Timers
283
(Extra Credit) Lab 6B - Timer Using up Mode
290
Lab 6B Worksheet
290
File Management
293
Change the Timer Setup Code
293
Debug/Run
294
Archive and Close the Project
295
(Extra Credit) Lab 6C - Timer Using up Mode
297
Lab 6C Worksheet
297
File Management
300
Change the GPIO Setup
300
Change the Timer Setup Code
301
Chapter Topics
314
USB Devices
315
What Is USB
315
Msp430'S USB Support
318
How USB Works
323
Descriptions and Classes
326
Quick Overview of Msp430'S USB Stack
331
Abc's of USB
333
Plan Your System
333
Connect & Enumerate
334
Managing My App & Transferring Data
336
Lab Topics
342
Lab 7A - LED On/Off HID Example
343
Lab 7B - LED On/Off CDC Example
346
Play with the Demo
349
Lab 7C - CDC 'Simple Send' Example
351
Lab 7D - Creating a CDC Push Button App
353
Import Empty USB Project Steps
353
Use the Descriptor Tool
354
Add 'Custom' Code to Project
356
Chapter Topics
360
What Is Arduino
361
Energia
362
Programming Energia (and Arduino)
365
Programming with 'Wiring
365
Wiring Language/Library Reference
366
How Does 'Wiring' Compare
367
Examples, Lots of Examples
371
Energia/Arduino References
372
Lab 8
373
Installing the Launchpad Drivers
374
Starting and Configuring Energia
375
Lab 8A - Blink
378
Your First Sketch
378
Lab 8B - Pushing Your Button
382
Examine the Code
382
Reverse Button/Led Action
383
Lab 8C - Serial Communication (and Debugging)
384
What if the Serial Monitor Is Blank
385
Blink with Serial Communication
386
Another Pushbutton/Serial Example
386
Lab 8D - Using Interrupts
387
Adding an Interrupt
387
Lab 8E - Using TIMER_A
389
Appendix - Looking 'Under the Hood
390
Where, Oh Where, Is Main
390
Two Ways to Change the MSP430 Clock Source
392
Sidebar - Initclocks()
393
Sidebar Cont'D - Where Is F_CPU Defined
394
Lab Debrief
395
Other manuals for Texas Instruments MSP430
Manual
413 pages
User Guide
193 pages
Application Report
30 pages
5
Based on 1 rating
Ask a question
Give review
Questions and Answers:
Need help?
Do you have a question about the Texas Instruments MSP430 and is the answer not in the manual?
Ask a question
Texas Instruments MSP430 Specifications
General
Brand
Texas Instruments
Model
MSP430
Category
Microcontrollers
Language
English
Related product manuals
Texas Instruments MSP430F5529
128 pages
Texas Instruments MSP430 series
191 pages
LaunchPad MSP430G2553
33 pages
MSP-EXP430FR5969
47 pages
LaunchPad MSP‑EXP430G2ET
33 pages
Serial Programming Adapter MSP430
53 pages
Texas Instruments C2000
41 pages
Texas Instruments CC2541
370 pages
Texas Instruments AM5728
42 pages
Texas Instruments TM4C1294NCPDT
1890 pages
TMS320F2837 D Series
52 pages
C2000 LED BoosterPack
15 pages