15
15-43
Rev.1.0
(11) Setting the TEP0P, TEP0M, TEP1P, and TEP1M Control Registers
Set the value H'11 in each register to enable counting in PD sensor support mode.
Note: Use all of the data tables 0-255 to define the sine wave.
(12) Setting the TIN Input Processing Control Register
Select rising-edge detection for each TIN input.
Figure 15.3.1 PD Sensor Support Initialization Flow
PD MODULE
15.3 Initialization for PD Sensor Support
Initialization for PD sensor
support
Set Parameter Table Data and
DA Control Register
Set Position Detection Accuracy
Select Register
Set Prescalers A and B
Set DACNT Reload Register
Set DACNT Register
Set the following registers
• Prescalers 0C and 1C
• PD0,1 Data Updating Disable Event Select Registers
• PD0,1 Data Updating Control Registers
• ABD0,1 Mask Registers
• S Error 0,1 Detection Range Select Registers
• ABD0,1 Compare Registers
• PITCH0,1 Compare Registers
Set Interrupt Controller
• Set TIN and PD Interrupt Control Registers
Set TIN Input Processing Control Register
Set Input/output Port Operation
Mode Register
Initialization complete
• Set DACNT and TPD Control Registers
• Set TEP0P, TEP0M, TEP1P, and
TEP1M Control Registers
●
Parameter Table Data
Set table data necessary to generate sine wave
●
DA Control Register
Select continuous mode for DA0 and enable its output
Select from 10, 11, or 12-bit resolutions
●
Prescaler A
Set H'03 for 10-bit accuracy
Set H'07 for 11-bit accuracy
Set H'0F for 12-bit accuracy
●
Set H'00 in Prescaler B
Set H'FF in DACNT Reload Register
Set H'00 in Prescalers 0C and 1C
Set interrupt priority
●
TIN Interrupt Control Register
• Enable/disable TIN input detection interrupt
• Enable/disable TIN input error detection interrupt
●
PD Interrupt Control Register
• Enable/disable ABD compare match interrupt
• Enable/disable PITCH compare match interrupt
• Enable/disable S error interrupt
Select rising-edge detection
Set these registers simultaneously
by using STH instruction
• Set TEP0P and TEP0M Control Registers simultaneously
by using STH instruction
• Set TEP1P and TEP1M Control Registers simultaneously
by using STH instruction
Содержание 32172
Страница 20: ... This is a blank page 16 ...
Страница 21: ...1 1 Overview 1 2 Block Diagram 1 3 Pin Functions 1 4 Pin Layout CHAPTER 1 CHAPTER 1 OVERVIEW ...
Страница 44: ...1 1 24 Rev 1 0 This is a blank page Overview 1 4 Pin Layout ...
Страница 58: ...2 2 14 Rev 1 0 This is a blank page CPU 2 6 Data Formats ...
Страница 122: ...4 4 26 Rev 1 0 This is a blank page EIT 4 13 Precautions on EIT ...
Страница 200: ...7 7 6 Rev 1 0 This is a blank page RESET 7 4 Precautions to Be Taken Immediately after Reset ...
Страница 240: ...8 8 40 Rev 1 0 This is a blank page INPUT OUTPUT PORTS AND PIN FUNCTIONS 8 5 Precautions on Input Output Ports ...
Страница 298: ...9 9 58 Rev 1 0 This is a blank page DMAC 9 4 Precautions on Using DMAC ...
Страница 416: ...10 10 118 Rev 1 0 This is a blank page INPUT OUTPUT TIMERS 10 6 TOM Output Related 16 bit Timers ...
Страница 658: ...14 14 16 Rev 1 0 REAL TIME DEBUGGER RTD 14 4 Typical Connection with the Host This is a blank page ...
Страница 718: ...16 16 16 Rev 1 0 This is a blank page D A CONVERTERS 16 3 Functional Description of the D A Converters ...
Страница 766: ...18 18 22 Rev 1 0 WAIT CONTROLLER 18 3 Typical Operation of the Wait Controller This is a blank page ...
Страница 776: ...19 19 10 Rev 1 0 RAM BACKUP MODE 19 4 Exiting RAM Backup Mode Wakeup This is a blank page ...
Страница 777: ...CHAPTER 20 CHAPTER 20 OSCILLATION CIRCUIT 20 1 Oscillator Circuit 20 2 Clock Generator Circuit ...
Страница 782: ...20 20 6 Rev 1 0 OSCILLATION CIRCUIT 20 2 Clock Generator Circuit This is a blank page ...
Страница 856: ...23 23 26 Rev 1 0 This is a blank page ELECTRICAL CHARACTERISTICS 23 6 AC Characteristics ...
Страница 857: ...24 1 A D Conversion Characteristics CHAPTER 24 CHAPTER 24 STANDARD CHARACTERISTICS ...
Страница 859: ...Appendix 1 1 Dimensional Outline Drawing APPENDIX 1 APPENDIX 1 MECHANICAL SPECIFICATIONS ...
Страница 861: ...Appendix 2 1 M32R E Instruction Processing Time APPENDIX 2 APPENDIX 2 INSTRUCTION PROCESSING TIME ...
Страница 865: ...Appendix 3 1 Precautions about Noise APPENDIX 3 APPENDIX 3 PRECAUTIONS ABOUT NOISE ...