🛠 Se connecter en SSH via l'Ethernet
Objectives
Configure the network address of the Model B Rev 2 and control the board remotely via SSH. The board has neither WiFi nor Bluetooth: only the 10/100 Mbps Ethernet port (SMSC LAN9512 chip, behind the single USB bus) allows connecting it to the network.
Hardware
- Raspberry Pi Model B Rev 2 with 32-bit legacy Raspbian
- RJ45 Ethernet cable to the box/router, screen + keyboard for the initial configuration
- Quality micro-USB power supply: brown-outs also cut off the network.
Complete code
# Voir l'adresse IP obtenue par DHCP (interface eth0, pas de wlan0 sur cette carte)
ip -4 addr show eth0
# Adresse statique classique via /etc/network/interfaces (era Raspbian legacy)
sudo nano /etc/network/interfaces
# auto eth0
# iface eth0 inet static
# address 192.168.1.50
# netmask 255.255.255.0
# gateway 192.168.1.1
sudo /etc/init.d networking restart
# Activer le serveur SSH si absent
sudo apt install -y openssh-server
sudo service ssh start
# Depuis un autre poste:
ssh pi@192.168.1.50
Expected verification
ip -4 addr show eth0 displays an IPv4 address; the Ethernet port LED blinks; ssh pi@<ip> opens a remote session. ifconfig -a shows no wireless interface, which is normal for this model.
Common errors
- Looking for a wlan0 interface: the board has no integrated WiFi, confirmed by the datasheet.
- Defective Ethernet cable: 10/100 negotiation fails and falls back to half-duplex; test with another cable.
- Shared USB bus: a heavily used USB drive also slows down the network (LAN9512 is connected to the same 480 Mbps bus).
- Lights off on the router side: check the polyfuse F1 and the power supply, typical symptoms of undervoltage.
Other tutorials for this board
Code examples for this board
led_blink.pyPythonbutton_led.pyPythonservo_sweep.pyPythondht_temp.pyPythonoled_i2c.pyPythonmcp3008_read.pyPython