APLUS APU4006 4-Bit Micro-Controller with LCD Driver, 1K Word FEATURES · · · · · · · · · · · · · · · · Very low current dissipation. Wide operating voltage range. Supports both Ag and Li batteries. Powerful instruction set. 4-level subroutine nesting (including interrupt). 4 event driven interrupts, 2 external and 2 internal. ROM size: 1024 x 15 bits. RAM size: 48 x 4 bits. Input ports: 1 port/ 4 pins (M-PORT). Control output: ALARM. LCD driver outputs (can drive up to 60 LCD segments). Mask option to select 3 LCD drive modes: static, duplex 1/2 duty 1/2 bias, 1/3 duty 1/2 bias. Mask option permits LCD driver output pins to be used for DC output ports. Up to 20 pins are available. SEG13-SEG20 can be selected by open-drain output. Segment PLA circuit permits any layout on the LCD panel. Built-in clock generator (crystal or RC). Built-in voltage doubler, halver. GENERAL DESCRIPTION TheAPU4006 is a single-chip 4-bit microcontroller with LCD drivers. It can drive up to 3 common time 20 segments, i.e. 60 segments LCD driver. This 4-bit microcontroller contains a 4-bit parallel processing ALU, 1024 x 15-bit program ROM, 48 x 4-bit data RAM, input ports, alarm driver, timer, clock generator, crystal and RC oscillator circuit, LCD driver and 70 powerful instructions in a single chip. It uses HALT instruction to stop all internal operations other than the timer, clock generator, crystal/RC oscillator and LCD driver. Very low current dissipation can be easily achieved by combining 4 types of interrupt function and HALT instruction to minimize the operation cycle. BLOCK DIAGRAM ALARM M1~4 OUTPUT PORT INPUT PORT SEG1~20 COM 1~3 VDD1~2 LCD DIRVER SEGMENT PLA 4 BITS DATA BUS OSC IN OSC OUT OSCILLATOR 6 BITS PRESET TIMER CUP 1 CUP 2 PRE-DIVIDER CONTROL CIRCUIT R E S E T INT 1/8 ALU RAM 48 X 4 BITS 10 BITS PROGRAM COUNTER INSTRUCTION DECODER 4 LEVELS STACK PROM 1024 X 15 BITS APLUS APU4006 1.0 PACKAGE & CHIP INFORMATION 1995 x 1590 (mm2) min. 140mm Chip Size Pad Pitch VDD2 ALARM RESET INTPAD M1 M2 M3 M4 TESTA OSCIN OSCOUT Bounding Diagram VDD1 VDD GND CUP1 COM2 CUP2 COM3 COM1 SEG20 SEG1 SEG19 SEG2 SEG16 SEG15 SEG14 SEG13 SEG12 SEG11 SEG10 SEG9 SEG8 SEG17 SEG7 SEG4 SEG6 SEG18 SEG5 SEG3 2.0 PIN/PAD ASSIGNMENT Unit : um Pad Name No. 1 GND 2 VDD1 3 VDD2 4 ALARM 5 RESET 6 INT 7 M1 8 M2 9 M3 10 M4 11 TESTA 12 OSCOUT Coordinate X Y 1909.5 1128.60 1909.5 1275.60 1757.40 1500.60 1610.40 1500.60 1465.80 1500.60 1327.80 1500.60 1152.00 1500.60 1023.00 1500.60 894.00 1500.60 765.00 1500.60 636.00 1500.60 498.00 1500.60 Pad No. 21 22 23 24 25 26 27 28 29 30 31 32 2/8 Name SEG4 SEG5 SEG6 SEG7 SEG8 SEG9 SEG10 SEG11 SEG12 SEG13 SEG14 SEG15 Coordinate X Y 85.50 199.50 234.00 88.50 381.00 88.50 519.00 88.50 657.00 88.50 795.00 88.50 933.00 88.50 1071.00 88.50 1209.00 88.50 1347.00 88.50 1485.00 88.50 1623.00 88.50 APLUS 13 14 15 16 17 18 19 20 OSCIN VDD CUP1 CUP2 COM1 SEG1 SEG2 SEG3 155.10 85.50 85.50 85.50 85.50 85.50 85.50 85.50 APU4006 1500.60 1132.50 994.50 865.50 736.50 607.50 478.50 349.50 33 34 35 36 37 38 39 SEG16 SEG17 SEG18 SEG19 SEG20 COM3 COM2 1761.00 1909.50 1909.50 1909.50 1909.50 1909.50 1909.50 88.50 219.60 375.60 527.10 678.60 830.10 981.60 *Note: The substrate must connect to GND. 3.0 PIN DESCRIPTION Name OSCIN OSCOUT M1 - 4 INT RESET Type I O I I I ALARM O VDD VDD1 VDD2 GND CUP1 - 2 O Description Typical 32.768kHz crystal is connected across OSCIN/OSCOUT for oscillation, R/C oscillation mode is also available. Input pins with pull-down Tr or "L-level hold" Tr. External interrupt request control input pin. System reset pin with pull-down resistance. Output only for outputting 4kHz/2kHz/1kHz modulation signal. Also can be used to output non-modulation signal. Power supply pin for logic unit inside LSI. When using Li version, a capacitor must be connected across GND and VDD to prevent logic unit from malfunctioning. For Ag-B mode positive power supply pin. For Li-B(EXTV) mode positive power supply pin. Negative power supply pin. Pins for connecting voltage step-up (step-down) capacitor. Output pins for LCD panel common plate. The following pins are used in each case. COM1 - 3 Static O SEG1 - 20 TESTA O * COM1 COM2 COM3 Alternating frequency O ¾ ¾ 32Hz* 1/2 duty O O ¾ 32Hz* * Frequency can be doubled, quadrupled with PLA. Output pins for LCD panel segments. * Also used as output ports with mask option. Test pin (for internal testing only). 3/8 1/3 duty O O O 43Hz* APLUS APU4006 4.0 ABSOLUTE MAXIMUM RATINGS at Ta = 0 to 70oC, GND = 0V Name Maximum Supply Voltage Maximum Input Voltage Maximum Output Voltage Maximum Operating Temperature Maximum Storage Temperature Symbol VDD1 VDD2 Vin1 Vout1 Vout2 Topg Range +1.3 to +5.5 +2.5 to +5.5 -0.3 to VDD1+0.3 -0.3 to VDD1+0.3 -0.3 to VDD2+0.3 0 to +70 Unit V V V V V oC Tstg -25 to +125 oC 5.0 ALLOWABLE OPERATING CONDITIONS at Ta = 0 to 70oC, GND = 0V Name Symb. Supply Voltage VDD1 VDD2 Supply Voltage VDD1 VDD2 Oscillator Start-Up Vss1 Supply Voltage Vss2 Input "H" Voltage Vih1 Input "L" Voltage Vil1 Input "H" Voltage Vih2 Input "L" Voltage Vil2 Input "H" Voltage Vih3 Input "L" Voltage Vil3 Input "H" Voltage Vih4 Input "L" Voltage Vil4 Fopg1 Fopg2 Operating Freq. Fopg3 Condition External RC Mode Crystal Mode Crystal Mode Ag Battery Mode Li Battery Mode OSCIN at Ext. RC & Ag Battery Mode OSCIN at Ext. RC & Li Battery Mode Ag Battery Mode Li Battery Mode External RC Mode Min. 1.5 3.5 1.2 2.4 1.2V 1.2V VDD1-0.3 -0.5 VDD2-0.6 -0.7 0.8 x VDD1 0 0.8 x VDD2 0 32 32 32 Max. 5.25 5.25 5.25 5.25 VDD1+0.3 0.2 VDD2+0.6 0.7 VDD1 0.2 x VDD1 VDD2 0.2 x VDD2 32 100 1000 Unit V V V V V V V V V V V V V V KHz KHz KHz 6.0 ELECTRICAL CHARACTERISTICS at #1 : VDD1 = 1.2V ( Ag ); #2 : VDD2 = 2.4V ( Li ); #3 : VDD2 = 4V (ExtV). 6.1 Input Resistance Name M-Port L-Level Hold Tr M-Port Pull-Down Tr INT Pull-Up Tr Symb. Rllh1 Rllh2 Rllh3 Rmsd1 Rmsd2 Rmsd3 Rintu1 Vi Vi Vi Vi Vi Vi Vi Condition = 0.2VDD1, #1 = 0.2VDD1, #2 = 0.2VDD1, #3 = VDD1, #1 = VDD2, #2 = VDD2, #3 = VDD1, #1 4/8 Min. 10 10 5 200 200 100 200 Typ. 40 40 20 700 500 250 700 Max. 100 100 50 2000 1000 500 2000 Unit Kohm Kohm Kohm Kohm Kohm Kohm Kohm APLUS INT Pull-Down Tr RES Pull-Down R APU4006 Rintu2 Rintu3 Rintd1 Rintd2 Rintd3 Rres1 Rres2 Rres3 Vi Vi Vi Vi Vi Vi Vi Vi 200 100 200 200 100 5 5 5 = VDD2, #2 = VDD2, #3 = GND, #1 = GND, #2 = GND, #3 = GND or VDD1, #1 = GND or VDD2, #2 = GND or VDD2, #3 500 250 700 500 250 20 20 20 1000 500 2000 1000 500 50 50 50 Kohm Kohm Kohm Kohm Kohm Kohm Kohm Kohm 6.2 DC Output Characteristics Name Output "H" Voltage Output "L" Voltage Symb. Voh1a Voh2a Voh3a Vol1a Vol2a Vol3a Condition Ioh = 200mA, #1 Ioh = 500mA, #2 Ioh = 1mA, #3 Iol = 400mA, #1 Iol = 1mA, #2 Iol = 2mA, #3 for Min. 0.8 1.5 2.5 0.2 0.3 0.5 Typ. 0.9 1.8 3 0.3 0.6 1 Max. 1.0 2.1 3.5 0.4 0.9 1.5 Unit V V V V V V Condition for Min. CMOS Output Mode Voh1c Ioh = -10uA, #1 0.8 Voh2c Ioh = -50uA, #2 1.5 Voh3c Ioh = -200uA, #3 2.5 SEGn Vol1c 0.2 Iol = 20uA, #1 Vol2c 0.3 Iol = 100uA, #2 Vol3c 0.5 Iol = 400uA, #3 Static Display Mode Voh1d Ioh = -1uA, #1 Voh2d Ioh = -1uA, #2 Voh3d Ioh = -1uA, #3 SEGn Vol1d 0.2 Iol = 1uA, #1 Vol2d 0.2 Iol = 1uA, #2 Vol3d 0.2 Iol = 1uA, #3 Voh1e Ioh = -10uA, #1 Voh2e Ioh = -10uA, #2 Voh3e Ioh = -10uA, #3 COMn Vol1e 0.2 Iol = 10uA, #1 Vol2e 0.2 Iol = 10uA, #2 Vol3e 0.2 Iol = 10uA, #3 Duplex (1/2 Bias, 1/2 Duty) Display Mode Voh12f Ioh = -1uA, #1, #2 Voh3f Ioh = -1uA, #3 SEGn Vol12f Iol = 1uA, #1, #2 0.2 Vol3f 0.2 Iol = 1uA, #3 Voh12g Ioh = -10uA, #1, #2 COMn Voh3g Ioh = -10uA, #3 Typ. Max. Unit 0.9 1.8 3 0.3 0.6 1 1.0 2.1 3.5 0.4 0.9 1.5 V V V V V V 1.0 2.2 3.8 V V V V V V V V V V V V Alarm 6.3 Segment Driver Output Characteristics Name Output "H" Voltage Output "L" Voltage Output "H" Voltage Output "L" Voltage Output "H" Voltage Output "L" Voltage Output "H" Voltage Output "L" Voltage Output "H" Voltage Symb. 5/8 1.0 2.2 3.8 2.2 3.8 2.2 3.8 V V V V V V APLUS Output "M" Voltage Output "L" Voltage Output "H" Voltage Output "L" Voltage Output "H" Voltage Output "M" Voltage Output "L" Voltage APU4006 Vom12g Iol/h= +/-10uA, #1, #2 Vom3g Iol/h= +/-10uA, #3 Vol12g Iol = 10uA, #1 Vol3g Iol = 10uA, #3 1/2 Bias, 1/3 Duty Display Mode Voh12h Ioh = -1uA, #1 ,#2 Voh3h Ioh = -1uA, #3 SEGn Vol12h Iol = 1uA, #1 ,#2 Vol3h Iol = 1uA, #3 Voh12i Ioh = -10uA, #1, #2 Voh3i Ioh = -10uA, #3 Vom12i Iol/h= +/-10uA, #1, #2 COMn Vom3i Iol/h= +/-10uA, #3 Vol12i Iol = 10uA, #1, #2 Vol3i Iol = 10uA, #3 1.0 1.8 0.2 0.2 1.4 2.2 0.2 0.2 1.0 1.8 0.2 0.2 2.2 3.8 1.4 2.2 V V V V V V V V V V V V V V 6.4 Instruction Table Note: Rx=28~37 not used Instruction Machine Code 000 0000 0000 0000 NOP 000 00YY YYXX XXXX LCT Y,X 000 1101 01XX XXXX MRA X 000 01YY YYXX XXXX LCB Y,X 000 10YY YYXX XXXX LCP Y,X 001 0000 00XX XXXX ADC X 001 0000 10XX XXXX ADC* X 001 0001 00XX XXXX SBC X 001 0001 10XX XXXX SBC* X 001 0010 00XX XXXX ADD X 001 0010 10XX XXXX ADD* X 001 0011 00XX XXXX SUB X 001 0011 10XX XXXX SUB* X 001 0100 00XX XXXX ADN X 001 0100 10XX XXXX ADN* X 001 0101 00XX XXXX AND X 001 0101 10XX XXXX AND* X 001 0110 00XX XXXX EOR X 001 0110 10XX XXXX EOR* X 001 0111 00XX XXXX OR X 001 0111 10XX XXXX OR* X 001 1000 0DDD DYYY ADCI Y,D 001 1000 1DDD DYYY ADCI* Y,D 001 1001 0DDD DYYY SBCI Y,D 001 1001 1DDD DYYY SBCI* Y,D 001 1010 0DDD DYYY ADDI Y,D 001 1010 1DDD DYYY ADDI* Y,D 001 1011 0DDD DYYY SUBI Y,D 001 1011 1DDD DYYY SUBI* Y,D 001 1100 0DDD DYYY ADNI Y,D 001 1100 1DDD DYYY ADNI* Y,D (Ly) CF (Ly) abcd,efgh (AC) (AC),(Rx) (AC) (AC),(Rx) (AC) (AC),(Rx) (AC) (AC),(Rx) (AC) (AC),(Rx) (AC) (AC),(Rx) (AC) (AC),(Rx) (AC) (AC),(Rx) (AC) (AC),(Ry) (AC) (AC),(Ry) (AC) (AC),(Ry) (AC) (AC),(Ry) (AC) (AC),(Ry) 6/8 Function No Operation <= (Rx) <= (Rx3) <= (Rx) <= (Rx),(AC) <= (Rx)+(AC)+(CF) <= (Rx)+(AC)+(CF) <= (Rx)+(AC)B+(CF) <= (Rx)+(AC)B+(CF) <= (Rx)+(AC) <= (Rx)+(AC) <= (Rx)+(AC)B+1 <= (Rx)+(AC)B+1 <= (Rx)+(AC) <= (Rx)+(AC) <= (Rx) AND (AC) <= (Rx) AND (AC) <= (Rx) EOR (AC) <= (Rx) EOR (AC) <= (Rx) OR (AC) <= (Rx) OR (AC) <= (Ry)+(D)+(CF) <= (Ry)+(D)+(CF) <= (Ry)+(D)B+(CF) <= (Ry)+(D)B+(CF) <= (Ry)+(D) <= (Ry)+(D) <= (Ry)+(D)B+1 <= (Ry)+(D)B+1 <= (Ry)+(D) <= (Ry)+(D) Remark Flag Y=000- No Use Y=000- No Use Y=000- No Use CF CF CF CF CF CF CF CF CF CF CF CF CF CF CF CF APLUS APU4006 Instruction ANDI Y,D ANDI* Y,D EORI Y,D EORI* Y,D ORI Y,D ORI* Y,D MRW Y,X MWR X,Y LDS X,D IPM X MAF X 001 001 001 001 001 001 011 011 010 010 011 DYYY DYYY DYYY DYYY DYYY DYYY XXXX XXXX XXXX XXXX XXXX (AC) (AC),(Ry) (AC) (AC),(Ry) (AC) (AC),(Ry) (AC),(Ry) (AC),(Rx) (AC),(Rx) (AC),(Rx) (AC),(Rx) MSB X 010 0010 00XX XXXX (AC),(Rx) <= STS2 MSC X 011 0000 00XX XXXX (AC),(Rx) <= STS3 STA SR0 X X 010 0010 10XX XXXX 010 0011 00XX XXXX SR1 X 010 0011 01XX XXXX SL0 X 010 0011 10XX XXXX SL1 X 010 0011 11XX XXXX LDA JB0 JB1 JB2 JB3 JNZ JNC JZ JC JMP CALL X X X X X X X X X X X 011 100 100 100 100 101 101 101 101 110 110 0111 00XX 01XX 10XX 11XX 00XX 01XX 10XX 11XX 00XX 01XX 10XX XXXX XXXX XXXX XXXX XXXX XXXX XXXX XXXX XXXX XXXX XXXX XXXX XXXX XXXX XXXX XXXX XXXX XXXX XXXX XXXX XXXX RTS SMS TMS SF X X X 110 111 111 111 1000 0000 0010 0100 0000 000X 00XX 0X00 0000 0000 XXXX 00XX (Rx) (ACn),(Rxn) (AC3),(Rx3) (ACn),(Rxn) (AC3),(Rx3) (ACn),(Rxn) (AC0),(Rx0) (ACn),(Rxn) (AC0),(Rx0) (AC) (PC) (PC) (PC) (PC) (PC) (PC) (PC) (PC) (PC) (STACK) (PC) (PC) SEF4 TIMER X6 X1 X0 X6 X1 X0 <= (AC) <= (Rxn+1) <= 0 <= (Rxn+1) <= 1 <= (Rxn-1) <= 0 <= (Rxn-1) <= 1 <= (Rx) <= X <= X <= X <= X <= X <= X <= X <= X <= X <= (PC)+1 <= X <= (STACK) <= X4 <= X : M-PORT Pull-Low : BCF Set : CF Set : M-PORT Low-L-H : BCF Reset : CF Reset RF X Machine Code 1101 1101 1110 1110 1111 1111 100Y 110Y 01DD 0000 0001 0DDD 1DDD 0DDD 1DDD 0DDD 1DDD YYXX YYXX DDXX 10XX 00XX 111 0110 0X00 00XX 7/8 Function <= (Ry) AND (D) <= (Ry) AND (D) <= (Ry) EOR (D) <= (Ry) EOR (D) <= (Ry) OR (D) <= (Ry) OR (D) <= (Rx) <= (Ry) <= (D) <= Port(M) <= STS1 Remark Flag TF2 : ZERO TF3 : CF B0 : BCF B1 : SCF1(MPT) B2 : SCF2(HRF) B0 : SCF4(INT) B1 : SCF5(TMR) B2 : PH15 B3 : SCF7(PDV) if if if if if if if if (AC0) = 1 (AC1) = 1 (AC2) = 1 (AC3) = 1 AC ¹ 0 (CF) = 0 AC = 0 (CF) = 1 M1-4 Enable HRF0 HRF1 BCF CF APLUS Instruction ALM X 111 0111 XXXX XXXX SIE X 111 1000 XXXX XXXX SIE* PLC X X 111 1010 0000 XXXX 111 110X XXXX XXXX HALT APU4006 Machine Code Function 0,1 1,0 1,1 DC 1K/2K 4K Hz X5 X4 X3 1 Hz 2 Hz 4 Hz X2 X1 X0 8 Hz 16 Hz 32 Hz : HEF1-3 is Enabled : IEF0-3 is Enabled : IEF0-3 is Enabled : Reset HRF0-3 : Reset PH11-15 X7,X6 Signal Xn = 1 Signal Xn = 1 Signal X5-7 X0-3 X0-3 X0-3 X8 111 1111 1111 1111 6.5 Symbol Description AC ACn Rx Rxn Ry D PC : Accumulator : Accumulator Bit N : Memory of Address X : Memory Bit N of Address X : Memory of Working Register Y : Immediate Data : Program Counter CF BCF IEFn HEFn SCFn Ly 8/8 : Carry Flag : Backup Flag : Interrupt Enable Flag : Halt Release Enable Flag HRFn : Halt Release Flag : Start Condition Flag : LCD Latch Remark Flag