Maxim MAXQ3100, MAXQ3100-EMN+ Datasheet

General Description
The MAXQ3100 microcontroller is a low-power, 16-bit RISC device that incorporates an integrated liquid-crystal display (LCD) interface that can drive up to 160 seg­ments, two analog comparators with precision internal
1.25V reference voltage, and a real-time clock (RTC) module with a dedicated battery-backup supply. An inter­nal temperature sensor allows software to monitor device temperature and optionally interrupt to alert when a tem­perature conversion is complete. The MAXQ3100 is uniquely suited for single-phase electricity metering appli­cations that require an external analog front-end, but can be used in any application that requires high-perfor­mance operation. The device operates at a fixed
4.194MHz, generated from the 32.76kHz RTC crystal. The device has 8kWords of EEPROM, 512 words of RAM, three 16-bit timers, and two universal synchronous/asyn­chronous receiver/transmitters (USARTs). The microcon­troller core and I/O are powered by a single 3.3V supply, and an additional battery supply keeps the RTC running during power outages.
Features
High-Performance, Low-Power, 16-Bit RISC Core
4.194MHz Operation, Approaching 1MIPS per MHz
3.3V Core and I/O
33 Instructions, Most Single-Cycle Three Independent Data Pointers Accelerate
Data Movement with Automatic Increment/ Decrement
16-Level Hardware Stack 16-Bit Instruction Word, 16-Bit Data Bus 16 x 16-Bit, General-Purpose Working Registers Optimized for C-Compiler (High-Speed/Density
Code)
Program and Data Memory
8kWords EEPROM 200,000 EEPROM Write/Erase Cycles 512 Words of Internal Data RAM JTAG-Compatible Debug Port Bootloader for
Programming
Peripheral Features
Up to 27 General-Purpose I/O Pins, Most 5V
Tolerant
160-Segment LCD Driver
Up to 4 COM and 40 Segments Static, 1/2, and 1/3 LCD Bias Supported No External Resistors Required
Two Analog Comparators with Internal +1.25V
Precision Reference
Two Serial USARTs, One with Infrared PWM
Support
Digital Temperature Sensor Three 16-Bit Programmable Timers/Counters 8-Bit, Subsecond, System Timer/Alarm Battery-Backed, 32-Bit RTC with
Time-of-Day Alarm and Digital Trim
Programmable Watchdog Timer
Flexible Programming Interface
Bootloader Simplifies Programming In-System Programming Through Debug Port Supports In-Application Programming of EEPROM
Power Consumption
1.9mA at 4.194MHz, 3.6V Operation
1.9µA Standby Current in Sleep Mode
Low-Power Divide-by-256 Mode
MAXQ3100
Mixed-Signal Microcontroller with Analog
Comparators, LCD, and RTC
________________________________________________________________
Maxim Integrated Products
1
Rev 0; 6/07
For pricing, delivery, and ordering information, please contact Maxim Direct at 1-888-629-4642, or visit Maxim’s website at www.maxim-ic.com.
EVALUATION KIT
AVAILABLE
Typical Application Circuits and Pin Configuration appear at end of data sheet.
Note: Some revisions of this device may incorporate deviations
from published specifications known as errata. Multiple revi­sions of any device may be simultaneously available through various sales channels. For information about device errata, go to:
www.maxim-ic.com/errata
.
MAXQ is a registered trademark of Maxim Integrated Products, Inc.
+
Denotes a Pb-free/RoHS-compliant device.
Ordering Information
Utility Meters
Battery-Powered and Portable Devices
Electrochemical and Optical Sensors
Industrial Control
Data-Acquisition Systems and Data Loggers
Home Appliances
Consumer Electronics
Thermostats/Humidity Sensors
Security Sensors
Gas and Chemical Sensors
HVAC
Smart Transmitters
Applications
PART TEMP RANGE PIN-PACKAGE
MAXQ3100-EMN+ -40°C to +85°C 80 MQFP
MAXQ3100
Mixed-Signal Microcontroller with Analog Comparators, LCD, and RTC
2 _______________________________________________________________________________________
ABSOLUTE MAXIMUM RATINGS
ELECTRICAL CHARACTERISTICS
(DVDD= V
RST
to 3.6V, f
32KIN
= 32.768kHz, TA= -40°C to +85°C, unless otherwise noted.) (Note 1)
Stresses beyond those listed under “Absolute Maximum Ratings” may cause permanent damage to the device. These are stress ratings only, and functional operation of the device at these or any other conditions beyond those indicated in the operational sections of the specifications is not implied. Exposure to absolute maximum rating conditions for extended periods may affect device reliability.
Voltage Range on DVDDRelative to DGND ..........-0.5V to +6.0V
Voltage Range on Any Pin Relative to DGND
(3V Tolerant) .........................................-0.5V to (DV
DD
+ 0.5V)
Continuous Output Current
(Any Single I/O Pin)..........................................................25mA
(All I/O Pins Combined) ...................................................25mA
Operating Temperature Range ...........................-40°C to +85°C
Junction Temperature......................................................+150°C
Storage Temperature Range .............................-65°C to +150°C
Soldering Temperature .......................................See IPC/JEDEC
J-STD-020 Specification
Digital Supply Voltage DVDD V
Digital Power-Fail Reset V
Battery Supply Voltage V
Active Current (Note 2)
Stop-Mode Current
ANALOG VOLTAGE COMPARATOR
Comparator Input-Voltage Range V
Internal Voltage Reference V
Input Offset Voltage VOS (Note 4) -10 +10 mV
Input Common-Mode Voltage V
Common-Mode Rejection Ratio CMMR (Note 4) 55 dB
DC Input-Leakage Current TA = +25°C, CMPx pin in tri-state mode -50 +50 nA
Comparator Setup Time t
Response T ime (CMPx Change to CMO Valid)
Current Consumed By Comparator
PARAMETER SYMBOL CONDITIONS MIN TYP MAX UNITS
2.34 2.5 2.71 V
RST
2.0 3.8 V
BAT
I
/1 mode 1.9 2.6
DD1
I
/2 mode 1.3 1.8
DD2
I
/4 mode 1.0 1.4
DD3
I
/8 mode 0.8 1.2
DD4
I
PMM1 mode 0.7 1.0
DD5
Brownout detector disab led (Note 3), T
I
STOP1
I
STOP2
I
STOP3
INPUT
REF
CMR
CMP_SETUP fSYS
t
CMP_RES P
I
DD_CMP
Brownout detector disab led (Note 3), T
Brownout detector disab led (Note 3), T
Brownout detector enabled (Note 3) 16.3 63.0
Brownout detector enabled, RTC enabled (Note 3)
GND DVDD V
1.15 1.25 1.35 V
(Note 4) 1 DVDD V
= 4.194MHz, V = 20mV (Note 4) 0.8 1.6 μs
f
= 4.194MHz, transition CMPx from
SYS
DGND to DV (Note 4)
Per enabled comparator, CMONx = 1, brownout detector enabled, CMPx pins in tri-state mode
3.3 3.6 V
RST
= +25°C
A
= +60°C
A
= +85°C
A
in ~2ns, t
DD
SYS
= 1/f
SYS
1.9 5.0
2.1 10.0
3.3 35.0
16.4 64.0
140 +
(2 x
t
SYS)
18.0 39.0 μA
600 +
t
(2 x
SYS)
mA
μA
ns
MAXQ3100
Mixed-Signal Microcontroller with Analog
Comparators, LCD, and RTC
_______________________________________________________________________________________ 3
ELECTRICAL CHARACTERISTICS (continued)
(DVDD= V
RST
to 3.6V, f
32KIN
= 32.768kHz, TA= -40°C to +85°C, unless otherwise noted.) (Note 1)
PARAMETER SYMBOL CONDITIONS MIN TYP MAX UNITS
DIGITAL I/O
Input High Voltage (Port 0, 1, 3, RESET)
Input High Voltage (Port 2) V
V
IH1
IH2
Input Low Voltage VIL
Output High Voltage (Al l Ports) VOH I
Output Low Voltage (Al l Ports, RESET)
Input Pullup Current I
V
OL
PULLUP
I
DVDD = 3.6V, input mode with weak pullup enabled
= 3mA
SOURCE
= 4mA 0.4 V
SINK
0.8 x
DV
0.8 x
DV
DV
0.4
DD
DD
DD
5.5 V
DV
DD
+ 0.3
0.2 x DV
DD
­ DV
DD
V
V
V
40 120 250 μA
Input Leakage (All Ports) IL Input mode with wea k pullup disabled -50 +50 nA
TEMPERATURE SENSOR
Temperature Conversion Time T
CONV
10-bit resolution, f
11-bit resolution, f
12-bit resolution, f
13-bit resolution, f
= 4.194MH z
SYS
= 4.194MH z
SYS
= 4.194MH z
SYS
= 4.194MH z
SYS
12.5
25
50
100
ms
Temperature Sensor Accuracy ±2 °C
RTC
Battery Supply Current, Battery­Backed Mode
Battery Supply Leakage Current I
I
BAT
BATL
Measured on V DV
= 0V, RTC enab led
DD
Measured on V
= 3.6V, RTC enabled
DV
DD
BAT
BAT
pin, V
pin, V
BAT
BAT
= 3.6V,
= 3.6V,
1.76 3.1 μA
4 200 nA
Trimm ing Resolut ion One 32.768kHz cloc k per 10s (Note 4) 3.05 ppm
LCD
LCD Supply Voltage V
LCD Bias Voltage 1 V
LCD Bias Voltage 2 V
LCD Adjustment Voltage V
2.4 DVDD V
LCD
V
+ 2/3
(Note 4)
LCD1
(Note 4)
LCD2
(Note 4) 0
ADJ
(V
V (V
ADJ
LCD
ADJ
LCD
- V
ADJ
+ 1/3
- V
ADJ
)
)
0.4 x V
LCD
V
V
V
Measured on DVDD pin; LCFG = 0xF7,
LCD Digital Operating Current
I
LCD
LCRA = 0x1B20, LCDx = 0xFF; LCD pins
0.1 μA
are unconnected
LCD Bia s Re sistor R
LCD Adjust Resistor R
40 k
LCD
LRA3:LRA0 = 1111 80 k
LADJ
MAXQ3100
Mixed-Signal Microcontroller with Analog Comparators, LCD, and RTC
4 _______________________________________________________________________________________
Note 1: Specifications to -40°C are guaranteed by design and are not production tested. Note 2: Measured on the DV
DD
pin with DVDD= 3.6V, V
BAT
= 3.8V, f
32KIN
= 32.768kHz, executing from EEPROM.
Note 3: Measured on the DV
DD
pin with DVDD= 3.6V, V
BAT
= 3.8V, f
32KIN
= 32.768kHz, all I/O pins disconnected, and not in reset.
Note 4: Specification guaranteed by design but not production tested.
ELECTRICAL CHARACTERISTICS (continued)
(DVDD= V
RST
to 3.6V, f
32KIN
= 32.768kHz, TA= -40°C to +85°C, unless otherwise noted.) (Note 1)
LCD Segment Voltage V
CLOCK SOURCES
External Cry stal Frequency f
Internal Clock Frequency f
System Clock Frequency f
JTAG-COMPATIBLE PROGRAMMING
TCK Frequency f
MEMORY CHARACTERISTICS
EEPROM Write/Era se Cyc les
EEPROM Data Retention Theta-JA = +85°C 50 Years
PARAMETER SYMBOL CONDITIONS MIN TYP MAX UNITS
Segment is driven at V
= -3μA, guaranteed by design
I
SEGxx
Segment is driven at V
= -3μA, guaranteed by design
I
SEGxx
SEGxx
Segment is driven at V I
= -3μA, guaranteed by design
SEGxx
Segment is driven at V I
= +3μA, guaranteed by design
SEGxx
32.768 kHz
32KIN
f
CLK
f
SYS
JTAG programming (Note 4) 0 f
TCK
= 32.768kHz, DVDD = 3.6V 4.110 4.194 4.278 MH z
32KIN
= f
SYS
/ system clock divisor
CLK
LCD
LCD1
LCD2
ADJ
; V
; V
; V
; V
LCD
LCD1
LCD2
ADJ
= 3V,
= 2V,
= 1V,
= 0V,
Theta- JA = +25°C 200,000
Theta- JA = +85°C 50,000
V
-
LCD
0.06
V
LCD1
0.04
V
LCD2
0.02
V
f
CLK /
256
ADJ
V
­ V
­ V
0.1
f
LCD
LCD1
LCD2
CLK
/ 8 MHz
SYS
V
Cycles
MAXQ3100
Pin Description
PIN NAME FUNCTION
1, 11, 52,
58, 75
DGND
Digital Ground
6, 53, 59,
76
DV
DD
Digital Supply Voltage (+3.3V)
General-Purpose, Digital, I/O, Type D Port; External Edge-Selectable Interrupt. These port
pins function as bidirectional I/O pins only. All port pins default to input mode with weak pullups enabled after a reset. All port pins can be configured as external interrupt inputs. All alternate function s must be enabled from software.
SPECIAL/ALTERNATE FUNCTION
PIN NAME
NAME FUNCTION
77 P0.0 INT0 TXD0 Serial Port 0 Tran sm it
78 P0.1 INT1 RXD0 Serial Port 0 Receive
79 P0.2 INT2 T0G Timer 0 Gate Input
80 P0.3 INT3 T0 Timer 0 Input
2 P0.4 INT4 T1 Timer 1 Input/Output
3 P0.5 INT5 T1EX Timer 1 External Capture/Reload Input
4 P0.6 INT6 — —
2–5, 77–80
P0.0–P0.7;
INT0–INT7;
TXD0, RXD0,
T0G, T0, T1, EX
5 P0.7 INT7 — —
7–10 COM0–COM3
Dedicated LCD Common-Voltage Outputs
12–43 SEG1–SEG31
Dedicated LCD Drive Outputs
General-Purpose, Digital, I/O, Type C Port; LCD Segment-Driver Output. These port pins
function as bidirectional I/O pins and LCD segment-driver outputs. All alternate functions must be enabled from software.
SPECIAL/ALTERNATE FUNCTION
PIN NAME
NAME FUNCTION
44 P2.0 SEG32 LCD Segment 32
45 P2.1 SEG33 LCD Segment 33
46 P2.2 SEG34 LCD Segment 34
47 P2.3 SEG35 LCD Segment 35
48 P2.4 SEG36 LCD Segment 36
49 P2.5 SEG37 LCD Segment 37
50 P2.6 SEG38 LCD Segment 38
44–51
P2.0–P2.7;
SEG32–SEG39
51 P2.7 SEG39 LCD Segment 39
54
V
LCD
LCD Bias-Control Voltage. Highest LCD drive voltage used in all bias modes. This pin must be connected to an external supply when using the LCD display controller.
55
V
LCD1
LCD Bias, Voltage 1. Next highest LCD drive voltage, used in 1/2 and 1/3 LCD bias modes. An internal resistor-divider sets the voltage at this pin. External resistor s and capacitors can be used to change LCD voltage or drive capability at this pin. This pin must be shunted externally to V
LCD2
when using 1/2 bias mode.
Mixed-Signal Microcontroller with Analog
Comparators, LCD, and RTC
_______________________________________________________________________________________ 5
MAXQ3100
Mixed-Signal Microcontroller with Analog Comparators, LCD, and RTC
6 _______________________________________________________________________________________
Pin Description (continued)
PIN NAME FUNCTION
56
V
LCD2
LCD Bias, Voltage 2. Third highest LCD drive voltage, used in 1/3 LCD bias mode only. An internal resistor-divider sets the voltage at this pin. External resistor s and capacitors can be used to change LCD voltage or drive capability at this pin. This pin must be shunted externally to V
LCD1
when using 1/2 bias mode.
57
V
ADJ
LCD Adjustment Voltag e. Lowest LCD drive voltage, u sed in al l bias modes . Connect to DGND through an external resistor to provide external control of the LCD contrast. Leave disconnected for internal contrast adjustment.
General-Purpose, Digital, I/O, Type D Port; External Edge-Selectable Interrupt. These port pins function as bidirectional I/O pins only. All port pins default to input mode with weak pullups enabled after a reset. Port pins P1.0–P1.3 can be configured as external interrupt inputs. Al l alternate funct ions must be enabled from software.
SPECIAL/ALTERNATE FUNCTION
PIN NAME
NAME FUNCTION
60 P1.0 INT8 T2B Timer 2 Secondary I/O
61 P1.1 INT9 T2A Timer 2 Primary I/O
62 P1.2 INT10 TXD1 Serial Port 1 Transmit
60–63
P1.0–P1.3;
INT8–INT11;
T2B, T2A, TXD1,
RXD1
63 P1.3 INT11 RXD1 Serial Port 1 Receive
General-Purpose, Digital, I/O, Type C Port; External Edge-Selectable Interrupt. These port pins function as bidirectional I/O pins only. All port pins default to input mode with weak pullups enabled after a reset. All alternate functions must be enab led from software, except for the JTAG-compatible functions that are enabled by default fo llowing reset.
SPECIAL/ALTERNATE FUNCTION
PIN NAME
NAME FUNCTION
64 P3.0 TDI JT AG TAP Data Input
65 P3.1 TDO JTAG TAP Data Output
66 P3.2 TCK JT AG TAP Clock Input
67 P3.3 TMS JTAG TAP Mode-Select Input
68 P3.4 SQW RTC Square-Wave Output
69 P3.5 CMP0 Analog Comparator Input 0
64–70
P3.0–P3.6;
TDI, TDO, TCK,
TMS, SWQ,
CMP0, CMP1
70 P3.6 CMP1 Analog Comarator Input 1
71
RESET
Active-Low, Digital Reset Input/Output. The CPU i s held in reset when thi s pin is low and begins executing from the reset vector when released. The pin must be pulled high by an
external 50k resistor. This pin is driven low as an output when an internal reset condition occurs.
72
V
BAT
Digital Battery-Backup Supply. This supply provides an optional battery backup for the RTC when DV
DD
power is removed. If this pin is connected to a nominal 3.3V battery then
the RTC will operate and battery-backed register contents will be preserved when DV
DD
is
removed. If battery backup is not required this pin should be connected directly to DV
DD
.
73 32KIN
74 32KOUT
32kHz Crystal Input/Output. Connect an external, 6pF 32kHz watch crystal between 32KIN and 32KOUT to generate the system clock.
MAXQ3100
Mixed-Signal Microcontroller with Analog
Comparators, LCD, and RTC
_______________________________________________________________________________________ 7
Detailed Description
The following is an introduction to the primary features of the microcontroller. More detailed descriptions of the device features can be found in the data sheets, errata sheets, and user’s guides described later in the
Additional Documentation
section.
MAXQ Core Architecture
The MAXQ3100 is a high-performance, CMOS, 16-bit RISC microcontroller with EEPROM and an integrated 160-segment LCD controller. It is structured on a highly advanced, accumulator-based, 16-bit RISC architec­ture. Fetch and execution operations are completed in one cycle without pipelining, because the instruction
contains both the op code and data. The result is a streamlined 4.194 million instructions-per-second (MIPS) microcontroller.
The highly efficient core is supported by a 16-level hardware stack, enabling fast subroutine calling and task switching. Data can be quickly and efficiently manipulated with three internal data pointers. Multiple data pointers allow more than one function to access data memory without having to save and restore data pointers each time. The data pointers can automatically increment or decrement following an operation, elimi­nating the need for software intervention. As a result, the application speed is greatly increased.
Functional Diagram
ANALOG COMPARATOR
8kW EEPROM
(PROGRAM)
TIMER 0-TYPE
16-BIT TIMER/COUNTER
TIMER 1-TYPE
16-BIT TIMER/COUNTER
TIMER 2-TYPE
16-BIT TIMER/COUNTER
SERIAL USART
SERIAL USART WITH
INFRARED PWM
SUPPORT
DIGITAL TEMPERATURE
SENSOR
512W SRAM
(D ATA)
(16 x 16-BIT ACCUMULATORS)
WATCHDOG TIMER
POWER REDUCTION/ CLOCK GENERATION
POR
JTAG
TMS TDI TDO TCK
2kW UTILITY ROM
+1.25V
REFERENCE
ANALOG COMPARATOR
3.3V
160-SEGMENT LCD
DRIVER
REAL-TIME CLOCK
EXTERNAL 32.768kHz
CRYSTAL
MAXQ20 RISC CORE
MAXQ3100
MAXQ3100
Mixed-Signal Microcontroller with Analog Comparators, LCD, and RTC
8 _______________________________________________________________________________________
Instruction Set
The instruction set is composed of fixed-length, 16-bit instructions that operate on registers and memory loca­tions. The instruction set is highly orthogonal, allowing arithmetic and logical operations to use any register along with the accumulator. Special-function registers control the peripherals and are subdivided into register modules. The family architecture is modular, so that new devices and modules can reuse code developed for existing products.
The architecture is transport-triggered. This means that writes or reads from certain register locations can also cause side effects to occur. These side effects form the basis for the higher-level op codes defined by the assembler, such as ADDC, OR, JUMP, etc. The op codes are actually implemented as MOVE instructions between certain system register locations, while the assembler handles the encoding, which need not be a concern to the programmer.
The 16-bit instruction word is designed for efficient exe­cution. Bit 15 indicates the format for the source field of the instruction. Bits 0 to 7 of the instruction represent the source for the transfer. Depending on the value of the format field, this can either be an immediate value or a source register. If this field represents a register, the lower four bits contain the module specifier and the upper four bits contain the register index in that module.
Bits 8 to 14 represent the destination for the transfer. This value always represents a destination register, with the lower four bits containing the module specifier and the upper three bits containing the register subindex within that module.
Anytime that it is necessary to directly select one of the upper 24 index locations in a destination module, the prefix register PFX is needed to supply the extra desti­nation bits. This prefix register write is inserted auto­matically by the assembler and requires only one additional execution cycle.
Memory Organization
The device incorporates several memory areas:
• 2kWords utility ROM
• 8kWords of EEPROM for program storage
• 512 words of SRAM for storage of temporary variables
• 16-level, 16-bit-wide stack memory for storage of program return addresses and general-purpose use
The memory is arranged by default in a Harvard archi­tecture, with separate address spaces for program and
data memory. The configuration of program and data space depends on the current execution location.
• When executing code from EEPROM memory, the SRAM and utility ROM are accessible in data space.
• When executing code from SRAM, the EEPROM and utility ROM are accessible in data space.
• When executing code from the utility ROM, the EEPROM memory and SRAM are accessible in data space.
Refer to the
MAXQ Family User’s Guide: MAXQ3100
Supplement
for more details.
In all cases, whichever memory segment is currently being executed from cannot be accessed in data space. To allow the use of lookup tables and similar constructs in the memory, the utility ROM contains a set of lookup and block copy routines (refer to the user’s guide sup­plement for more details).
The incorporation of EEPROM allows the device to be reprogrammed, eliminating the expense of throwing away one-time programmable devices during develop­ment and field upgrades. Program memory can be password protected with a 16-word key, denying access to program memory by unauthorized individuals.
Stack Memory
A 16-bit-wide internal stack provides storage for pro­gram return addresses and general-purpose use. The stack is used automatically by the processor when the CALL, RET, and RETI instructions are executed and interrupts serviced. The stack can also be used explic­itly to store and retrieve data by using the PUSH, POP, and POPI instructions.
On reset, the stack pointer, SP, initializes to the top of the stack (0Fh). The CALL, PUSH, and interrupt-vector­ing operations increment SP, then store a value at the stack location pointed to by SP. The RET, RETI, POP, and POPI operations retrieve the value at the stack location pointed to by SP, and then decrement SP.
Utility ROM
The utility ROM is a 2kWord block of internal ROM memory that defaults to a starting address of 8000h. The utility ROM consists of subroutines that can be called from application software. These include:
• In-system programming (bootloader) over the JTAG­compatible debug port
• In-circuit debug routines
• User-callable routines for in-application flash pro­gramming and code space table lookup
MAXQ3100
Mixed-Signal Microcontroller with Analog
Comparators, LCD, and RTC
_______________________________________________________________________________________ 9
Figure 1. Memory Map When Executing from EEPROM
PROGRAM
SPACE
DATA SPACE
(BYTE MODE)
DATA SPACE
(WORD MODE)
EXECUTING FROM
512 x 16
DATA SRAM
2k x 16
UTILITY ROM
8k x 16
PROGRAM EEPROM
A1FFh
A000h
87FFh
8000h
1FFFh
0000h
4k x 8
UTILITY ROM
1k x 8
DATA SRAM
8FFFh
8000h
03FFh
0000h
2k x 16
UTILITY ROM
512 x 16
DATA SRAM
87FFh
8000h
01FFh
0000h
Loading...
+ 21 hidden pages