构建
-
Orange Pi 3 用户手册推荐用 Ubuntu 14.04 编译,其实用最新的 Debian 10 也可以。以下操作都是在 VirtualBox 里的 Debian 10 (Buster) 里进行;
-
按用户手册里的步骤编译:
apt install sudo sudo apt install git debootstrap sudo apt install zlib1g-dev # 缺失此包会导致下面 OrangePi_Build 执行失败 git clone https://github.com/orangepi-xunlong/OrangePi_Build.git cd OrangePi_Build ./Build_OrangePi.sh # 选择 4.9 内核,比 3.10 新 cd ../OrangePiH6_Linux4.9 sudo apt install binfmt-support # 缺失此包会导致 "Build Release Image" 时失败, # 参考 https://wiki.debian.org/QemuUserEmulation sed -i -e 's/jessie/buster/g; s/Jessie/Buster/g;' scripts/*.sh sed -i -e 's/rm -rf "$TEMP"/echo rm -rf "$TEMP"/' scripts/*.sh sed -i -e 's/EXCLUDE="--exclude=init,systemd-sysv"/#EXCLUDE="--exclude=init,systemd-sysv"/' scripts/*.sh sed -i -e 's/mirrors.ustc.edu.cn/mirrors.tuna.tsinghua.edu.cn/g' scripts/*.sh sed -i -e 's|install_readonly /usr/share/keyrings/debian-archive-keyring.gpg|#install_readonly /usr/share/keyrings/debian-archive-keyring.gpg|' scripts/*.sh #sed -i -e 's/disk_size="1200"/disk_size="3800"/' scripts/build_image.sh ./build.sh # 选择 Buster
-
使用 balenaEtcher 将 output/images/*.img 写入 SD 卡
-
使用 SD 卡启动系统后,执行
OrangePi_install2EMMC.sh
烧写内置的 eMMC -
重启系统,执行一些配置
passwd root passwd orangepi cat >/etc/network/interfaces.d/wlan0 <<EOF auto wlan0 iface wlan0 inet dhcp wpa-ssid ...SSID.... wpa-psk ...PASSWD.. EOF ifdown wlan0 ifup wlan0 dpkg-reconfigure tzdata # 调整时区 dpkg-reconfigure locales # 选择 en_US.UTF-8 和 zh_CN.UTF-8 update-locale LANG=en_US.UTF-8 LANGUAGE=en_US:en LC_CTYPE=zh_CN.UTF-8 apt update apt full-upgrade apt install openssh-server cpufrequtils screen cat >/etc/default/cpufrequtils <<EOF GOVERNOR=conservative MAX_SPEED=1.08G EOF sync reboot cpufreq-info # 检查是否生效 systemctl restart cpufrequtils # 强制生效 cat /sys/class/thermal/*/temp # 查看温度 apt install lxde