Datasheet BA45F5420 (Holtek) - 17

HerstellerHoltek
Beschreibung9V High Voltage Smoke Detector Flash MCU
Seiten / Seite112 / 17 — BA45F5420. 9V High Voltage Smoke Detector Flash MCU. System Clocking and …
Dateiformat / GrößePDF / 2.1 Mb
DokumentenspracheEnglisch

BA45F5420. 9V High Voltage Smoke Detector Flash MCU. System Clocking and Pipelining. Instruction Fetching. Program Counter

BA45F5420 9V High Voltage Smoke Detector Flash MCU System Clocking and Pipelining Instruction Fetching Program Counter

Modelllinie für dieses Datenblatt

Textversion des Dokuments

BA45F5420 BA45F5420 9V High Voltage Smoke Detector Flash MCU 9V High Voltage Smoke Detector Flash MCU
branch. The requirement for this extra cycle should be taken into account by programmers in timing sensitive applications. fSYS (System Clock) Phase Clock T1 Phase Clock T2 Phase Clock T3 Phase Clock T4 Program Counter PC PC+1 PC+2 Fetch Inst. (PC) Pipelining Execute Inst. (PC-1) Fetch Inst. (PC+1) Execute Inst. (PC) Fetch Inst. (PC+2) Execute Inst. (PC+1)
System Clocking and Pipelining
Fetch Inst. 1 1 MOV A,[12H] Execute Inst. 1 2 CALL DELAY Fetch Inst. 2 Execute Inst. 2 3 CPL [12H] Fetch Inst. 3 Flush Pipeline 4 : Fetch Inst. 6 Execute Inst. 6 5 : Fetch Inst. 7 6 DELAY: NOP
Instruction Fetching Program Counter
During program execution, the Program Counter is used to keep track of the address of the next instruction to be executed. It is automatically incremented by one each time an instruction is executed except for instructions, such as “JMP” or “CALL” that demands a jump to a non- consecutive Program Memory address. Only the lower 8 bits, known as the Program Counter Low Register, are directly addressable by the application program. When executing instructions requiring jumps to non-consecutive addresses such as a jump instruction, a subroutine call, interrupt or reset, etc., the microcontroller manages program control by loading the required address into the Program Counter. For conditional skip instructions, once the condition has been met, the next instruction, which has already been fetched during the present instruction execution, is discarded and a dummy cycle takes its place while the correct instruction is obtained.
Program Counter Program Counter High Byte PCL Register
PC9~PC8 PCL7~PCL0
Program Counter
The lower byte of the Program Counter, known as the Program Counter Low register or PCL, is available for program control and is a readable and writeable register. By transferring data directly into this register, a short program jump can be executed directly. However, as only this low byte is available for manipulation, the jumps are limited to the present page of memory, that is 256 locations. When such program jumps are executed it should also be noted that a dummy cycle will be inserted. Manipulating the PCL register may cause program branching, so an extra cycle is needed to pre-fetch. Rev. 1.00 16 June 15, 2020 Rev. 1.00 17 June 15, 2020 Document Outline Features CPU Features Peripheral Features General Description Block Diagram Pin Assignment Pin Description Absolute Maximum Ratings D.C. Electrical Characteristics Operating Voltage Characteristics Standby Current Characteristics Operating Current Characteristics A.C. Electrical Characteristics High Speed Internal Oscillator – HIRC – Frequency Accuracy Low Speed Internal Oscillator Characteristics – LIRC System Start Up Time Characteristics Input/Output Characteristics Memory Characteristics Internal Reference Voltage Electrical Characteristics LVR Electrical Characteristics Sink Current Generator Electrical Characteristics Operational Amplifier Electrical Characteristics A/D Converter Electrical Characteristics LDO Electrical Characteristics Piezoelectric Horn Driver Characteristics Power-on Reset Characteristics System Architecture Clocking and Pipelining Program Counter Stack Arithmetic and Logic Unit – ALU Flash Program Memory Structure Special Vectors Look-up Table Table Program Example In Circuit Programming – ICP On-Chip Debug Support – OCDS RAM Data Memory Structure General Purpose Data Memory Special Purpose Data Memory Special Function Register Description Indirect Addressing Register – IAR0, IAR1 Memory Pointers – MP0, MP1 Accumulator – ACC Program Counter Low Register – PCL Look-up Table Registers – TBLP, TBLH Status Register – STATUS Emulated EEPROM Data Memory Emulated EEPROM Data Memory Structure Emulated EEPROM Registers Erasing the Emulated EEPROM Writing Data to the Emulated EEPROM Reading Data from the Emulated EEPROM Programming Considerations Oscillators Oscillator Overview System Clock Configurations Internal RC Oscillator – HIRC Internal 32kHz Oscillator – LIRC Operating Modes and System Clocks System Clocks System Operation Modes Control Registers Operating Mode Switching Standby Current Considerations Wake-up Watchdog Timer Watchdog Timer Clock Source Watchdog Timer Control Register Watchdog Timer Operation Reset and Initialisation Reset Functions Reset Initial Conditions Input/Output Ports Pull-high Resistors Port A Wake-up I/O Port Control Registers Sink Current Generator Pin-shared Functions I/O Pin Structures Programming Considerations Timer Modules – TM Introduction TM Operation TM Clock Source TM Interrupts TM External Pins Programming Considerations Periodic Type TM – PTM Periodic Type TM Operation Periodic Type TM Register Description Periodic Type TM Operating Modes Smoke Detector AFE Smoke Detector AFE Registers Operational Amplifier Operation Piezoel Horn Driver Analog to Digital Converter A/D Overview Registers Descriptions A/D Converter Reference Voltage A/D Converter Input Signals A/D Converter Operation Conversion Rate and Timing Diagram Summary of A/D Conversion Steps Programming Considerations A/D Transfer Function A/D Programming Examples Interrupts Interrupt Registers Interrupt Operation External Interrupt Timer Module Interrupts A/D Converter Interrupt Time Base Interrupts Interrupt Wake-up Function Programming Considerations Application Circuits External-driving Buzzer Application Circuit Self-driving Buzzer Application Circuit Instruction Set Introduction Instruction Timing Moving and Transferring Data Arithmetic Operations Logical and Rotate Operation Branches and Control Transfer Bit Operations Table Read Operations Other Operations Instruction Set Summary Table Conventions Instruction Definition Package Information 16-pin NSOP (150mil) Outline Dimensions 20-pin SOP (300mil) Outline Dimensions