PMS132
12-bit ADC Enhanced Controller
Datasheet
Version 0.02 – Nov. 23, 2017
Copyright
2017 by PADAUK Technology Co., Ltd., all rights reserved
10F-2, No. 1, Sec. 2, Dong-Da Road, Hsin-Chu 300, Taiwan, R.O.C.
TEL: 886-3-532-7598
www.padauk.com.tw
PMS132
12-bit ADC Enhanced Controller
IMPORTANT NOTICE
PADAUK Technology reserves the right to make changes to its products or to terminate
production of its products at any time without notice. Customers are strongly
recommended to contact PADAUK Technology for the latest information and verify
whether the information is correct and complete before placing orders.
PADAUK Technology products are not warranted to be suitable for use in life-support
applications or other critical applications. PADAUK Technology assumes no liability for
such applications. Critical applications include, but are not limited to, those which may
involve potential risks of death, personal injury, fire or severe property damage.
PADAUK Technology assumes no responsibility for any issue caused by a customer’s
product design. Customers should design and verify their products within the ranges
guaranteed by PADAUK Technology. In order to minimize the risks in customers’ products,
customers should design a product with adequate operating safeguards.
PMS132 is NOT designed for AC RC step-down powered, high power ripple or high EFT
requirement application. Please do NOT apply PMS132 to those application products.
© Copyright 2017, PADAUK Technology Co. Ltd
Page 2 of 95
PDK-DS-PMS132-EN_V002 – Nov. 23, 2017
PMS132
12-bit ADC Enhanced Controller
Table of content
1. Features ................................................................................................................................. 9
1.1.
1.2.
1.3.
1.4.
Special Features ..................................................................................................................... 9
System Features ..................................................................................................................... 9
CPU Features ......................................................................................................................... 9
Package Information ............................................................................................................... 9
2. General Description and Block Diagram .......................................................................... 10
3. Pin Assignment and Description ...................................................................................... 11
4. Device Characteristics ....................................................................................................... 18
4.1.
4.2.
4.3.
4.4.
4.5.
4.6.
4.7.
4.8.
4.9.
4.10.
4.11.
4.12.
4.13.
4.14.
4.15.
4.16.
AC/DC Device Characteristics .............................................................................................. 18
Absolute Maximum Ratings................................................................................................... 20
Typical ILRC frequency vs. VDD and temperature ................................................................ 21
Typical IHRC frequency deviation vs. VDD ........................................................................... 21
Typical ILRC Frequency vs. Temperature ............................................................................. 22
Typical IHRC Frequency vs. Temperature (calibrated to 16MHz) .......................................... 22
Typical operating current vs. VDD @ system clock = ILRC/n ................................................ 23
Typical operating current vs. VDD @ system clock = IHRC/n ............................................... 23
Typical operating current vs. VDD @ system clock = 4MHz EOSC / n .................................. 24
Typical operating current vs. VDD @ system clock = 32KHz EOSC / n (reserved) ................ 24
Typical operating current vs. VDD @ system clock = 1MHz EOSC / n .................................. 25
Typical IO driving current (I
OH
) and sink current (I
OL
) ............................................................. 25
Typical IO input high/low threshold voltage (V
IH
/V
IL
) .............................................................. 27
Typical resistance of IO pull high device ............................................................................... 28
Typical power down current (I
PD
) and power save current (I
PS
) .............................................. 28
Timing charts for boot up conditions ...................................................................................... 29
5. Functional Description ....................................................................................................... 30
5.1.
5.2.
5.3.
5.4.
Program Memory - OTP ........................................................................................................ 30
Boot Procedure ..................................................................................................................... 30
Data Memory - SRAM ........................................................................................................... 31
Oscillator and clock ............................................................................................................... 31
5.4.1. Internal High RC oscillator and Internal Low RC oscillator ......................................... 31
5.4.2. Chip calibration .......................................................................................................... 31
5.4.3. IHRC Frequency Calibration and System Clock ........................................................ 32
5.4.4. External Crystal Oscillator ......................................................................................... 33
© Copyright 2017, PADAUK Technology Co. Ltd
Page 3 of 95
PDK-DS-PMS132-EN_V002 – Nov. 23, 2017
PMS132
12-bit ADC Enhanced Controller
5.4.5. System Clock and LVR level ..................................................................................... 35
5.4.6. System Clock Switching ............................................................................................ 36
5.5.
Comparator ........................................................................................................................... 37
5.5.1
5.5.2
5.5.3
5.6
5.7
Internal reference voltage (V
internal R
) ........................................................................... 38
Using the comparator ................................................................................................ 40
Using the comparator and band-gap 1.20V ............................................................... 40
16-bit Timer (Timer16) .......................................................................................................... 41
8-bit Timer (Timer2/Timer3) with PWM generation ................................................................ 43
5.7.1
5.7.2
5.7.3
Using the Timer2 to generate periodical waveform .................................................... 44
Using the Timer2 to generate 8-bit PWM waveform................................................... 45
Using the Timer2 to generate 6-bit PWM waveform................................................... 47
PWM Waveform ........................................................................................................ 48
Hardware and Timing Diagram .................................................................................. 49
Equations for 11-bit PWM Generator ......................................................................... 50
5.8
11-bit PWM Generator .......................................................................................................... 48
5.8.1
5.8.2
5.8.3
5.9
5.10
5.11
WatchDog Timer ................................................................................................................... 50
Interrupt ................................................................................................................................ 51
Power-Save and Power-Down .............................................................................................. 53
5.11.1 Power-Save mode (“stopexe”) ................................................................................... 53
5.11.2 Power-Down mode (“stopsys”) .................................................................................. 54
5.11.3 Wake-up .................................................................................................................... 54
5.12
5.13
IO Pins .................................................................................................................................. 55
Reset and LVR...................................................................................................................... 56
5.13.1 Reset ......................................................................................................................... 56
5.13.2 LVR reset .................................................................................................................. 56
5.14
Analog-to-Digital Conversion (ADC) module ......................................................................... 57
5.14.1 The input requirement for AD conversion .................................................................. 58
5.14.2 Select the reference high voltage .............................................................................. 59
5.14.3 ADC clock selection................................................................................................... 59
5.14.4 Configure the analog pins .......................................................................................... 59
5.14.5 Using the ADC........................................................................................................... 59
5.15
Multiplier ............................................................................................................................... 60
6. IO Registers ........................................................................................................................ 61
6.1.
6.2.
6.3.
6.4.
6.5.
6.6.
ACC Status Flag Register (flag), IO address = 0x00 ............................................................. 61
Stack Pointer Register (sp), IO address = 0x02 .................................................................... 61
Clock Mode Register (clkmd), IO address = 0x03 ................................................................. 61
Interrupt Enable Register (inten), IO address = 0x04 ............................................................ 62
Interrupt Request Register (intrq), IO address = 0x05 ........................................................... 62
Multiplier Operand Register (mulop), IO address = 0x08 ....................................................... 62
Page 4 of 95
PDK-DS-PMS132-EN_V002 – Nov. 23, 2017
© Copyright 2017, PADAUK Technology Co. Ltd
PMS132
12-bit ADC Enhanced Controller
6.7.
6.8.
6.9.
6.10.
6.11.
6.12.
6.13.
6.14.
6.15.
6.16.
6.17.
6.18.
6.19.
6.20.
6.21.
6.22.
6.23.
6.24.
6.25.
6.26.
6.27.
6.28.
6.29.
6.30.
6.31.
6.32.
6.33.
6.34.
6.35.
6.36.
6.37.
6.38.
6.39.
6.40.
6.41.
6.42.
6.43.
6.44.
6.45.
6.46.
Multiplier Result High Byte Register (mulrh), IO address = 0x09 ........................................... 62
Timer16 mode Register (t16m), IO address = 0x06............................................................... 63
External Oscillator setting Register (eoscr), IO address = 0x0a............................................. 63
Interrupt Edge Select Register (integs), IO address = 0x0c ................................................... 64
Port A Digital Input Enable Register (padier), IO address = 0x0d .......................................... 64
Port B Digital Input Enable Register (pbdier), IO address = 0x0e .......................................... 64
Port A Data Register (pa), IO address = 0x10 ....................................................................... 65
Port A Control Register (pac), IO address = 0x11 ................................................................. 65
Port A Pull-High Register (paph), IO address = 0x12 ............................................................ 65
Port B Data Register (pb), IO address = 0x14 ....................................................................... 65
Port B Control Register (pbc), IO address = 0x15 ................................................................. 65
Port B Pull-High Register (pbph), IO address = 0x16 ............................................................ 65
Miscellaneous Register (misc), IO address = 0x17................................................................ 66
Comparator Control Register (gpcc), IO address = 0x18 ....................................................... 66
Comparator Selection Register (gpcs), IO address = 0x19 .................................................... 67
Reset Status Register (rstst), IO address = 0x1b .................................................................. 67
Timer2 Control Register (tm2c), IO address = 0x1c .............................................................. 68
Timer2 Counter Register (tm2ct), IO address = 0x1d ............................................................ 68
Timer2 Scalar Register (tm2s), IO address = 0x1e................................................................ 68
Timer2 Bound Register (tm2b), IO address = 0x09 ............................................................... 69
PWMG0 control Register (pwmg0c), IO address = 0x20 ....................................................... 69
PWMG0 Scalar Register (pwmg0s), IO address = 0x21 ........................................................ 69
PWMG0 Counter Upper Bound High Register (pwmg0cubh), IO address = 0x24 ................. 69
PWMG0 Counter Upper Bound Low Register (pwmg0cubl), IO address = 0x25 ................... 70
PWMG0 Duty Value High Register (pwmg0dth), IO address = 0x22 ..................................... 70
PWMG0 Duty Value Low Register (pwmg0dtl), IO address = 0x23 ....................................... 70
Timer3 Control Register (tm3c), IO address = 0x32 .............................................................. 70
Timer3 Counter Register (tm3ct), IO address = 0x33 ............................................................ 71
Timer3 Scalar Register (tm3s), IO address = 0x34................................................................ 71
Timer3 Bound Register (tm3b), IO address = 0x3f ................................................................ 71
ADC Control Register (adcc), IO address = 0x3b .................................................................. 71
ADC Mode Register (adcm), IO address = 0x3c.................................................................... 72
ADC Regulator Control Register (adcrgc), IO address = 0x3d............................................... 72
ADC Result High Register (adcrh), IO address = 0x3e .......................................................... 72
ADC Result Low Register (adcrl), IO address = 0x3f ............................................................. 72
PWMG1 control Register (pwmg1c), IO address = 0x26 ....................................................... 73
PWMG1 Scalar Register
(pwmg1s),
IO address = 0x27 ........................................................ 73
PWMG1 Counter Upper Bound High Register
(pwmg1cubh),
IO address = 0x2A ................. 73
PWMG1 Counter Upper Bound Low Register
(pwmg1cubl),
IO address = 0x2B ................... 73
PWMG1 Duty Value High Register (pwmg1dth), IO address = 0x28 ..................................... 74
Page 5 of 95
PDK-DS-PMS132-EN_V002 – Nov. 23, 2017
© Copyright 2017, PADAUK Technology Co. Ltd