Raspberry Pi 4 pinout [BOARD vs BCM]
Till now we’ve discussed how we can set up our Raspberry Pi board. Now in this lesson, I will explain different pinouts of the raspberry pi boards. As raspberry pi has 40 general purpose input and output (GPIO) pins which make it famous among the developers worldwide. So it’s very important to know what’s the order of the pins and which pin can do what type of tasks. And in this lesson, you will come to know all about these GPIO pins.
The 40 GPIO pins make the raspberry pi the first choice of embedded or IOT developers as it has more GPIOs than any Arduino board which allow you to connect more Peripheral devices with it. But at the same time, it is a little bit confusing to determine the exact order of them. So their developers come up with 2 different numbering system for the pins of the raspberry pi. They are:
Let’s see what are the differences and how they work
The main difference is the numbering policies of the GPIO pins of the raspberry pi. Here is the pictorial representation of them
In this architecture the pins are given some names like pin number 8 of the raspberry pi is named as GPIO14 and pin number 3 of the raspberry pi is named as GPIO2 and so on the chart is given from where you can find which pin is named what. And while writing a program to use them you have to provide the given name in the program which you can see in the upcoming lessons. There are some pins which are specifically used in some pre define tasks like for I2C, SPI and UART protocols.
In this case, unlike the BCM structure, the pins are numbered in a zig-zag pattern and you can use these numbers while writing the python scripts. In the given diagram
- Red colored pins are the +5v
- Black colored pins are the GND
- Goldens colored pins are the +3v
- Rest of them can be used as GPIO tasks.
So in the upcoming lesions we are going to use both of them randomly so that you come to know about both of them. How you can use them in your python scripts.
There is another way to find the diagrams in your raspberry Pi. You just need to execute a terminal command which returns a detailed pinout structure of the board.
Let me know how was the lesson in the comment section below.
Keep learning keep building…