









The Raspberry Pi comes in various models, such as the Raspberry Pi 4 Model B, Raspberry Pi 3 Model B+, and Raspberry Pi Zero. Below are the general technical specifications for the Raspberry Pi 4 Model B:
| Specification | Details |
|---|---|
| Processor | Quad-core ARM Cortex-A72 (64-bit) at 1.5 GHz |
| RAM | 2GB, 4GB, or 8GB LPDDR4 |
| Storage | MicroSD card slot for OS and data storage |
| USB Ports | 2x USB 3.0, 2x USB 2.0 |
| HDMI Ports | 2x Micro HDMI (supports up to 4K resolution) |
| Networking | Gigabit Ethernet, 802.11ac Wi-Fi, Bluetooth 5.0 |
| GPIO Pins | 40-pin header (3.3V logic, includes I2C, SPI, UART, and GPIO support) |
| Power Supply | 5V/3A via USB-C or GPIO header |
| Dimensions | 85.6mm x 56.5mm x 17mm |
The Raspberry Pi features a 40-pin GPIO header. Below is a summary of the pin configuration:
| Pin Number | Pin Name | Description |
|---|---|---|
| 1 | 3.3V Power | 3.3V power supply |
| 2 | 5V Power | 5V power supply |
| 3 | GPIO2 (SDA1) | I2C Data |
| 4 | 5V Power | 5V power supply |
| 5 | GPIO3 (SCL1) | I2C Clock |
| 6 | Ground | Ground |
| 7 | GPIO4 | General-purpose I/O |
| 8 | GPIO14 (TXD) | UART Transmit |
| 9 | Ground | Ground |
| 10 | GPIO15 (RXD) | UART Receive |
| ... | ... | ... |
| 39 | Ground | Ground |
| 40 | GPIO21 | General-purpose I/O |
For a complete GPIO pinout, refer to the official Raspberry Pi documentation.
sudo apt update && sudo apt upgrade.RPi.GPIO or gpiozero.Below is an example of how to blink an LED connected to GPIO pin 17 using Python:
import RPi.GPIO as GPIO import time
GPIO.setmode(GPIO.BCM) # Use Broadcom pin numbering GPIO.setup(17, GPIO.OUT) # Set GPIO pin 17 as an output
try: while True: GPIO.output(17, GPIO.HIGH) # Turn LED on time.sleep(1) # Wait for 1 second GPIO.output(17, GPIO.LOW) # Turn LED off time.sleep(1) # Wait for 1 second except KeyboardInterrupt: # Clean up GPIO settings on exit GPIO.cleanup()
sudo rpi-update.Can I power the Raspberry Pi via GPIO pins? Yes, you can supply 5V to the 5V and GND pins, but ensure the power source is stable.
How do I enable SSH for remote access?
Place an empty file named ssh (no extension) in the boot partition of the microSD card before the first boot.
What is the maximum current the GPIO pins can handle? Each GPIO pin can source/sink up to 16mA, with a total maximum of 50mA across all pins.
By following this documentation, you can effectively use the Raspberry Pi for a wide range of projects and applications.