HT48R066B Holtek Semiconductor, HT48R066B Datasheet

no-image

HT48R066B

Manufacturer Part Number
HT48R066B
Description
(HT48R063B - HT48R066B) Enhanced I/O Type 8-Bit OTP MCU
Manufacturer
Holtek Semiconductor
Datasheet
www.DataSheet.co.kr
Enhanced I/O Type 8-Bit OTP MCU
HT48R063B/HT48R064B
HT48R065B/HT48R066B
Revision: 1.00
Date: April 7, 2011
Datasheet pdf - http://www.DataSheet4U.net/

Related parts for HT48R066B

HT48R066B Summary of contents

Page 1

... Enhanced I/O Type 8-Bit OTP MCU HT48R063B/HT48R064B HT48R065B/HT48R066B Revision: 1.00 Date: April 7, 2011 Datasheet pdf - http://www.DataSheet4U.net/ ...

Page 2

... Features ...............................................................................................1 CPU Features ........................................................................................................1 Peripheral Features ................................................................................................1 Technical Document ...........................................................................1 Selection Table ....................................................................................2 Block Diagram .....................................................................................2 Pin Assignment ...................................................................................3 Pin Description ....................................................................................4 HT48R063B ...........................................................................................................4 HT48R064B ...........................................................................................................5 HT48R065B, HT48R066B ......................................................................................6 Absolute Maximum Ratings ...............................................................7 D.C. Characteristics ............................................................................7 A.C. Characteristics ............................................................................8 Power-on Reset Characteristics ........................................................9 System Architecture .........................................................................10 Clocking and Pipelining ........................................................................................10 Program Counter ..................................................................................................11 Stack ....................................................................................................................11 Arithmetic and Logic Unit Program Memory...............................................................................12 Structure ...

Page 3

Special Function Registers ..............................................................15 Indirect Addressing Registers Memory Pointers Accumulator ACC ..............................................................................................17 Program Counter Low Register Status Register Input/Output Ports and Control Registers .............................................................18 System Control Registers Wake-up Function Register Pull-high Registers Software COM Register Oscillator............................................................................................20 System Oscillator Overview..................................................................................20 ...

Page 4

Timer/Event Counters .......................................................................32 Configuring the Timer/Event Counter Input Clock Source .....................................32 Timer Registers Timer Control Registers Timer Mode ..........................................................................................................35 Event Counter Mode.............................................................................................35 Pulse Width Capture Mode...................................................................................36 Prescaler ..............................................................................................................36 PFD Function .......................................................................................................37 I/O Interfacing.......................................................................................................37 Programming Considerations ...............................................................................38 Timer Program Example.......................................................................................38 ...

Page 5

Package Information .........................................................................60 16-pin DIP (300mil) Outline Dimensions ...............................................................60 16-pin NSOP (150mil) Outline Dimensions ...........................................................62 20-pin DIP (300mil) Outline Dimensions ...............................................................63 20-pin SOP (300mil) Outline Dimensions..............................................................65 20-pin SSOP (150mil) Outline Dimensions ...........................................................66 24-pin SKDIP (300mil) Outline Dimensions ..........................................................67 24-pin ...

Page 6

Technical Document Application Note HA0075E MCU Reset and Oscillator Circuits Application Note Features CPU Features Operating voltage 4MHz: 2.2V~5.5V SYS f = 8MHz: 3.0V~5.5V SYS f = 12MHz: 4.5V~5.5V SYS Up to 0.33 s instruction cycle with ...

Page 7

