Analysis of the internal structure and working principle of PIC16C5X single-chip microcomputer

PIC16C5X integrates an 8-bit arithmetic logic unit ALU and working register (W) on a chip; 12-bit program memory (ROM) of 384~2K; 32~80 8-bit data registers (RAM); 12~20 I / O port; 8-bit counter and prescaler; clock, reset, and watch counter, etc.

PIC16C5X integrates an 8-bit arithmetic logic unit ALU and working register (W) on a chip; 12-bit program memory (ROM) of 384~2K; 32~80 8-bit data registers (RAM); 12~20 I / O port; 8-bit counter and prescaler; clock, reset, and watch counter, etc. The internal structure is shown in Figure 1.2:

Analysis of the internal structure and working principle of PIC16C5X single-chip microcomputer

As you can see from the figure, PIC16C5X has a feature, that is, the data memory RAM is used as a register for addressing to facilitate programming. The register group is divided into two parts according to function, namely special register group and general register group. The special register group includes real-time clock counter RTCC, program counter PC, status register Status, I/O port register and bank selection register FSR. We will discuss these registers in detail later.

The PIC bus structure adopts the Harvard (Harvard) structure in which the data line (8 bits) and the instruction line (12 bits) are separated independently. In this way, the instruction speed of the microcontroller can be improved. When an instruction is executed in the ALU, the next instruction has been fetched and placed in the instruction register for execution. The arithmetic logic unit ALU and the working register (W) are responsible for arithmetic and logic operation tasks.

PIC16C5X provides a two-level stack (Stack), so subroutine calls only have two levels. Be sure to pay attention to this when using, otherwise the program will run out of control.

The Links:   SKM800GA126D LC260W01-A5KA

Author: Yoyokuo