
x
CHAPTER 21 MULTI-PULSE GENERATOR ...................................................... 377
21.1 Overview .......................................................................................................................... 378
21.2 Block Diagram ................................................................................................................. 381
21.3 Pins .................................................................................................................................. 389
21.4 Interrupts ......................................................................................................................... 390
21.5 Operations ....................................................................................................................... 392
21.5.1 Operation of Position Detection .................................................................................. 394
21.5.2 Operation of Data Write Control Unit .......................................................................... 396
21.5.3 Operation of 16-bit MPG Output Data Buffer Register (Upper/Lower)
(OPDBRHx/OPDBRLx) .............................................................................................. 400
21.5.4 Operation of Data Transfer of 16-bit MPG Output Data Register (Upper/Lower) ....... 402
21.5.4.1 At OPDBRH0 and OPDBRL0 Write ......................................................................... 404
21.5.4.2 At 16-bit Reload Timer Underflow ........................................................................... 405
21.5.4.3 At Position Detection ............................................................................................... 407
21.5.4.4 At Position Detection and Timer Underflow ............................................................. 409
21.5.4.5 At Position Detection or Timer Underflow ................................................................ 412
21.5.4.6 At One-shot Position Detection ............................................................................... 414
21.5.4.7 When One-shot Position Detection and Reload Timer Underflow ........................... 415
21.5.4.8 When One-shot Position Detection or Reload Timer Underflow ............................. 416
21.5.5 Operation of DTTI Input Control ................................................................................. 417
21.5.6 Operation of Noise Cancellation Function .................................................................. 420
21.5.7 Operation of 16-bit Timer ............................................................................................ 421
21.6 Registers ......................................................................................................................... 426
21.6.1 16-bit MPG Output Control Register (Upper) (OPCUR) ............................................. 427
21.6.2 16-bit MPG Output Control Register (Lower) (OPCLR) .............................................. 429
21.6.3 16-bit MPG Output Data Register (Upper/Lower) (OPDUR/OPDLR) ......................... 431
21.6.3.1 16-bit MPG Output Data Register (Upper) (OPDUR) .............................................. 432
21.6.3.2 16-bit MPG Output Data Register (Lower) (OPDLR) ............................................... 434
21.6.4 16-bit MPG Output Data Buffer Register (Upper/Lower) (OPDBRHx/OPDBRLx) ...... 435
21.6.4.1 16-bit MPG Output Data Buffer Register (Upper) (OPDBRHx) ............................... 436
21.6.4.2 16-bit MPG Output Data Buffer Register (Lower) (OPDBRLx) ................................ 438
21.6.5 16-bit MPG Input Control Register (Upper/Lower) (IPCUR/IPCLR) ........................... 440
21.6.5.1 16-bit MPG Input Control Register (Upper) (IPCUR) ............................................... 441
21.6.5.2 16-bit MPG Input Control Register (Lower) (IPCLR) ............................................... 443
21.6.6 16-bit MPG Compare Clear Register (Upper/Lower) (CPCUR/CPCLR) .................... 445
21.6.7 16-bit MPG Timer Buffer Register (Upper/Lower) (TMBUR/TMBLR) ......................... 446
21.6.8 16-bit MPG Timer Control Status Register (TCSR) .................................................... 447
21.6.9 16-bit MPG Noise Cancellation Control Register (NCCR) .......................................... 449
21.7 Notes on Using Multi-pulse Generator ............................................................................ 450
21.8 Sample Program for Multi-pulse Generator ..................................................................... 452
CHAPTER 22 UART/SIO ..................................................................................... 455
22.1 Overview .......................................................................................................................... 456
22.2 Configuration ................................................................................................................... 457
22.3 Channel ........................................................................................................................... 459
22.4 Pins .................................................................................................................................. 460
22.5 Interrupts ......................................................................................................................... 461
22.6 Operations and Setting Procedure Example ................................................................... 462
22.6.1 Operations in Operation Mode 0 ................................................................................ 463