|
Introduction to the 68HC12 |
|
|
1 | (13) |
|
Brief History of Computers |
|
|
2 | (2) |
|
Computers and Embedded Controllers |
|
|
4 | (4) |
|
Applications of Embedded Controllers |
|
|
8 | (1) |
|
|
9 | (4) |
|
|
9 | (1) |
|
|
10 | (3) |
|
|
13 | (1) |
|
|
13 | (1) |
|
68HC12 Assembly Language Programming |
|
|
14 | (57) |
|
|
15 | (4) |
|
Motorola Assembly Language |
|
|
19 | (1) |
|
Instruction Execution Cycle |
|
|
20 | (3) |
|
|
23 | (25) |
|
Data Transfer and Manipulation Instructions |
|
|
26 | (5) |
|
|
31 | (6) |
|
Logical and Bit Operations |
|
|
37 | (7) |
|
|
44 | (2) |
|
Optional: Fuzzy Logic Instructions |
|
|
46 | (2) |
|
|
48 | (6) |
|
|
49 | (1) |
|
Immediate Addressing Mode |
|
|
49 | (1) |
|
|
50 | (1) |
|
|
50 | (1) |
|
|
51 | (2) |
|
|
53 | (1) |
|
|
54 | (5) |
|
Directives (pseudo-op code) and a Good Programming Approach |
|
|
59 | (3) |
|
|
59 | (2) |
|
A Good Programming Approach |
|
|
61 | (1) |
|
|
62 | (6) |
|
|
68 | (1) |
|
|
69 | (2) |
|
Advanced Assembly Programming |
|
|
71 | (47) |
|
|
72 | (4) |
|
|
76 | (2) |
|
|
78 | (4) |
|
|
78 | (1) |
|
|
79 | (1) |
|
|
80 | (2) |
|
|
82 | (9) |
|
Subroutine Calls and Returns |
|
|
83 | (3) |
|
Parameter-Passing Techniques |
|
|
86 | (5) |
|
68HC12 D-Bug 12 Utility Subroutines |
|
|
91 | (8) |
|
|
99 | (5) |
|
|
101 | (3) |
|
|
104 | (6) |
|
|
110 | (4) |
|
|
114 | (1) |
|
|
115 | (1) |
|
|
115 | (3) |
|
|
118 | (48) |
|
Conventional Controller versus Fuzzy Logic Controller |
|
|
119 | (3) |
|
Fuzzy Logic Controller for a Balancing Robot |
|
|
122 | (11) |
|
|
122 | (1) |
|
Optional: Dynamic Model for the Robot |
|
|
123 | (4) |
|
|
127 | (6) |
|
The 68HC12 Fuzzy Logic Operations |
|
|
133 | (16) |
|
Membership Function Design Process |
|
|
136 | (2) |
|
Fuzzy Rule Implementation |
|
|
138 | (1) |
|
68HC12 Fuzzification Process |
|
|
139 | (2) |
|
Unweighted Rule Evaluation (REV) and Weighted Rule Evaluation (REVW) |
|
|
141 | (5) |
|
68HC12 Defuzzification Process |
|
|
146 | (2) |
|
Other Fuzzy Logic Controller-Related Instructions |
|
|
148 | (1) |
|
|
149 | (7) |
|
Some Comments on Fuzzy Logic Controller Design |
|
|
156 | (2) |
|
|
158 | (5) |
|
|
163 | (1) |
|
|
163 | (1) |
|
|
164 | (2) |
|
|
166 | (33) |
|
|
167 | (2) |
|
The 68HC12 Hardware System |
|
|
169 | (5) |
|
|
174 | (1) |
|
|
174 | (1) |
|
|
175 | (2) |
|
|
177 | (11) |
|
|
177 | (1) |
|
|
178 | (3) |
|
The Timing System---The Standard Timer Module |
|
|
181 | (2) |
|
|
183 | (2) |
|
|
185 | (1) |
|
|
186 | (1) |
|
Serial Communications---The Multiple Serial Interface |
|
|
187 | (1) |
|
The Data Conversion System---The Analog-to-Digital Converter |
|
|
188 | (1) |
|
Application---Switches, Keypads, Indicators---Oh my! |
|
|
188 | (6) |
|
|
188 | (2) |
|
|
190 | (1) |
|
Indicators---Light Emitting Diodes |
|
|
191 | (1) |
|
Indicators---Seven-Segment Displays |
|
|
192 | (1) |
|
Programming Switches and Indicators |
|
|
193 | (1) |
|
Application---Wall Following Robot |
|
|
194 | (1) |
|
|
194 | (1) |
|
|
195 | (1) |
|
|
196 | (3) |
|
Exceptions---Resets and Interrupts |
|
|
199 | (41) |
|
|
200 | (3) |
|
|
203 | (1) |
|
General Interrupt Response |
|
|
204 | (3) |
|
Reset and Exception Systems Aboard the 68HC12 |
|
|
207 | (11) |
|
|
208 | (4) |
|
|
212 | (3) |
|
|
215 | (1) |
|
|
216 | (2) |
|
Interrupt System-Associated Registers |
|
|
218 | (1) |
|
How Does 68HC12 Respond to an Interrupt? |
|
|
218 | (5) |
|
Writing Interrupt Service Routines for the 68HC812A4EVB |
|
|
223 | (2) |
|
How to Program an ISR---An Example |
|
|
225 | (4) |
|
Programming the Real-Time Interrupt (RTI) System |
|
|
229 | (4) |
|
|
233 | (1) |
|
Advanced Interrupt Topics |
|
|
233 | (1) |
|
|
234 | (4) |
|
|
238 | (1) |
|
|
238 | (1) |
|
|
238 | (2) |
|
The 68HC12 Clock Module and Standard Timer Module (TIM) |
|
|
240 | (54) |
|
|
241 | (1) |
|
|
242 | (1) |
|
|
242 | (2) |
|
Clock Divider Chain Serving the TIM |
|
|
244 | (1) |
|
|
244 | (3) |
|
Components of the Timer Module |
|
|
247 | (24) |
|
|
250 | (2) |
|
Free-Running Counter-Associated Registers |
|
|
252 | (3) |
|
Input Capture/Output Compare Channels |
|
|
255 | (12) |
|
|
267 | (4) |
|
The Real-Time Interrupt (RTI) |
|
|
271 | (1) |
|
Programming Input Capture, Output Compare, and the Pulse Accumulator Features of the TIM |
|
|
272 | (7) |
|
Programming the Input Capture System |
|
|
272 | (2) |
|
Programming the Input Capture System with an Interrupt |
|
|
274 | (1) |
|
Programming the Output Compare System |
|
|
274 | (2) |
|
Programming the Output Compare System with Interrupts |
|
|
276 | (2) |
|
Programming the Pulse Accumulator System |
|
|
278 | (1) |
|
|
279 | (1) |
|
|
280 | (10) |
|
|
290 | (1) |
|
|
290 | (1) |
|
|
290 | (4) |
|
|
294 | (57) |
|
|
295 | (1) |
|
|
296 | (1) |
|
|
296 | (10) |
|
Memory Capacity and Control Signals |
|
|
296 | (2) |
|
|
298 | (2) |
|
Memory Technologies: ROM versus RAM |
|
|
300 | (2) |
|
|
302 | (4) |
|
|
306 | (1) |
|
|
306 | (41) |
|
|
307 | (6) |
|
68HC12 and Memory Chip Control Signal Connections |
|
|
313 | (4) |
|
Timing Analysis of Basic Memory Operations |
|
|
317 | (14) |
|
|
331 | (3) |
|
|
334 | (11) |
|
|
345 | (2) |
|
|
347 | (1) |
|
|
348 | (1) |
|
|
349 | (1) |
|
|
349 | (2) |
|
Analog-to-Digital (ATD) Converter |
|
|
351 | (41) |
|
|
352 | (2) |
|
Transducer Interface Design |
|
|
354 | (2) |
|
Analog-to-Digital Conversion Background Theory |
|
|
356 | (6) |
|
|
357 | (1) |
|
|
358 | (1) |
|
Quantizing and Resolution |
|
|
359 | (1) |
|
|
360 | (2) |
|
Analog-to-Digital Converter Technologies |
|
|
362 | (7) |
|
Successive-Approximation Converters |
|
|
362 | (1) |
|
Integration-Based Converters |
|
|
362 | (3) |
|
|
365 | (2) |
|
|
367 | (2) |
|
The 68HC12 Analog-to-Digital (ATD) Conversion System |
|
|
369 | (13) |
|
|
370 | (1) |
|
68HC12 ATD System Control Registers |
|
|
370 | (8) |
|
Programming the 68HC12 ATD System |
|
|
378 | (3) |
|
Programming the ATD System Using Interrupts |
|
|
381 | (1) |
|
|
382 | (3) |
|
|
385 | (4) |
|
|
389 | (1) |
|
|
390 | (1) |
|
|
390 | (2) |
|
68HC12 Communications System---Multiple Serial Interface |
|
|
392 | (46) |
|
Need for Communication Features |
|
|
393 | (1) |
|
Fundamentals of Serial Communication |
|
|
394 | (5) |
|
Serial Communication Terminology |
|
|
394 | (3) |
|
Serial Communication Signals |
|
|
397 | (2) |
|
Multiple Serial Interface |
|
|
399 | (1) |
|
The Serial Communications Interface |
|
|
399 | (14) |
|
Hardware Description---The SCI Transmitter |
|
|
402 | (1) |
|
Hardware Description---The SCI Receiver |
|
|
403 | (1) |
|
|
404 | (6) |
|
SCI Transmitter and Receiver Operation |
|
|
410 | (1) |
|
Programming the Serial Communication Interface |
|
|
411 | (2) |
|
SPI---Serial Peripheral Interface |
|
|
413 | (20) |
|
|
413 | (3) |
|
|
416 | (4) |
|
|
420 | (6) |
|
|
426 | (3) |
|
|
429 | (4) |
|
|
433 | (2) |
|
|
435 | (1) |
|
|
436 | (2) |
A 68HC12 Instruction Set |
|
438 | (22) |
B 68HC812A4 Register Set |
|
460 | (5) |
C Number Systems and Number Arithmetic |
|
465 | (17) |
|
|
465 | (3) |
|
|
468 | (8) |
|
The 2's Complement Number Representation |
|
|
469 | (3) |
|
|
472 | (4) |
|
Changing the Base of Numbers |
|
|
476 | (4) |
|
Summary and Further Readings |
|
|
480 | (2) |
D Digital Logic Fundamentals |
|
482 | (9) |
|
|
482 | (1) |
|
Basic Combinational Logic |
|
|
483 | (4) |
|
Medium-Scale Integration Combinational Circuits |
|
|
486 | (1) |
|
Sequential Logic Circuits |
|
|
487 | (3) |
|
|
487 | (1) |
|
MSI Sequential Circuit Components |
|
|
488 | (2) |
|
|
490 | (1) |
E Mobile Robot and Related Products for the 68HC12 |
|
491 | (14) |
|
Building Your Own Mobile Robot |
|
|
492 | (4) |
|
68HC12-Related Hardware and Software Products |
|
|
496 | (9) |
|
|
496 | (2) |
|
|
498 | (7) |
Index |
|
505 | |