Remote Access1. Preliminary preparation1.1. Enable SSH and VNCGraphical interfaceCommand line1.2. Get IPGraphical interface2. SSH remote control3. VNC remote login
We often use SSH and VNC tools to remotely control the Raspberry Pi system.
Note: SSH and VNC are already enabled in the car image, so you can skip the preliminary preparation content
Before performing SSH and VNC remote login, you need to enable SSH and VNC functions in the Raspberry Pi system settings or use the raspi-config tool.
Enable SSH and VNC: applications menu → Preferences → Raspberry Pi Configuration
Use raspi-config tool to enable SSH and VNC functions: Interface Options → SSH/VNC: enable
The steps to enable the VNC function are the same, just follow the above steps!
Note: If the VNC service fails to start, check whether the system has been updated; update the software and restart the system before re-enabling the VNC service.
After enabling SSH and VNC functions, you can remotely control the Raspberry Pi according to its IP!
After the system is connected to WiFi, hover the mouse over the WiFi icon to see the corresponding IP address.
Use the command to view the IP address: hostname -I or ifconfig
After obtaining the IP address of the Raspberry Pi motherboard, you can log in remotely through SSH in the terminal according to the username and password of the Raspberry Pi system.
Take the car hotspot as an example, password: 12345678
SSH remote login command: ssh username@IP address
The car's username is pi, the password is yahboom, and the hotspot IP address is 192.168.1.11
xxxxxxxxxx
ssh pi@192.168.1.11
After obtaining the Raspberry Pi motherboard IP address, you can use the RealVNC Viewer software for remote login.
Take the example of connecting to the car hotspot, password: 12345678
xxxxxxxxxx
The user name for car login is pi, the password is yahboom, and the IP address of the hotspot is 192.168.1.11
After successful remote login, the Raspberry Pi system desktop will be displayed!