How to set up a Raspberry Pi 4 for the first time?
What You Need for Raspberry Pi 4 Setup
Required Hardware
-
Raspberry Pi 4 board
-
microSD card (16GB+ recommended, Class 10)
-
Power supply (USB-C, 5V 3A)
-
microSD card reader (for your PC or laptop)
-
HDMI cable (micro-HDMI to HDMI)
-
Monitor (or headless setup option)
-
Keyboard and mouse
-
Internet connection (Wi-Fi or Ethernet)
Step-by-Step Setup (With Monitor)
Step 1: Flash Raspberry Pi OS to microSD
-
Download Raspberry Pi Imager:
https://www.raspberrypi.com/software -
Insert the microSD card into your PC.
-
Open Raspberry Pi Imager and:
-
Select OS: e.g., Raspberry Pi OS (32-bit)
-
Choose storage: your microSD card
-
Click Write → wait until it finishes
-
Step 2: Boot Your Raspberry Pi 4
-
Insert the microSD card into the Pi.
-
Connect:
-
Monitor via micro-HDMI
-
USB keyboard and mouse
-
Ethernet cable (or Wi-Fi will be set up later)
-
-
Plug in the power supply → Raspberry Pi will boot.
Step 3: First-Time Setup Wizard
-
Set language, country, and keyboard.
-
Connect to Wi-Fi (if not using Ethernet).
-
Change the default password (default:
pi
/raspberry
). -
Let it check for and install updates.
-
(Optional) Enable SSH, VNC, or remote access.
Headless Setup (No Monitor)
If you want to set it up without a display:
Step 1: Flash Raspberry Pi OS (Lite or Full)
Same as before — use Raspberry Pi Imager, but:
-
After flashing, open the boot partition (appears as a USB drive).
Step 2: Enable SSH
-
Create an empty file named
ssh
(no extension) in the boot partition.
Step 3: Set Up Wi-Fi
-
Create a file named
wpa_supplicant.conf
in the boot partition with this content:
Replace
"YourWiFiName"
and"YourWiFiPassword"
with your actual Wi-Fi credentials.
Step 4: Boot and Find IP Address
-
Insert microSD into Pi, power it up.
-
Use your router’s admin page or a tool like
Advanced IP Scanner
to find the Pi’s IP. -
Open a terminal and run:
(Default password: raspberry
)
Optional Setup Tips
-
Update your system:
-
Install useful tools:
-
Enable GPIO access with
gpiozero
orRPi.GPIO
libraries
评论
发表评论