Hello, friends, I hope you all are enjoying your life. In today’s tutorial, we will have a detailed look at Introduction to PIC16f877A. Due to less price and easy access, it is mostly used PIC microcontroller. You can buy this module from any electronic hope in the range of three to four dollars.
Most engineering students were asking about this important microcontroller so I am going to share a detailed post about this controller. In today’s post, we will have a detailed look at its working, pinout, operation, applications, and features. So let’s get started with Introduction to PIC16f877A.
Introduction to PIC16f877A
- The PIC16F877A belongs to the PICmicro group of the controller and now very commonly used in different engineering starting from basic to a professional level.
- The usage of flash memory allows us to write and remove any program according to our requirements and times.
- As this module has large space in memory unit generally eight-kilo words and three sixty bytes of RAM which allows to store and perform more than one function at a time.
- There are forty pinout exits in this module so it can be used in numerous electronic projects.
- Ther are 5 ports assembled on this module first is A, second is B, the third is C, fourth is D and fifth is E.
- There are 3 timers created on this module one is sixteen-bit and the other 2 is eight-bit.
- It is compatible with serial, parallel, and I2C communication protocols.
Features of PIC16F877A
- These are some important features of PIC16F877A which are denoted here.
- It comprises of the eight-bit central process unit.
- There are fort inputs of different category exits on this module.
- Its functioning voltage is in the range of two to 5,5 volts.
- There is thirty-three inputs and output pinouts exit on this mode.
- It has analog to digital converter which comprises of eight-channel of ten bits,
- There is two comparators that exist on this model.
- Like other controllers it does not has any digital to analog converter.
- The commonly used communication protocol in this module is UART, SPI, I2C MSSP.
- It has an exterior oscillator of twenty megahertz frequency.
- It does not consist of an inner oscillator.
- It has flash memory which is programmable and has a range of fourteen-kilo byte.
- The speed of its central processing unit is five MIPS.
- The space of its random access memory is three sixty-eight bytes.
Pinout of PIC16F877A
- There are forty common pinouts of this module which are discussed here with the details.
- Through this pinout, we program the controller normally PicKit is used to program it.
- It is zero pinouts of Port A and also analog.
- It is the first pinout of port A and first analog pinout.
- It is the second pinout of port A.
- It is the third pinout of port A.
- This is the fourth pinout of port A.
- It is zero pinouts of Port E.
- It is the first pinout of PORT E.
- It is the seventh pinout of Port E.
- At this pinout, the ground terminal is attached.
- At this pinout plus five volts are provided.
- At this pinout, exterior oscillator clock is given,
- This is the zero pinouts of port C.
- This is the first pinout of port C or also called pulse width modulation pinout.
- This is the second pinout of port C.
- This is the third pinout of port c.
- This is zero pinouts of Port D.
- This is the first pinout of port D.
- It is the second pinout of port D.
- It is the third pinout of port D.
- This is a serial data input pinout.
- This is serail data ouput pinnput.
- This transmitter pinout of this controller.
- This is the receiver pinout of the controller.
- This is the fourth pinout of port D.
- This is the fifth pinout of Port D.
- It is six pinouts of port D.
- This is the seventh pinout of port D.
- At this pinout positive five volts are given.
- It is ground pinout.
- This zero pinout of port B or exterior interrupt is given at this pinout.
- This is the second pinout of port B.
PIC16F877A Microcontroller Architecture
- The most common parts of PIC16F877A are central processing unit, input and output ports, memory unit analog to digital converter, timers, serial communication protocol, etc.
- In the below figure block diagram of the PIC16F877A structure is shown.
- There are different process occurs through the central processing unit of the controller such as arithmetic operation, logical operation. The CPU also makes pull like the arrangement between random access memory and other components of the controller.
- Arithmetic and logic operations are done by the ALU of CPU. Different types of instruction are stored in the memory unit of CPU.
- Through the memory unit, we can define the program size of the microcontroller. There is one important part of the controller which is the control unit which operates communication buses among the central processing unit and other parts of the controller.
- The operating speed of the controller is defined by the size of RAM. The ram comprises of registers that perform certain operations.
- The commonly used registers are of two types.
- The first one is GPR and the second is SFR.
- GPR performs general operations such as addition, subtraction, multiplication, etc. They can handle data up to eight bits.
- GPR does the read and writes function through the user. For their function, they required certain types of software.
- For complicated functions, SFR registers are used and they can handle the data up to the sixteen bits through these registers user can read and instruction and can not write.
- So the function performed by these registers are defined at the time of their creation.
- This memory unit is used for data storage, Through this memory, the size of our program is defined due to that it known as program memory,
- During the operation of the controller, the program already stored in the read-only memory is executed according to every communication cycle.
- The EEPROM or electronically erasable read-only memory is also the category of the memory unit. In this command stores when the program gets executed.
- This memory retains the data after power supplied to the controller is off.
- Flash memory of controller is a type of memory unit where we can read, write, and erase programs according to our requirements. Usually, ROM is used as a flash memory.
Input and outputs ports
- There are five ports are exits in these modules A, B , C, D, and E.
- The memory storage of Port A is sixteen-bit and Port E is three bit while remaining ports are of three bits.
- The pinouts of these ports can be used input or output according to arrangements of the TRIS register.
- With working as inputs and outputs these pinouts can also use as SPI, Interrupt, pulse width modulation.
- There are 2 types of buses are used in this module. The first one is the data bus and the second one address bus.
- For sending and receiving data, a data bus is used.
- The transfer of memory addresses from different devices to the central processing unit address bus is used.
Programming Software for PIC16F877A
- Numerous types of software are used for programming of this controller some users used assembly language to program this controller.
- With that, some other software is used for the program the PIC.
- IDE:IPE:Compiler: XC8
Applications of PIC16F877A
- These are some applications of PIC16F877A.
- It used in numerous DIY projects.
- To learn different types of controller it is the best option.
- For such projects which needed numerous input and output interfaces, this controller is preferred.
- In such projects where Arduino is required where you can use this controller.
So that is a detailed post about PIC16F877A if you have any further query ask in comments, Thanks for reading. Have a good day,