... Selection Table Program Part No. Memory HT48R063B 1K 14 HT48R064B 1K 14 HT48R065B 2K 15 HT48R066B 4K 15 Block Diagram The following block diagram illustrates the main functional blocks. Rev. 1.00 Data Time HIRC RTC I/O Timer Memory Base (MHz) (LXT 4/8/ 8-bit 8-bit 1 ...

Page 8

Pin Assignment Note: Bracketed pin names indicate non-default pinout remapping locations. Rev. 1.00 HT48R063B/064B/065B/066B 8 April 7, 2011 Datasheet pdf - http://www.DataSheet4U.net/ ...

Page 9

Pin Description HT48R063B Pin Name Function PA0 PA0/PFD PFD PA1 PA1/PFD PFD PA2 PA2/TC0 TC0 PA3 PA3/INT INT PA4 PA4 PA5 PA5/OSC2 OSC2 PA6 PA6/OSC1 OSC1 PA7 PA7/RES RES PB0~PB5 PBn VDD VDD VSS VSS Note: I/T: Input type; ...

Page 10

HT48R064B Pin Name Function PA0 PA0/PFD PFD PA1 PA1/PFD PFD PA2 PA2/TC0 TC0 PA3 PA3/INT INT PA4 PA4 PA5 PA5/OSC2 OSC2 PA6 PA6/OSC1 OSC1 PA7 PA7/RES RES PB0 PB0/SCOM0 SCOM0 PB1 PB1/SCOM1 SCOM1 PB2 PB2/SCOM2 SCOM2 PB3 PB3/SCOM3 SCOM3 ...

Page 11

... HT48R065B, HT48R066B Pin Name Function PA0 PA0/PFD PFD PA1 PA1/PFD PFD PA2 PA2/TC0 TC0 PA3 PA3/INT INT PA4 PA4/TC1 TC1 PA5 PA5/OSC2 OSC2 PA6 PA6/OSC1 OSC1 PA7 PA7/RES RES PB0 PB0/SCOM0 SCOM0 PB1 PB1/SCOM1 SCOM1 PB2 PB2/SCOM2 SCOM2 PB3 PB3/SCOM3 ...

Page 12

Absolute Maximum Ratings Supply Voltage ...........................V Input Voltage..............................V I Total ..............................................................100mA OL Total Power Dissipation .....................................500mW Note: These are stress ratings only. Stresses exceeding the range specified under Absolute Maximum Ratings may cause substantial damage to the device. Functional ...

Page 13

Symbol I/O Port Sink Current I OL1 (PA, PB, PC) I I/O Port Source Current OH I PA7 Sink Current OL2 R Pull-high Resistance PH I SCOM Operating Current SCOM Voltage for LCD COM SCOM DD ...

Page 14

Symbol f System Clock (ERC) ERC f System Clock (LXT) LXT Timer Input Frequency f TIMER (TCn) f LIRC Oscillator LIRC t External Reset Low Pulse Width RES t System Start-up time Period SST t Interrupt Pulse Width INT ...

Page 15

System Architecture A key factor in the high-performance features of the Holtek range of microcontrollers is attributed to the inter- nal system architecture. The range of devices take ad- vantage of the usual features found within RISC microcontrollers providing ...

Page 16

... After a device reset, the Stack Pointer will point to the top of the stack. HT48R063B HT48R064B HT48R065B HT48R066B If the stack is full and an enabled interrupt takes place, Program Counter the interrupt request flag will be recorded but the ac- knowledge signal will be inhibited. When the Stack ...

Page 17

... Table data, which can be setup in any location within the Program Memory, is addressed by separate table pointer registers. Device HT48R063B HT48R064B HT48R065B HT48R066B Rev. 1.00 HT48R063B/064B/065B/066B Special Vectors Within the Program Memory, certain locations are re- served for special usage such as reset and interrupts. Reset Vector This vector is reserved for use by the device reset for program initialisation ...

Page 18

... Table Pointer TBLP bits For the HT48R063B/HT48R064B, the Table address location is 10 bits, i.e. from b9~b0. For the HT48R065B, the Table address location is 11 bits, i.e. from b10~b0. For the HT48R066B, the Table address location is 12 bits, i.e. from b11~b0 Rev. 1.00 Table Program Example ...

Page 19

... The second area of Data Memory is reserved for general purpose use. All locations within this area are read and write accessible under program control. Device HT48R063B HT48R064B HT48R065B HT48R066B Rev. 1.00 ; temporary register #1 ; temporary register #2 ; initialise table pointer - note that this address ; is referenced ; to the last page or present page ...

Page 20

Data Memory Structure Note: Most of the Data Memory bits can be directly manipulated using the SET [m].i and CLR [m].i with the exception of a few dedicated bits. The Data Memory can also be accessed through the memory ...

Page 21

Rev. 1.00 HT48R063B/064B/065B/066B Special Purpose Data Memory 21 April 7, 2011 Datasheet pdf - http://www.DataSheet4U.net/ ...

Page 22

Indirect Addressing Program Example data .section adres1 db ? adres2 db ? adres3 db ? adres4 db ? block code .section at 0 code org 00h start: mov a,04h mov block,a mov a,offset adres1 mov mp0,a loop: clr IAR0 ...

Page 23

STATUS Register Bit Name R/W POR Bit 7, 6 Unimplemented, read as 0 Bit 5 TO: Watchdog Time-Out flag 0: After ...

Page 24

... HT48R066B Bit Name R/W POR Bit Unimplemented, read as 0 Bit 6 PFDCS: PFD clock source 0: timer0 1: timer1 Bit 3,2 PFDEN1, PFDEN0: PFD/PFD enable/disable 00: both disables 01: Reserved 10: PFD enable 11: PFD and PFD both enabled when PFD or PFD is disabled, the related pin will have a normal I/O function. ...

Page 25

Wake-up Function Register - PAWK When the microcontroller enters the Idle/Sleep Mode, various methods exist to wake the device up and con- tinue with normal operation. One method is to allow a falling edge on the I/O pins to ...

Page 26

Here only the OSC1 pin is used, which is shared with I/O pin PA6, leaving pin PA5 free for use as a normal I/O pin. External RC Oscillator - ERC Internal ...

Page 27

Internal Low Speed Oscillator - LIRC The LIRC is a fully self-contained free running on-chip RC oscillator with a typical frequency of 13kHz at 5V re- quiring no external components. When the device en- ters the Idle/Sleep Mode, the ...

Page 28

Standby Current Considerations As the main reason for entering the Idle/Sleep Mode is to keep the current consumption of the MCU to as low a value as possible, perhaps only in the order of several micro-amps, there are other ...

Page 29

Configuration Option Disable Disable Enable Watchdog Timer On/Off Control The Watchdog Timer will be disabled if bits WDTEN3~WDTEN0 in the CTRL1 register are written with the binary value 1010B and WDT configuration op- tion is disable. This will be ...

Page 30

Reset and Initialisation A reset function is a fundamental part of any microcontroller ensuring that the device can be set to some predetermined condition irrespective of outside parameters. The most important reset condition is after power is first applied ...

Page 31

RES Pin Reset This type of reset occurs when the microcontroller is already running and the RES pin is forcefully pulled low by external hardware such as an external switch. In this case as in the case of other ...

Page 32

The different kinds of resets all affect the internal registers of the microcontroller in different ways. To ensure reliable continuation of normal program execution after a reset occurs important to know what condition the microcontroller is in ...

Page 33

Input/Output Ports Holtek microcontrollers offer considerable flexibility on their I/O ports. Most pins can have either an input or out- put designation under user program control. Addi- tionally, as there are pull-high resistors and wake-up software configurations, the user ...

Page 34

... PBPU 00H PCC FFH PCPU 00H PAWKn: PA wake-up function enable 0: disable 1: enable PACn/PBCn/PCCn: I/O type selection 0: output 1: input PAPUn/PBPUn/PCPUn: Pull-high function enable 0: disable 1: enable HT48R065B/HT48R066B Register POR Name PAWK 00H PAC FFH PAPU 00H PBC 3FH PBPU 00H PCC FFH PCPU ...

Page 35

I/O Port Control Registers Each Port has its own control register, known as PAC, PBC, PCC, PDC, PEC, PFC which controls the in- put/output configuration. With this control register, each I/O pin with or without pull-high resistors can be ...

Page 36

Rev. 1.00 HT48R063B/064B/065B/066B Generic Input/Output Ports PA7 NMOS Input/Output Port PB Input/Output Port 36 April 7, 2011 Datasheet pdf - http://www.DataSheet4U.net/ ...

Page 37

Timer/Event Counters The provision of timers form an important part of any microcontroller, giving the designer a means of carrying out time related functions. The devices contain from one to three count-up timer of 8-bit capacity. As the timers ...

Page 38

Rev. 1.00 HT48R063B/064B/065B/066B Clock Structure for Timer/PWM/Time Base 8-bit Timer/Event Counter 0 Structure 8-bit Timer/Event Counter 1 Structure 38 April 7, 2011 Datasheet pdf - http://www.DataSheet4U.net/ ...

Page 39

TMR0C Register Bit Name T0M1 R/W R/W POR Bit 7,6 T0M1, T0M0: Timer0 operation mode selection 00: no mode available 01: event counter mode 10: timer mode 11: pulse width capture mode Bit 5 T0S: timer clock source 0: ...

Page 40

Timer Mode In this mode, the Timer/Event Counter can be utilised to measure fixed time intervals, providing an internal inter- rupt signal each time the Timer/Event Counter over- flows. To operate in this mode, the Operating Mode Select bit ...

Page 41

Pulse Width Capture Mode In this mode, the Timer/Event Counter can be utilised to measure the width of external pulses applied to the ex- ternal timer pin. To operate in this mode, the Operating Mode Select bit pair, TnM1/TnM0, ...

Page 42

PFD Function The Programmable Frequency Divider provides a means of producing a variable frequency output suitable for applications, such as piezo-buzzer driving or other interfaces requiring a precise frequency generator. Depending upon which device is used, there is either ...

Page 43

Programming Considerations When configured to run in the timer mode, the internal system clock is used as the timer clock source and is therefore synchronised with the overall operation of the microcontroller. In this mode when the appropriate timer ...

Page 44

PFD Programming Example org 04h org 08h jmp tmr0int : : org 20h : : ;internal Timer 0 interrupt routine tmr0int Timer 0 main program placed here : : begin: ;setup Timer 0 registers mov a,09bh mov ...

Page 45

Interrupts Interrupts are an important part of any microcontroller system. When an external event or an internal function such as a Timer/Event Counter or Time Base requires microcontroller attention, their corresponding interrupt will enforce a temporary suspension of the ...

Page 46

... INTF, will be automatically reset and the EMI bit will be automatically cleared to disable other 1 04H interrupts. Note that any pull-high resistor connections 2 08H on this pin will remain valid even if the pin is used 0CH external interrupt input. HT48R066B Priority Vector 1 04H 2 08H 3 0CH 4 10H 46 ...

Page 47

... Bit 2 T0E: Timer/Event Counter 0 interrupt enable 0: disable 1: enable Bit 1 INTE: external interrupt enable 0: disable 1: enable Bit 0 EMI: Master interrupt global enable 0: disable 1: enable HT48R066B INTC0 Register Bit 7 Name R/W POR Bit 7 unimplemented, read as 0 Bit 6 T1F: Timer/Event Counter 1 interrupt request flag 0: inactive ...

Page 48

INTC1 Register Bit Name R/W POR Bit 7~5,3~1 unimplemented, read as 0 Bit 4 TBF: Time Base event interrupt request flag 0: inactive 1: active Bit 0 TBE: Time base event interrupt enable 0: disable 1: enable Bit 7 ...

Page 49

Timer/Event Counter Interrupt For a Timer/Event Counter interrupt to occur, the global interrupt enable bit, EMI, and the corresponding timer interrupt enable bit, TnE, must first be set. An actual Timer/Event Counter interrupt will take place when the Timer/Event ...

Page 50

LCD Bias Control The LCD COM driver enables a range of selections to be provided to suit the requirement of the LCD panel which is be- ing used. The bias resistor choice is implemented using the ISEL1 and ISEL0 ...

Page 51

Configuration Options Configuration options refer to certain options within the MCU that are programmed into the OTP Program Memory de- vice during the programming process. During the development process, these options are selected using the HT-IDE software development tools. ...

Page 52

Instruction Set Introduction ful ope rati microcontroller is its instruction set, which is a set of pro- gram ...

Page 53

Bit Operations The ability to provide single bit operations on Data Mem- ory is an extremely flexible feature of all Holtek microcontrollers. This feature is especially useful for output port bit programming where individual bits or port pins can ...

Page 54

Mnemonic Rotate RRA [m] Rotate Data Memory right with result in ACC RR [m] Rotate Data Memory right RRCA [m] Rotate Data Memory right through Carry with result in ACC RRC [m] Rotate Data Memory right through Carry RLA ...

Page 55

Instruction Definition ADC A,[m] Description Operation Affected flag(s) ADCM A,[m] Description Operation Affected flag(s) ADD A,[m] Description Operation Affected flag(s) ADD A,x Description Operation Affected flag(s) ADDM A,[m] Description Operation Affected flag(s) AND A,[m] Description Operation Affected flag(s) AND ...

Page 56

CALL addr Description Operation Affected flag(s) CLR [m] Description Operation Affected flag(s) CLR [m].i Description Operation Affected flag(s) CLR WDT Description Operation Affected flag(s) CLR WDT1 Description Operation Affected flag(s) CLR WDT2 Description Operation Affected flag(s) Rev. 1.00 HT48R063B/064B/065B/066B ...

Page 57

CPL [m] Description Operation Affected flag(s) CPLA [m] Description Operation Affected flag(s) DAA [m] Description Operation Affected flag(s) DEC [m] Description Operation Affected flag(s) DECA [m] Description Operation Affected flag(s) HALT Description Operation Affected flag(s) Rev. 1.00 HT48R063B/064B/065B/066B Complement ...

Page 58

INC [m] Description Operation Affected flag(s) INCA [m] Description Operation Affected flag(s) JMP addr Description Operation Affected flag(s) MOV A,[m] Description Operation Affected flag(s) MOV A,x Description Operation Affected flag(s) MOV [m],A Description Operation Affected flag(s) NOP Description Operation ...

Page 59

OR A,x Description Operation Affected flag(s) ORM A,[m] Description Operation Affected flag(s) RET Description Operation Affected flag(s) RET A,x Description Operation Affected flag(s) RETI Description Operation Affected flag(s) RL [m] Description Operation Affected flag(s) RLA [m] Description Operation Affected ...

Page 60

RLC [m] Description Operation Affected flag(s) RLCA [m] Description Operation Affected flag(s) RR [m] Description Operation Affected flag(s) RRA [m] Description Operation Affected flag(s) RRC [m] Description Operation Affected flag(s) RRCA [m] Description Operation Affected flag(s) Rev. 1.00 HT48R063B/064B/065B/066B ...

Page 61

SBC A,[m] Description Operation Affected flag(s) SBCM A,[m] Description Operation Affected flag(s) SDZ [m] Description Operation Affected flag(s) SDZA [m] Description Operation Affected flag(s) SET [m] Description Operation Affected flag(s) SET [m].i Description Operation Affected flag(s) Rev. 1.00 HT48R063B/064B/065B/066B ...

Page 62

SIZ [m] Description Operation Affected flag(s) SIZA [m] Description Operation Affected flag(s) SNZ [m].i Description Operation Affected flag(s) SUB A,[m] Description Operation Affected flag(s) SUBM A,[m] Description Operation Affected flag(s) SUB A,x Description Operation Affected flag(s) Rev. 1.00 HT48R063B/064B/065B/066B ...

Page 63

SWAP [m] Description Operation Affected flag(s) SWAPA [m] Description Operation Affected flag(s) SZ [m] Description Operation Affected flag(s) SZA [m] Description Operation Affected flag(s) SZ [m].i Description Operation Affected flag(s) TABRDC [m] Description Operation Affected flag(s) TABRDL [m] Description ...

Page 64

XOR A,[m] Description Operation Affected flag(s) XORM A,[m] Description Operation Affected flag(s) XOR A,x Description Operation Affected flag(s) Rev. 1.00 HT48R063B/064B/065B/066B Logical XOR Data Memory to ACC Data in the Accumulator and the specified Data Memory perform a bitwise ...

Page 65

Package Information 16-pin DIP (300mil) Outline Dimensions Fig1. Full Lead Packages MS-001d (see fig1) Symbol Symbol Rev. 1.00 HT48R063B/064B/065B/066B Fig2. 1/2 ...

Page 66

MS-001d (see fig2) Symbol Symbol MO-095a (see fig2) Symbol Symbol A B ...

Page 67

NSOP (150mil) Outline Dimensions Symbol Symbol Rev. 1.00 HT48R063B/064B/065B/066B Dimensions in inch Min. Nom. 0.228 0.150 0.012 0.386 0.050 0.004 ...

Page 68

DIP (300mil) Outline Dimensions Fig1. Full Lead Packages MS-001d (see fig1) Symbol Symbol Rev. 1.00 HT48R063B/064B/065B/066B Fig2. 1/2 Lead Packages ...

Page 69

MO-095a (see fig2) Symbol Symbol Rev. 1.00 HT48R063B/064B/065B/066B Dimensions in inch Min. Nom. 0.945 0.275 0.120 0.110 0.014 0.045 0.100 0.300 ...

Page 70

SOP (300mil) Outline Dimensions MS-013 Symbol Symbol Rev. 1.00 HT48R063B/064B/065B/066B Dimensions in inch Min. Nom. 0.393 0.256 0.012 0.496 0.050 ...

Page 71

SSOP (150mil) Outline Dimensions Symbol Symbol Rev. 1.00 HT48R063B/064B/065B/066B Dimensions in inch Min. Nom. 0.228 0.150 0.008 0.335 0.049 0.025 ...

Page 72

SKDIP (300mil) Outline Dimensions Fig1. Full Lead Packages MS-001d (see fig1) Symbol Symbol Rev. 1.00 HT48R063B/064B/065B/066B Fig2. 1/2 Lead Packages ...

Page 73

MS-001d (see fig2) Symbol Symbol MO-095a (see fig2) Symbol Symbol A B ...

Page 74

SOP (300mil) Outline Dimensions MS-013MS-013 Symbol Symbol Rev. 1.00 HT48R063B/064B/065B/066B Dimensions in inch Min. Nom. 0.393 0.256 0.012 0.598 0.050 ...

Page 75

SSOP (150mil) Outline Dimensions Symbol Symbol Rev. 1.00 HT48R063B/064B/065B/066B Dimensions in inch Min. Nom. 0.228 0.150 0.008 0.335 0.054 0.025 ...

Page 76

SKDIP (300mil) Outline Dimensions Symbol Symbol Rev. 1.00 HT48R063B/064B/065B/066B Dimensions in inch Min. Nom. 1.375 0.278 0.125 0.125 0.016 0.050 ...

Page 77

SOP (300mil) Outline Dimensions MS-013 Symbol Symbol Rev. 1.00 HT48R063B/064B/065B/066B Dimensions in inch Min. Nom. 0.393 0.256 0.012 0.697 0.050 ...

Page 78

SSOP (150mil) Outline Dimensions Symbol Symbol Rev. 1.00 HT48R063B/064B/065B/066B Dimensions in inch Min. Nom. 0.228 0.150 0.008 0.386 0.054 0.025 ...

Page 79

Product Tape and Reel Specifications Reel Dimensions SOP 16N (150mil) Symbol A Reel Outer Diameter B Reel Inner Diameter C Spindle Hole Diameter D Key Slit Width T1 Space Between Flange T2 Reel Thickness SOP 20W, SOP 24W, SOP ...

Page 80

Carrier Tape Dimensions SOP 16N (150mil) Symbol W Carrier Tape Width P Cavity Pitch E Perforation Position F Cavity to Perforation (Width Direction) D Perforation Diameter D1 Cavity Hole Diameter P0 Perforation Pitch P1 Cavity to Perforation (Length Direction) ...

Page 81

SOP 24W Symbol W Carrier Tape Width P Cavity Pitch E Perforation Position F Cavity to Perforation (Width Direction) D Perforation Diameter D1 Cavity Hole Diameter P0 Perforation Pitch P1 Cavity to Perforation (Length Direction) A0 Cavity Length B0 ...

Page 82

SSOP 20S (150mil) Symbol W Carrier Tape Width P Cavity Pitch E Perforation Position F Cavity to Perforation (Width Direction) D Perforation Diameter D1 Cavity Hole Diameter P0 Perforation Pitch P1 Cavity to Perforation (Length Direction) A0 Cavity Length ...

Page 83

SSOP 28S (150mil) Symbol W Carrier Tape Width P Cavity Pitch E Perforation Position F Cavity to Perforation (Width Direction) D Perforation Diameter D1 Cavity Hole Diameter P0 Perforation Pitch P1 Cavity to Perforation (Length Direction) A0 Cavity Length ...

Page 84

... Holtek Semiconductor Inc. (Shenzhen Sales Office) 5F, Unit A, Productivity Building, No.5 Gaoxin M 2nd Road, Nanshan District, Shenzhen, China 518057 Tel: 86-755-8616-9908, 86-755-8616-9308 Fax: 86-755-8616-9722 Holtek Semiconductor (USA), Inc. (North America Sales Office) 46729 Fremont Blvd., Fremont, CA 94538, USA Tel: 1-510-252-9880 Fax: 1-510-252-9885 http://www.holtek.com Copyright 2011 by HOLTEK SEMICONDUCTOR INC ...

Related keywords