admin 管理员组文章数量: 887191
nvidia tegra 3 surface rt 刷postmarketos
前提
自供电 usb hub
越狱(禁止安全启动)
Surface_RT_2_Jailbreak_USB_v1.3c.zip
-
格式化u盘为fat32,
-
解压 Surface_RT_2_Jailbreak_USB_v1.3c.zip 到 空u盘
-
按住
音量下
键 不放, 按电源按钮
第一次进入 u盘 -
越狱中: 选择菜单
Install Golden Keys
--> 同意 -->PLEASE RESET YOUR DEVICE MAULALLY USING THE POWER BUTTON!!!
(手工按电源按钮
重启平板) --> 按住音量下
键 不放, 按电源按钮
第二次进入 u盘 -
越狱中:选择菜单
Install Yahallo
--> 越狱完整(已禁止安全启动)
禁止安全启动后, 不要进入平板自带win8,因为win8会试图 开启 安全启动(入狱)
刷postmarketos
postmarketos,有预编译镜像
- ubuntu22下双击20241211-0533-postmarketOS-v24.06-xfce4-0.5.2-microsoft-surface-rt.img选择写入到目标空u盘
20241211-0533-postmarketOS-v24.06-xfce4-0.5.2-microsoft-surface-rt.img
中的用户user
和用户root
密码都是147147
-
按住
音量下
键 不放, 按电源按钮
第三次进入 u盘 中的postmarketos -
已进入u盘中的postmarketos, wiki\触摸\键盘都正常, 连接wiki, 在线将postmarket安装到平板内的emmc
ustc apline mirror
echo 147147 | sudo -S sed -i 's/dl-cdn.alpinelinux/mirrors.ustc.edu/g' /etc/apk/repositories
echo 147147 | sudo -S apk add pmbootstrap
pmbootstrap init
#edge(应该选v24.06), microsoft, surface-rt, wpa_supplicant, xfce4, 'Build outdated packages : y'
pmbootstrap install --disk /dev/mmcblk0 #由于系统postmarketos(u盘)在usb2.0上, 读写非常慢, 耗时估计有1小时
其他备忘
nvidia tegra 3 surface rt 刷机
Surface_RT_2_Jailbreak_USB_v1.3c.zip
postmarketos,有预编译镜像
树莓派,但iso制作没说清楚
来源: open-surfacert
最渣的帖子
mi note pro (小米note一代 顶配置 全网通): QFIL线刷
状况: mi note pro 无法进入fastboot
解决:QFIL线刷
进 高通EDL:9008串口
:
- usb数据线 的
D+点
接GND点
- 以 该usb数据线 连接
手机mi note pro
和 PC电脑(win10) - 断开 该 usb数据线
D+
和GND
- 此时 PC电脑(win10)设备管理器 出现
高通EDL:9008串口
- QFIL线刷
leo_images_6.1.7_20151221.0000.11_5.1_cn_02396b5585.tgz
(操作如下)
https://firmware.center/firmware/Xiaomi / leo_images_6.1.7_20151221.0000.11_5.1_cn_02396b5585.tgz
https://miuiver/tag/leo-developer-rom
下载速度慢解决: 替换域名 bigota.d.miui
为 bkt-sgp-miui-ota-update-alisgp.oss-ap-southeast-1.aliyuncs
参考1
postmarkos移植教程
https://ivonblog/posts/xperia5-ii-postmarketos-porting/
小米note pro(顶配版)leo (晓龙810:MSM8994) / postmarketos : /Qualcomm_Snapdragon_808/810_(MSM8992/MSM8994)
内核 xiaomi-classic-dev/android_kernel_xiaomi_leo.git
成功: oneplus3t刷ubuntu touch
不要勾选factory reset
, 否则会出现报错connection to device lost
- oneplus3t进入fastboot模式
- 下载:
ubports-installer_0.10.0_win_x64.exe
|ubports-installer_0.10.0_linux_x86_64.AppImage
- 运行: ubports-installer*
- 根据向导往下走,不要勾选
factory reset
, 否则会出现报错connection to device lost
- 报错,手工下载 twrp-3.2.1-0-oneplus3.img 放入
%appdata%/Roaming\ubports\oneplus3\firmware
|~/.cache/ubports/oneplus3/firmware/twrp-3.2.1-0-oneplus3.img
- 根据向导提示, twrp界面上: wpie --> advance --> 非usb外全部擦除 , format data --> .yes
- 向导走完即可
ubuntu touch 并不能用apt软件仓库, 所以对开发人员基本没啥用,
估计可以安装docker
#phablet的密码==sudo密码==root用户密码==锁屏密码123qwe
sudo android-gadget-service enable ssh #启动ssh
sudo mount -o remount rw / #根分区可读可写挂载
sudo vi /etc/init/ssh.override
#exec /usr/sbin/sshd -D -o PasswordAuthentication=no #改为 ... PasswordAuthentication=yes 允许ssh密码登陆
sudo systemctl get-default #multi-user.target
sudo systemctl set-default multi-user.target #重启后依然是图形化界面, 即 ubuntu touch不支持字符界面?
/bin/su 貌似用不着
ssh phablet@ubuntu_touch的ip
输入密码123qwe
高通bootloader:lk2nd
msm8916-mainline/lk2nd/releases/lk2nd-msm8996.img
wget https://github/msm8916-mainline/lk2nd/releases/download/17.0/lk2nd-msm8996.img
#oneplus3t手机进入fastboot
fastboot boot lk2nd-msm8996.img
#可临时进入 lk2nd-msm8996.img 的启动菜单
#boot分区刷入 lk2nd-msm8996.img
#fastboot flash boot lk2nd-msm8996.img
半失败: oneplus3t: 2024-12-11
参考: https://wiki.postmarketos/wiki/OnePlus_3T_(oneplus-oneplus3t)
pmbootstrap及其依赖安装
( cd /app/ && git clone https://gitlab.postmarketos/postmarketOS/pmbootstrap.git ;)
#/app/pmbootstrap/.git/config
git --git-dir=/app/pmbootstrap/.git rev-parse HEAD
#47984a87223b194f841eee4a068e1cc893c7ce05
python3.10 -m venv /app/venv-py310
source /app/venv-py310/bin/activate
export PATH=/app/platform-tools_r28.0.0-linux-android-9.0-Pie:$PATH
#PATH==/app/platform-tools_r28.0.0-linux-android-9.0-Pie:/app/venv-py310/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin
pip config set global.index-url https://mirrors.tuna.tsinghua.edu/pypi/web/simple
pip install poetry
( cd /app/pmbootstrap/ && pip install . && poetry install;)
#poetry install会报错: [tool.poetry] section not found in /app/pmbootstrap/pyproject.tom,
# 但不影响其安装依赖
sudo apt install kpartx
sudo ln -s /app/pmbootstrap/pmbootstrap.py /usr/bin/pmbootstrap
twrp 下 wipe所有
twrp 下 wipe所有, 否则, 刷入postmarketos后启动卡在android图标界面
失败记录: 重启后 手机启动到android图标 卡住: pmbootstrap安装postmarketos到oneplus3t手机
oneplus3t手机 进入twrp
#oneplus3t手机 进入fastboot
#fastboot下进入twrp
fastboot boot twrp-3.2.3-1-oneplus3.img
安装postmarketos
D=~/oneplus3t/; mkdir $D; cd $D
pmbootstrap init
#apline apk的清华镜像 加速下载
#pmbootstrap config mirrors.alpine --reset #清空镜像设置
#pmbootstrap config mirrors.alpine https://mirrors.tuna.tsinghua.edu/alpine #清华镜像不全
pmbootstrap config mirrors.alpine https://mirrors.ustc.edu/alpine/ #中科大镜像 更全
pmbootstrap install --android-recovery-zip
pmbootstrap export
#Export symlinks to: /tmp/postmarketOS-export
#手机twrp下进入adb sideload状态
adb sideload /tmp/postmarketOS-export/pmos-oneplus-oneplus3t.zip
#关闭PC电脑上的chroot环境
pmbootstrap shutdown
ls -lh /tmp/postmarketOS-export/
:
total 48K
lrwxrwxrwx 1 z z 76 12月 11 19:39 boot.img -> /home/z/.local/var/pmbootstrap/chroot_rootfs_oneplus-oneplus3t/boot/boot.img
lrwxrwxrwx 1 z z 76 12月 11 19:39 dtbo.img -> /home/z/.local/var/pmbootstrap/chroot_rootfs_oneplus-oneplus3t/boot/dtbo.img
lrwxrwxrwx 1 z z 77 12月 11 19:39 initramfs -> /home/z/.local/var/pmbootstrap/chroot_rootfs_oneplus-oneplus3t/boot/initramfs
lrwxrwxrwx 1 z z 83 12月 11 19:39 initramfs-extra -> /home/z/.local/var/pmbootstrap/chroot_rootfs_oneplus-oneplus3t/boot/initramfs-extra
lrwxrwxrwx 1 z z 77 12月 11 19:39 lk2nd.img -> /home/z/.local/var/pmbootstrap/chroot_rootfs_oneplus-oneplus3t/boot/lk2nd.img
lrwxrwxrwx 1 z z 88 12月 11 19:39 oneplus-oneplus3t-boot.img -> /home/z/.local/var/pmbootstrap/chroot_native/home/pmos/rootfs/oneplus-oneplus3t-boot.img
lrwxrwxrwx 1 z z 83 12月 11 19:39 oneplus-oneplus3t.img -> /home/z/.local/var/pmbootstrap/chroot_native/home/pmos/rootfs/oneplus-oneplus3t.img
lrwxrwxrwx 1 z z 88 12月 11 19:39 oneplus-oneplus3t-root.img -> /home/z/.local/var/pmbootstrap/chroot_native/home/pmos/rootfs/oneplus-oneplus3t-root.img
lrwxrwxrwx 1 z z 130 12月 11 19:39 pmos-oneplus-oneplus3t.zip -> /home/z/.local/var/pmbootstrap/chroot_buildroot_aarch64/var/lib/postmarketos-android-recovery-installer/pmos-oneplus-oneplus3t.zip
lrwxrwxrwx 1 z z 74 12月 11 19:39 uImage -> /home/z/.local/var/pmbootstrap/chroot_rootfs_oneplus-oneplus3t/boot/uImage
lrwxrwxrwx 1 z z 75 12月 11 19:39 uInitrd -> /home/z/.local/var/pmbootstrap/chroot_rootfs_oneplus-oneplus3t/boot/uInitrd
lrwxrwxrwx 1 z z 75 12月 11 19:39 vmlinuz -> /home/z/.local/var/pmbootstrap/chroot_rootfs_oneplus-oneplus3t/boot/vmlinuz
半正常
- 一台A原生android的oneplus3t 按照此步骤刷入postmarketos正常进入linux
- 另一台B非原生androidoneplus3t 按照此步骤刷入postmarketos后 启动卡在android图标
可能原始是A基础系统是原厂andriod(正常结果), 而B是基础系统未知(失败卡住)
oneplus3t手机 进入fastboot
#oneplus3t手机 进入fastboot
D=~/oneplus3t/; mkdir $D; cd $D
pmbootstrap init
#apline apk的清华镜像 加速下载
#pmbootstrap config mirrors.alpine --reset #清空镜像设置
#pmbootstrap config mirrors.alpine https://mirrors.tuna.tsinghua.edu/alpine #清华镜像不全
pmbootstrap config mirrors.alpine https://mirrors.ustc.edu/alpine/ #中科大镜像 更全
pmbootstrap install
pmbootstrap flasher flash_rootfs
pmbootstrap flasher flash_kernel
#关闭PC电脑上的chroot环境
pmbootstrap shutdown
fastboot reboot #重启
重启后 手机 进入 postmarketos 界面
pc电脑以usb线连接手机
#此时在PC电脑
ip address # 172.16.42.2 == PC的ip, 猜测 172.16.42.1==手机的ip (手机的dhcp服务给usb线的PC分配的ip)
telnet 172.16.42.1 #即可登陆手机postmarketos
依然有问题, 没启动完成
z@mchr:~$ telnet 172.16.42.1
Trying 172.16.42.1...
Connected to 172.16.42.1.
Escape character is '^]'.
postmarketOS debug shell
https://postmarketos/debug-shell
Device: OnePlus 3T (oneplus-oneplus3t)
Kernel: 6.3.1-msm8996
OS ver: edge
initrd: 3.4.6-r1
Run 'pmos_continue_boot' to continue booting.
Read the initramfs log with 'cat /pmOS_init.log'.
Run 'pmos_logdump' to generate a log dump and expose it over USB.
#能用命令行 但是 没启动完成
~ # cat /pmOS_init.log
❬❬ PMOS STAGE 1 ❭❭
initramfs version: 3.4.6-r1
❬❬ PMOS STAGE 2 ❭❭
Setup usb network
Setting up USB gadget through configfs
Starting unudhcpd with server ip 172.16.42.1, client ip: 172.16.42.2
Using interface usb0
Starting the DHCP daemon
Trying to start server with parameters: Server IP addr: 172.16.42.1:67, client IP addr: 172.16.42.2, interface: usb0
Setting framebuffer mode to: U:1080x1920p-0
Trying to mount subpartitions for 10 seconds...
ERROR: failed to mount subpartitions!
Creating logs disk
32+0 records in
32+0 records out
33554432 bytes (32.0MB) copied, 0.064878 seconds, 493.2MB/s
./_info
./blkid.txt
./cmdline.txt
./dmesg.txt
./fdt.dtb
./partitions.txt
./pmOS_init.txt
Making logs available via mass storage
Entering debug shell
/usr/bin/buffyboard
Ignoring invalid config file /etc/buffyboard.conf
Could not update current terminal size: Invalid argument
~ #
pmbootstrap flasher
可用命令
pmbootstrap flasher --help
# boot boot a kernel once
# flash_kernel flash a kernel
# flash_lk2nd flash lk2nd, a secondary bootloader needed for various Android devices
# flash_rootfs flash the rootfs to a partition on the device (partition layout does not get changed)
# flash_vbmeta generate and flash AVB 2.0 image with disable verification flag set to a partition on the device (typically called vbmeta)
# flash_dtbo flash dtbo image
# sideload sideload recovery zip
# list_flavors list installed kernel flavors inside the device rootfs chroot on this computer
# list_devices show connected devices
报错解决: 清华源没有最新的 apk-tools-static, 解决: 用中科大的
更简单的办法 是 中科大 镜像
#pmbootstrap config mirrors.alpine https://mirrors.tuna.tsinghua.edu/alpine #清华镜像不全
pmbootstrap config mirrors.alpine https://mirrors.ustc.edu/alpine/ #中科大镜像 更全
麻烦但通用的办法是绕过
#参考: https://gitlab.postmarketos/postmarketOS/pmbootstrap/-/blob/master/docs/mirrors.md
#apline apk的清华镜像 加速下载
pmbootstrap install
#(1/4) PREPARE NATIVE CHROOT ***
# 走完第一步后 ctrl+c 结束执行 pmbootstrap install
# apline apk配置清华镜像
pmbootstrap config mirrors.alpine https://mirrors.tuna.tsinghua.edu/alpine
#重置
pmbootstrap config mirrors.alpine --reset #清空镜像设置
#再次执行:
pmbootstrap install
#这样能绕过 清华源没有最新的 apk-tools-static
无效写法
#参考,但已经无效了: https://mirrors.tuna.tsinghua.edu/help/alpine/
pmbootstrap chroot
sed -i 's#https\?://dl-cdn.alpinelinux/alpine#https://mirrors.tuna.tsinghua.edu/alpine#g' /etc/apk/repositories
#[16:56:12] ERROR: Arguments --mirror-pmOS and --mirror-alpine have been removed. See docs/mirrors.md regarding how to set mirrors now.
日志: 半正常
pmbootstrap init
pmbootstrap init
配置
(venv-py310-postmarketos) z@mchr:~$ pmbootstrap init
[03:09:22] Location of the 'work' path. Multiple chroots (native, device arch, device rootfs) will be created in there.
[03:09:22] Work path [/home/z/.local/var/pmbootstrap]:
[03:09:23] Choose the postmarketOS release channel.
[03:09:23] Available (11):
[03:09:23] * edge: Rolling release / Most devices / Occasional breakage: https://postmarketos/edge
[03:09:23] * v24.12: Upcoming stable release (DO NOT USE)
[03:09:23] * v24.06: Latest release / Recommended for best stability
[03:09:23] Channel [v24.12]:
[03:09:23] Choose your target device vendor (either an existing one, or a new one for porting).
[03:09:23] Available vendors (61): acer, alcatel, amazon, amediatech, amlogic, apple, ark, arrow, asus, ayn, beelink, bq, cubietech, cutiepi, dongshanpi, epson, essential, fairphone, fxtec, generic, google, htc, huawei, jolla, kobo, lenovo, lg, librecomputer, linksys, mangopi, microsoft, motorola, nokia, nvidia, odroid, oneplus, pine64, postmarketos, purism, qcom, qemu, qualcomm, radxa, raspberry, realme, samsung, shift, sipeed, solidrun, sony, surftab, thundercomm, tolino, trekstor, valve, vivo, volla, wileyfox, xiaomi, xunlong, zte
[03:09:23] Vendor [oneplus]:
[03:09:24] Available codenames (13): billie2, cheeseburger, dumpling, enchilada, fajita, guacamole, hotdogb, instantnoodlep, kebab, lemonade, lemonadep, oneplus3, oneplus3t
[03:09:24] Device codename [oneplus3t]:
[03:09:24] Which kernel do you want to use with your device?
[03:09:24] Available kernels (2):
[03:09:24] * s6e3fa3: Samsung S6E3FA3 Panel. To find out which panel your device uses run cat /proc/cmdline in TWRP terminal
[03:09:24] * s6e3fa5: Samsung S6E3FA5 Panel. To find out which panel your device uses run cat /proc/cmdline in TWRP terminal
[03:09:24] Kernel [s6e3fa5]:
[03:09:25] Username [z]:
[03:09:25] Available providers for postmarketos-base-ui-wifi (2):
[03:09:25] * wpa_supplicant: Use wpa_supplicant as the WiFi backend. (default)
[03:09:25] * iwd: Use iwd as the WiFi backend (but may not work with all devices)
[03:09:25] Provider [default]:
[03:09:26] Available user interfaces (20):
[03:09:26] * none: Bare minimum OS image for testing and manual customization. The "console" UI should be selected if a graphical UI is not desired.
[03:09:26] * cage: (Wayland) Kiosk WM
[03:09:26] * console: Console environment, with no graphical/touch UI
[03:09:26] * fbkeyboard: Plain framebuffer console with touchscreen keyboard support
[03:09:26] * gnome: (Wayland) Gnome Shell
[03:09:26] * gnome-mobile: (Wayland) Gnome Shell patched to adapt better to phones (Experimental)
[03:09:26] * i3wm: (X11) Tiling WM (keyboard required)
[03:09:26] * kodi: (GBM) 10-foot UI useful on TV's
[03:09:26] * lxqt: (X11) Lightweight Qt Desktop Environment (stylus recommended)
[03:09:26] * mate: (X11) MATE Desktop Environment, fork of GNOME2 (stylus recommended)
[03:09:26] * moonlight: (Wayland) Open Source PC client for NVIDIA GameStream, as used by the NVIDIA Shield
[03:09:26] * openbox: (X11) A highly configurable and lightweight X11 window manager (keyboard required)
[03:09:26] * phosh: (Wayland) Mobile UI initially developed for the Librem 5
[03:09:26] * plasma-desktop: (X11/Wayland) KDE Desktop Environment (works well with tablets)
[03:09:26] * plasma-mobile: (Wayland) Mobile variant of KDE Plasma (does not run without hardware acceleration)
[03:09:26] * shelli: Plain console with touchscreen gesture support
[03:09:26] * sway: (Wayland) Tiling WM, drop-in replacement for i3wm (DOES NOT RUN WITHOUT HW ACCELERATION!)
[03:09:26] * sxmo-de-dwm: Simple Mobile: Mobile environment based on SXMO and running on dwm
[03:09:26] * sxmo-de-sway: Simple Mobile: Mobile environment based on SXMO and running on sway
[03:09:26] * weston: (Wayland) Reference compositor (demo, not a phone interface)
[03:09:26] * xfce4: (X11) Lightweight desktop (stylus recommended)
[03:09:26] User interface [console]:
[03:09:26] Additional options: extra free space: 0 MB, boot partition size: 256 MB, parallel jobs: 17, ccache per arch: 5G, sudo timer: False, mirror: http://mirror.postmarketos/postmarketos/
[03:09:26] Change them? (y/n) [n]:
[03:09:26] Additional packages that will be installed to rootfs. Specify them in a comma separated list (e.g.: vim,file) or "none"
[03:09:26] Extra packages [alpine-base]:
[03:09:27] Your host timezone: Asia/Shanghai
[03:09:27] Use this timezone instead of GMT? (y/n) [y]:
[03:09:28] Choose your preferred locale, like e.g. en_US. Only UTF-8 is supported, it gets appended automatically. Use tab-completion if needed.
[03:09:28] Locale [en_US]:
[03:09:29] Device hostname (short form, e.g. 'foo') [oneplus-oneplus3t]:
[03:09:29] NOTE: No SSH public keys found to copy to the device.
[03:09:29] See https://postmarketos/ssh-key-glob for more information.
[03:09:29] After pmaports are changed, the binary packages may be outdated. If you want to install postmarketOS without changes, reply 'n' for a faster installation.
[03:09:29] Build outdated packages during 'pmbootstrap install'? (y/n) [y]:
[03:09:30] Zap existing chroots to apply configuration? (y/n) [y]:
[03:09:30] DONE!
pmbootstrap install
pmbootstrap install
:
(venv-py310-postmarketos) z@mchr:~$ pmbootstrap install
[03:09:33] *** (1/4) PREPARE NATIVE CHROOT ***
[03:09:34] (native) Creating chroot
[03:09:34] (native) install cryptsetup util-linux parted
[03:09:35] *** (2/4) CREATE DEVICE ROOTFS ("oneplus-oneplus3t") ***
[03:09:35] (native) install qemu-aarch64
[03:09:36] Register qemu binfmt (aarch64)
[03:09:36] (rootfs_oneplus-oneplus3t) Creating chroot
[03:09:38] (rootfs_oneplus-oneplus3t) install postmarketos-base device-oneplus-oneplus3t postmarketos-ui-console device-oneplus-oneplus3t-kernel-s6e3fa5 device-oneplus-oneplus3t-nonfree-firmware alpine-base postmarketos-base-nofde doas doas-sudo-shim font-droid font-droid-nonlatin font-twemoji
[03:09:48] (rootfs_oneplus-oneplus3t) install device-oneplus-oneplus3t device-oneplus-oneplus3t-kernel-s6e3fa5
[03:09:48] (rootfs_oneplus-oneplus3t) install postmarketos-mkinitfs
[03:09:48] (rootfs_oneplus-oneplus3t) mkinitfs postmarketos-qcom-msm8996
[03:09:54] *** SET LOGIN PASSWORD FOR: 'z' ***
New password:
Retype new password:
passwd: password updated successfully
[03:10:02] NOTE: No valid keymap specified for device
[03:10:03] *** (3/4) PREPARE INSTALL BLOCKDEVICE ***
[03:10:03] (native) create oneplus-oneplus3t.img (1097M)
[03:10:03] (native) mount /dev/install (oneplus-oneplus3t.img)
[03:10:03] (native) partition /dev/install (boot: 256M, reserved: 0M, root: the rest)
[03:10:03] Mounting partitions of /dev/loop0 inside the chroot
[03:10:03] (native) install e2fsprogs
[03:10:04] (native) format /dev/installp2 (root, ext4)
[03:10:04] (native) mount /dev/installp2 to /mnt/install
[03:10:04] (native) install e2fsprogs
[03:10:04] (native) format /dev/installp1 (boot, ext2), mount to /mnt/install/boot
[03:10:04] (native) create /etc/fstab
[03:10:04] (rootfs_oneplus-oneplus3t) mkinitfs
[03:10:10] *** (4/4) FILL INSTALL BLOCKDEVICE ***
[03:10:10] (native) copy rootfs_oneplus-oneplus3t to /mnt/install/
[03:10:21] (native) make sparse rootfs
[03:10:21] (native) install android-tools
[03:10:53]
[03:10:53] *** FLASHING INFORMATION ***
[03:10:53] Run the following to flash your installation to the target device:
[03:10:53] * pmbootstrap flasher flash_rootfs
[03:10:53] Flashes the generated rootfs image to your device:
[03:10:53] /home/z/.local/var/pmbootstrap/chroot_native/home/pmos/rootfs/oneplus-oneplus3t.img
[03:10:53] (NOTE: This file has a partition table, which contains /boot and / subpartitions. That way we don't need to change the partition layout on your device.)
[03:10:53] * pmbootstrap flasher flash_kernel
[03:10:53] Flashes the kernel + initramfs to your device:
[03:10:53] /home/z/.local/var/pmbootstrap/chroot_rootfs_oneplus-oneplus3t/boot
[03:10:53] (NOTE: fastboot also supports booting the kernel/initramfs directly without flashing. Use 'pmbootstrap flasher boot' to do that.)
[03:10:53] * If the above steps do not work, you can also create symlinks to the generated files with 'pmbootstrap export' and flash outside of pmbootstrap.
[03:10:53]
[03:10:53] *** SSH DAEMON INFORMATION ***
[03:10:53] SSH daemon is enabled (disable with --no-sshd).
[03:10:53] Login as 'z' with the password given during installation.
[03:10:53]
[03:10:53] *** FIREWALL INFORMATION ***
[03:10:53] Firewall is enabled, but will not work (no support in kernel config for nftables).
[03:10:53] If/when the kernel supports it in the future, it will work automatically.
[03:10:53] For more information: https://postmarketos/firewall
[03:10:53]
[03:10:53] NOTE: chroot is still active (use 'pmbootstrap shutdown' as necessary)
[03:10:53] DONE!
pmbootstrap flasher flash_rootfs
(venv-py310-postmarketos) z@mchr:~$ pmbootstrap flasher flash_rootfs
[03:11:24] (native) flash rootfs image
[03:11:25] (native) install android-tools
Sending sparse 'userdata' 1/2 (410854 KB) OKAY [ 9.674s]
Writing 'userdata' OKAY [ 0.020s]
Sending sparse 'userdata' 2/2 (226424 KB) OKAY [ 5.231s]
Writing 'userdata' OKAY [ 0.016s]
Finished. Total time: 15.120s
[03:11:40] NOTE: chroot is still active (use 'pmbootstrap shutdown' as necessary)
[03:11:40] DONE!
pmbootstrap flasher flash_kernel
(venv-py310-postmarketos) z@mchr:~$ pmbootstrap flasher flash_kernel
[03:11:46] (rootfs_oneplus-oneplus3t) install device-oneplus-oneplus3t device-oneplus-oneplus3t-kernel-s6e3fa5
[03:11:46] (rootfs_oneplus-oneplus3t) install postmarketos-mkinitfs
[03:11:46] (rootfs_oneplus-oneplus3t) mkinitfs postmarketos-qcom-msm8996
[03:11:52] (native) flash kernel postmarketos-qcom-msm8996
[03:11:53] (native) install android-tools
Sending 'boot' (20308 KB) OKAY [ 0.469s]
Writing 'boot' OKAY [ 0.150s]
Finished. Total time: 0.715s
[03:11:54] You will get an IP automatically assigned to your USB interface shortly.
[03:11:54] Then you can connect to your device using ssh after pmOS has booted:
[03:11:54] ssh z@172.16.42.1
[03:11:54] NOTE: If you enabled full disk encryption, you should make sure that Unl0kr has been properly configured for your device
[03:11:54] NOTE: chroot is still active (use 'pmbootstrap shutdown' as necessary)
[03:11:54] DONE!
nexus 5
这里更好用: postmarketos/nexus5.md
nexu5 刷入最新固件、android系统
步骤0. 使用旧的 platform-tools_r27:
mkdir ~/nexus5; cd ~/nexus5;
#https://android.googlesource/platform/tools/google_prebuilts/studio/sdk/remote/+/a66136ae1bfeb1b08a42319158a7652938c648d3
#此页面有:dl.google/android/repository/platform-tools_r27.0.1-linux.zip, 此即旧platform-tools_r27下载地址,注意不是该文本的跳转链接
wget dl.google/android/repository/platform-tools_r27.0.1-linux.zip
unzip platform-tools_r27.0.1-linux.zip -d .
file `pwd`/platform-tools/fastboot
#/home/z/nexus5/platform-tools/fastboot: ELF 64-bit LSB shared object
export PATH=`pwd`/platform-tools/:$PATH
which fastboot
#/home/z/nexus5/platform-tools//fastboot
腾讯androidSdk网页/platform-tools_r23-macosx.zip
步骤1. nexus5刷入最新固件、android系统 :
#https://zhuanlan.zhihu/p/529627165
wget https://dl.google/dl/android/aosp/hammerhead-m4b30z-factory-625c027b.zip
unzip hammerhead-m4b30z-factory-625c027b.zip -d .
cd hammerhead-m4b30z
pwd #/home/z/nexus5/hammerhead-m4b30z
./flash-all.sh
#注意不要使用ota包. 必须使用factory包
报错解决e1: flash-all.sh中刷android系统报错 Snapshot cancel …
报错详细:
#flash-all.sh中刷android系统步骤 “ fastboot -w update image-hammerhead-m4b30z.zip “ 报错如下:
#Snapshot cancel FAILED (remote: 'unknown command')
解决办法: “步骤0. 使用旧的 platform-tools_r27”
nexu5 postmarkOS降低亮度、查看电量
cat /sys/class/power_supply/battery/capacity # == 11 == 电量 11%
echo 15 > /sys/class/backlight/lcd-backlight/brightness # 屏幕亮度调整为15%
其他说明
flash-all.sh中的内容
#flash-all.sh中的内容
#{刷入固件
fastboot flash bootloader bootloader-hammerhead-hhz20h.img
fastboot reboot-bootloader
sleep 5
fastboot flash radio radio-hammerhead-m8974a-2.0.50.2.30.img
fastboot reboot-bootloader
#}
#{刷入android系统
sleep 5
fastboot -w update image-hammerhead-m4b30z.zip
#}
factory包内容
#wget https://dl.google/dl/android/aosp/hammerhead-m4b30z-factory-625c027b.zip
#unzip hammerhead-m4b30z-factory-625c027b.zip -d .
pwd #/home/z/nexus5/hammerhead-m4b30z
ls -lh
总计 595M
#固件
-rw-r----- 1 z z 3.1M 12月 8 2016 bootloader-hammerhead-hhz20h.img
-rw-r----- 1 z z 45M 12月 8 2016 radio-hammerhead-m8974a-2.0.50.2.30.img
#android系统:
-rw-r----- 1 z z 548M 12月 8 2016 image-hammerhead-m4b30z.zip
#脚本:
-rw-r----- 1 z z 974 12月 8 2016 flash-all.bat
-rwxr-x--x 1 z z 845 12月 8 2016 flash-all.sh
-rwxr-x--x 1 z z 798 12月 8 2016 flash-base.sh
nexu5 刷入postmarketOS系统
报错解决
data too big 报错解决
报错data too big 在此步骤:
pmbootstrap flasher flash_rootfs --partition userdata
解决: “nexu5 刷入最新固件、android系统”
空间没用上问题解决
userdata 32GB空间没用上 , 问题描述,
问题解决 : 参考本文的“pmaports代码仓库不同分支试错”
nexu5 刷入postmarketOS系统 主步骤
#以下全程插入usb线
fastboot devices
fastboot getvar all
fastboot erase userdata
fastboot erase system
fastboot erase cache
pmbootstrap init
pmbootstrap install
pmbootstrap flasher flash_rootfs --partition userdata
pmbootstrap flasher flash_kernel
fastboot reboot #启动完最终停在postmarketOS界面不动,但实际上此时Linux已经正常启动了
ssh z@172.16.42.1 #usb线插好,即可ssh连接Linux
LG nexus 5 安装好 postmarketOS ,
-
htop命令输出:
-
uname输出
uname -a
#Linux lg-hammerhead 6.3.0-postmarketos-qcom-msm8974 #1 SMP PREEMPT Wed May 3 14:38:30 UTC 2023 armv7l Linux
#LG nexus 5 的确是 armv7
连接wifi
sudo nmtui
其他
sudo apk add htop
sudo apk add curl
关闭防火墙
sudo rc-update del nftables
#sudo rc-update nftables stop
sudo reboot
docker安装
sudo apk upgrade
sudo apk update
sudo apk add docker
sudo addgroup z docker
- 文件 /etc/docker/daemon.json 内容如下:
{
"iptables": false
}
sudo rc-update add docker boot
sudo service docker start
sudo service docker status
lash参考
按这里 Modem 操作,居然说没有modem. 但是nexus5 声称sms是work的,TODO, 有可能是因为没有插手机SIM卡
补充
步骤"pmbootstrap init" 中 用户界面 user interface 选 fbkeyboard 很保险
参考:
- Home Assistant on old Smartphone (Nexus5) with PostmarketOS and Docker
- Alpine Linux 安装 Docker
oneplus 6
build img : 用v22.12 的 sxmo-de-sway
按住音量大,再按电源 进入fastboot
参考: https://wiki.postmarketos/wiki/OnePlus_6_(oneplus-enchilada)
#OnePlus 6 : enchilada
#OnePlus6T : fajita
fastboot oem unlock
pmbootstrap init
pmbootstrap install
fastboot set_active b
fastboot erase dtbo
pmbootstrap flasher flash_rootfs --partition userdata
pmbootstrap flasher flash_kernel
fastboot reboot
ssh z@172.16.42.1
最终用的: 7e7224f4c16dc646b779271e6cd548840ab8c356(v22.12) 的 sxmo-de-sway
pmaports代码仓库不同分支试错
~/.local/var/pmbootstrap/cache_git/pmaports/.git/config : https://gitlab/postmarketOS/pmaports.git
-
f7e12b210dd6bba0f964a63db53afbc265a5384a : 磁盘空间45G, 貌似等一会儿crash了? 此提交在nexus5上好用?
-
7c03891fab8f5be997038dcbe840624e3252f1a3 : 磁盘空间45G, 黑屏
-
eca86adbf38bea4f885222496375d1391f71e228 (master), 18c04de3f8d03f31332c5ea0e6ff123b0a59445f(v23.06) : 磁盘空间几百MB, 屏亮
-
7e7224f4c16dc646b779271e6cd548840ab8c356(v22.12) : 磁盘空间45G, 屏亮
fbkeyboard|console: 电源键不熄屏
lxqt: 电源键不熄屏, GUI界面正常
sxmo-de-sway: 电源键熄屏, GUI界面正常(触摸屏本身就坏了,不太确定) -
cat /proc/cpuinfo : 确实是8核cpu
twrp
#https://eu.dl.twrp.me/enchilada/#google_vignette
wget https://eu.dl.twrp.me/enchilada/twrp-3.7.0_11-0-enchilada.img
fastboot getvar current-slot
#current-slot: a
fastboot flash boot_a twrp-3.7.0_11-0-enchilada.img #失败,并没有进入twrp
fastboot boot twrp-3.7.0_11-0-enchilada.img #估计是自动进入了一加手机的自动恢复
重来 用现成img
##https://images.postmarketos/bpo/v23.06/oneplus-enchilada/gnome-mobile/20230821-2134/
##https://wwwblogs/hupo376787/p/16461892.html
fastboot set_active b
fastboot erase dtbo
fastboot flash boot 20230821-2209-postmarketOS-v23.06-sxmo-de-sway-1.14.0-oneplus-enchilada-boot.img
fastboot flash userdata 20230821-2209-postmarketOS-v23.06-sxmo-de-sway-1.14.0-oneplus-enchilada.img
fastboot reboot
#ssh z@172.16.42.1 #sshd默认关闭的 : https://builds.sr.ht/~postmarketos/job/1045030
安装gcc
sudo apk add gcc
sudo apk add g++
sudo apk add make
sudo apk add gdb
gcc -dumpmachine
#aarch64-alpine-linux-musl
g++ -dumpmachine
#aarch64-alpine-linux-musl
安装numpy
注意: 直接安装 Miniconda3-py310_23.1.0-1-Linux-aarch64.sh 不成功, 说是有docker image可以用。但不想用docker,所以单独安装
sudo apk add python3-dev
pip install numpy
# Using cached https://pypi.tuna.tsinghua.edu/packages/a0/41 /8f53eff8e969dd8576ddfb45e7ed315407d27c7518ae49418be8ed532b07/numpy-1.25.2.tar.gz (10.8 MB)
#有需要编译的
安装jupyter
报错解决1. linux/version.h: No such file or directory
jupyter中的依赖psutil安装时报错: linux/version.h: No such file or directory, 解决:
sudo apk add linux-headers
#(1/1) Installing linux-headers (5.19.5-r0)
报错解决2. 报错 ffi.h: No such file or directory
报错 ffi.h: No such file or directory, 完整报错:
gcc -Wno-unused-result -Wsign-compare -DNDEBUG -g -fwrapv -O3 -Wall -Os -g -O2 -Os -g -O2 -Os -g -O2 -DTHREAD_STACK_SIZE=0x100000 -fPIC -DFFI_BUILDING=1 -DUSE__THREAD -DHAVE_SYNC_SYNCHRONIZE -I/usr/include/ffi -I/usr/include/libffi -I/usr/include/python3.10 -c c/_cffi_backend.c -o build/temp.linux-aarch64-cpython-310/c/_cffi_backend.o
c/_cffi_backend.c:15:10: fatal error: ffi.h: No such file or directory
15 | #include <ffi.h>
| ^~~~~~~
compilation terminated.
error: command '/usr/bin/gcc' failed with exit code 1
解决:
sudo apk search libffi
#libffi-3.4.4-r0
#libffi-doc-3.4.4-r0
#libffi-dbg-3.4.4-r0
#libffi-dev-3.4.4-r0
sudo apk add libffi libffi-dev
安装jupyter
pip install jupyter
"""
Defaulting to user installation because normal site-packages is not writeable
Looking in indexes: https://pypi.tuna.tsinghua.edu/simple
Collecting jupyter
Using cached https://pypi.tuna.tsinghua.edu/packages/83/df/0f5dd132200728a86190397e1ea87cd76244e42d39ec5e88efd25b2abd7e/jupyter-1.0.0-py2.py3-none-any.whl (2.7 kB)
Collecting ipykernel
Using cached https://pypi.tuna.tsinghua.edu/packages/ca/ca/1089ddd8dd3ba03ea593bf20cdc2f7fe02526dcd7d966b7da47aa105e65b/ipykernel-6.25.1-py3-none-any.whl (154 kB)
Collecting jupyter-console
Using cached https://pypi.tuna.tsinghua.edu/packages/ca/77/71d78d58f15c22db16328a476426f7ac4a60d3a5a7ba3b9627ee2f7903d4/jupyter_console-6.6.3-py3-none-any.whl (24 kB)
Collecting qtconsole
Using cached https://pypi.tuna.tsinghua.edu/packages/18/3b/7bdbb99256d1406ae6c8904355222c6dc010640e6be158830f48b7097b32/qtconsole-5.4.3-py3-none-any.whl (121 kB)
Collecting ipywidgets
Using cached https://pypi.tuna.tsinghua.edu/packages/b8/d4/ce436660098b2f456e2b8fdf76d4f33cbc3766c874c4aa2f772c7a5e943f/ipywidgets-8.1.0-py3-none-any.whl (139 kB)
Collecting nbconvert
Using cached https://pypi.tuna.tsinghua.edu/packages/80/ed/d883918ca3777f744f3373fc63d8af47b47237ca703450a451b3e885264a/nbconvert-7.7.4-py3-none-any.whl (254 kB)
Collecting notebook
Using cached https://pypi.tuna.tsinghua.edu/packages/85/76/51777158391e1784cc5a892ff355fd0a0b0b5189aeffce9baf51f514b9a2/notebook-7.0.2-py3-none-any.whl (4.0 MB)
Requirement already satisfied: tornado>=6.1 in ./.local/lib/python3.10/site-packages (from ipykernel->jupyter) (6.3.3)
Requirement already satisfied: comm>=0.1.1 in ./.local/lib/python3.10/site-packages (from ipykernel->jupyter) (0.1.4)
Requirement already satisfied: traitlets>=5.4.0 in ./.local/lib/python3.10/site-packages (from ipykernel->jupyter) (5.9.0)
Requirement already satisfied: nest-asyncio in ./.local/lib/python3.10/site-packages (from ipykernel->jupyter) (1.5.7)
Collecting ipython>=7.23.1
Using cached https://pypi.tuna.tsinghua.edu/packages/52/d1/f70cdafba20030cbc1412d7a7d6a89c5035071835cc50e47fc5ed8da553c/ipython-8.14.0-py3-none-any.whl (798 kB)
Requirement already satisfied: debugpy>=1.6.5 in ./.local/lib/python3.10/site-packages (from ipykernel->jupyter) (1.6.7.post1)
Requirement already satisfied: psutil in ./.local/lib/python3.10/site-packages (from ipykernel->jupyter) (5.9.5)
Requirement already satisfied: packaging in /usr/lib/python3.10/site-packages (from ipykernel->jupyter) (21.3)
Requirement already satisfied: matplotlib-inline>=0.1 in ./.local/lib/python3.10/site-packages (from ipykernel->jupyter) (0.1.6)
Requirement already satisfied: pyzmq>=20 in ./.local/lib/python3.10/site-packages (from ipykernel->jupyter) (25.1.1)
Collecting jupyter-client>=6.1.12
Using cached https://pypi.tuna.tsinghua.edu/packages/29/24/0491f7837cedf39ae0f96d9b3e4db2fae31cc4dd5eac00a98ab0db996c9b/jupyter_client-8.3.0-py3-none-any.whl (103 kB)
Requirement already satisfied: jupyter-core!=5.0.*,>=4.12 in ./.local/lib/python3.10/site-packages (from ipykernel->jupyter) (5.3.1)
Requirement already satisfied: widgetsnbextension~=4.0.7 in ./.local/lib/python3.10/site-packages (from ipywidgets->jupyter) (4.0.8)
Requirement already satisfied: jupyterlab-widgets~=3.0.7 in ./.local/lib/python3.10/site-packages (from ipywidgets->jupyter) (3.0.8)
Requirement already satisfied: prompt-toolkit>=3.0.30 in ./.local/lib/python3.10/site-packages (from jupyter-console->jupyter) (3.0.39)
Requirement already satisfied: pygments in ./.local/lib/python3.10/site-packages (from jupyter-console->jupyter) (2.16.1)
Collecting beautifulsoup4
Using cached https://pypi.tuna.tsinghua.edu/packages/57/f4/a69c20ee4f660081a7dedb1ac57f29be9378e04edfcb90c526b923d4bebc/beautifulsoup4-4.12.2-py3-none-any.whl (142 kB)
Requirement already satisfied: mistune<4,>=2.0.3 in ./.local/lib/python3.10/site-packages (from nbconvert->jupyter) (3.0.1)
Requirement already satisfied: jinja2>=3.0 in ./.local/lib/python3.10/site-packages (from nbconvert->jupyter) (3.1.2)
Requirement already satisfied: markupsafe>=2.0 in ./.local/lib/python3.10/site-packages (from nbconvert->jupyter) (2.1.3)
Requirement already satisfied: bleach!=5.0.0 in ./.local/lib/python3.10/site-packages (from nbconvert->jupyter) (6.0.0)
Requirement already satisfied: jupyterlab-pygments in ./.local/lib/python3.10/site-packages (from nbconvert->jupyter) (0.2.2)
Collecting nbclient>=0.5.0
Using cached https://pypi.tuna.tsinghua.edu/packages/ac/5a/d670ca51e6c3d98574b9647599821590efcd811d71f58e9c89fc59a17685/nbclient-0.8.0-py3-none-any.whl (73 kB)
Requirement already satisfied: pandocfilters>=1.4.1 in ./.local/lib/python3.10/site-packages (from nbconvert->jupyter) (1.5.0)
Collecting nbformat>=5.7
Using cached https://pypi.tuna.tsinghua.edu/packages/f4/e7/ef30a90b70eba39e675689b9eaaa92530a71d7435ab8f9cae520814e0caf/nbformat-5.9.2-py3-none-any.whl (77 kB)
Requirement already satisfied: defusedxml in ./.local/lib/python3.10/site-packages (from nbconvert->jupyter) (0.7.1)
Requirement already satisfied: tinycss2 in ./.local/lib/python3.10/site-packages (from nbconvert->jupyter) (1.2.1)
Collecting notebook-shim<0.3,>=0.2
Using cached https://pypi.tuna.tsinghua.edu/packages/f4/79/73250372e5bbab63018b41b02d5cc6b395655ec6c1254e477ef7c913aada/notebook_shim-0.2.3-py3-none-any.whl (13 kB)
Collecting jupyter-server<3,>=2.4.0
Using cached https://pypi.tuna.tsinghua.edu/packages/28/d9/4bf2ab8410cdc37f54aadb6cae497b9bc8ae16720d97b762b9bfb7834022/jupyter_server-2.7.2-py3-none-any.whl (375 kB)
Collecting jupyterlab-server<3,>=2.22.1
Using cached https://pypi.tuna.tsinghua.edu/packages/a7/0d/6d4eab0391bd4df1c43f308368d5e177b0fa8ac632267222a23b71317091/jupyterlab_server-2.24.0-py3-none-any.whl (57 kB)
Collecting jupyterlab<5,>=4.0.2
Using cached https://pypi.tuna.tsinghua.edu/packages/71/a3/38b9d6492a393dcfdae9e82021655432a9fd6e8f4c03c30a7b55036c0d70/jupyterlab-4.0.5-py3-none-any.whl (9.2 MB)
Requirement already satisfied: ipython-genutils in ./.local/lib/python3.10/site-packages (from qtconsole->jupyter) (0.2.0)
Requirement already satisfied: qtpy>=2.0.1 in ./.local/lib/python3.10/site-packages (from qtconsole->jupyter) (2.3.1)
Requirement already satisfied: webencodings in ./.local/lib/python3.10/site-packages (from bleach!=5.0.0->nbconvert->jupyter) (0.5.1)
Requirement already satisfied: six>=1.9.0 in /usr/lib/python3.10/site-packages (from bleach!=5.0.0->nbconvert->jupyter) (1.16.0)
Requirement already satisfied: stack-data in ./.local/lib/python3.10/site-packages (from ipython>=7.23.1->ipykernel->jupyter) (0.6.2)
Requirement already satisfied: jedi>=0.16 in ./.local/lib/python3.10/site-packages (from ipython>=7.23.1->ipykernel->jupyter) (0.19.0)
Requirement already satisfied: pickleshare in ./.local/lib/python3.10/site-packages (from ipython>=7.23.1->ipykernel->jupyter) (0.7.5)
Requirement already satisfied: pexpect>4.3 in ./.local/lib/python3.10/site-packages (from ipython>=7.23.1->ipykernel->jupyter) (4.8.0)
Requirement already satisfied: decorator in ./.local/lib/python3.10/site-packages (from ipython>=7.23.1->ipykernel->jupyter) (5.1.1)
Requirement already satisfied: backcall in ./.local/lib/python3.10/site-packages (from ipython>=7.23.1->ipykernel->jupyter) (0.2.0)
Requirement already satisfied: python-dateutil>=2.8.2 in ./.local/lib/python3.10/site-packages (from jupyter-client>=6.1.12->ipykernel->jupyter) (2.8.2)
Requirement already satisfied: platformdirs>=2.5 in ./.local/lib/python3.10/site-packages (from jupyter-core!=5.0.*,>=4.12->ipykernel->jupyter) (3.10.0)
Requirement already satisfied: send2trash>=1.8.2 in ./.local/lib/python3.10/site-packages (from jupyter-server<3,>=2.4.0->notebook->jupyter) (1.8.2)
Collecting jupyter-server-terminals
Using cached https://pypi.tuna.tsinghua.edu/packages/ea/7f/36db12bdb90f5237766dcbf59892198daab7260acbcf03fc75e2a2a82672/jupyter_server_terminals-0.4.4-py3-none-any.whl (13 kB)
Collecting jupyter-events>=0.6.0
Using cached https://pypi.tuna.tsinghua.edu/packages/15/0d/3c67f6c432d8085a3cee250e1e235f27b764be90cc2d16fdcc0b1cee9572/jupyter_events-0.7.0-py3-none-any.whl (18 kB)
Requirement already satisfied: overrides in ./.local/lib/python3.10/site-packages (from jupyter-server<3,>=2.4.0->notebook->jupyter) (7.4.0)
Requirement already satisfied: prometheus-client in ./.local/lib/python3.10/site-packages (from jupyter-server<3,>=2.4.0->notebook->jupyter) (0.17.1)
Requirement already satisfied: websocket-client in ./.local/lib/python3.10/site-packages (from jupyter-server<3,>=2.4.0->notebook->jupyter) (1.6.2)
Requirement already satisfied: terminado>=0.8.3 in ./.local/lib/python3.10/site-packages (from jupyter-server<3,>=2.4.0->notebook->jupyter) (0.17.1)
Collecting anyio>=3.1.0
Using cached https://pypi.tuna.tsinghua.edu/packages/19/24/44299477fe7dcc9cb58d0a57d5a7588d6af2ff403fdd2d47a246c91a3246/anyio-3.7.1-py3-none-any.whl (80 kB)
Collecting argon2-cffi
Using cached https://pypi.tuna.tsinghua.edu/packages/a4/6a/e8a041599e78b6b3752da48000b14c8d1e8a04ded09c88c714ba047f34f5/argon2_cffi-23.1.0-py3-none-any.whl (15 kB)
Requirement already satisfied: tomli in ./.local/lib/python3.10/site-packages (from jupyterlab<5,>=4.0.2->notebook->jupyter) (2.0.1)
Collecting async-lru>=1.0.0
Using cached https://pypi.tuna.tsinghua.edu/packages/fa/9f/3c3503693386c4b0f245eaf5ca6198e3b28879ca0a40bde6b0e319793453/async_lru-2.0.4-py3-none-any.whl (6.1 kB)
Collecting jupyter-lsp>=2.0.0
Using cached https://pypi.tuna.tsinghua.edu/packages/8f/b6/a1571e48550855a79898f851f57e5858b00eb36b09ea3b1a8bb65c53a290/jupyter_lsp-2.2.0-py3-none-any.whl (65 kB)
Collecting jsonschema>=4.17.3
Using cached https://pypi.tuna.tsinghua.edu/packages/2b/ff/af59fd34bc4d7ac3e6e0cd1f3c10317d329b6c1aee179e8b24ad9a79fbac/jsonschema-4.19.0-py3-none-any.whl (83 kB)
Requirement already satisfied: requests>=2.28 in ./.local/lib/python3.10/site-packages (from jupyterlab-server<3,>=2.22.1->notebook->jupyter) (2.31.0)
Requirement already satisfied: babel>=2.10 in ./.local/lib/python3.10/site-packages (from jupyterlab-server<3,>=2.22.1->notebook->jupyter) (2.12.1)
Requirement already satisfied: json5>=0.9.0 in ./.local/lib/python3.10/site-packages (from jupyterlab-server<3,>=2.22.1->notebook->jupyter) (0.9.14)
Requirement already satisfied: fastjsonschema in ./.local/lib/python3.10/site-packages (from nbformat>=5.7->nbconvert->jupyter) (2.18.0)
Requirement already satisfied: wcwidth in ./.local/lib/python3.10/site-packages (from prompt-toolkit>=3.0.30->jupyter-console->jupyter) (0.2.6)
Requirement already satisfied: soupsieve>1.2 in ./.local/lib/python3.10/site-packages (from beautifulsoup4->nbconvert->jupyter) (2.4.1)
Requirement already satisfied: sniffio>=1.1 in ./.local/lib/python3.10/site-packages (from anyio>=3.1.0->jupyter-server<3,>=2.4.0->notebook->jupyter) (1.3.0)
Requirement already satisfied: exceptiongroup in ./.local/lib/python3.10/site-packages (from anyio>=3.1.0->jupyter-server<3,>=2.4.0->notebook->jupyter) (1.1.3)
Requirement already satisfied: idna>=2.8 in ./.local/lib/python3.10/site-packages (from anyio>=3.1.0->jupyter-server<3,>=2.4.0->notebook->jupyter) (3.4)
Requirement already satisfied: typing-extensions>=4.0.0 in ./.local/lib/python3.10/site-packages (from async-lru>=1.0.0->jupyterlab<5,>=4.0.2->notebook->jupyter) (4.7.1)
Requirement already satisfied: parso<0.9.0,>=0.8.3 in ./.local/lib/python3.10/site-packages (from jedi>=0.16->ipython>=7.23.1->ipykernel->jupyter) (0.8.3)
Requirement already satisfied: rpds-py>=0.7.1 in ./.local/lib/python3.10/site-packages (from jsonschema>=4.17.3->jupyterlab-server<3,>=2.22.1->notebook->jupyter) (0.9.2)
Collecting jsonschema-specifications>=2023.03.6
Using cached https://pypi.tuna.tsinghua.edu/packages/1c/24/83349ac2189cc2435e84da3f69ba3c97314d3c0622628e55171c6798ed80/jsonschema_specifications-2023.7.1-py3-none-any.whl (17 kB)
Requirement already satisfied: referencing>=0.28.4 in ./.local/lib/python3.10/site-packages (from jsonschema>=4.17.3->jupyterlab-server<3,>=2.22.1->notebook->jupyter) (0.30.2)
Requirement already satisfied: attrs>=22.2.0 in ./.local/lib/python3.10/site-packages (from jsonschema>=4.17.3->jupyterlab-server<3,>=2.22.1->notebook->jupyter) (23.1.0)
Requirement already satisfied: rfc3986-validator>=0.1.1 in ./.local/lib/python3.10/site-packages (from jupyter-events>=0.6.0->jupyter-server<3,>=2.4.0->notebook->jupyter) (0.1.1)
Requirement already satisfied: pyyaml>=5.3 in ./.local/lib/python3.10/site-packages (from jupyter-events>=0.6.0->jupyter-server<3,>=2.4.0->notebook->jupyter) (6.0.1)
Requirement already satisfied: python-json-logger>=2.0.4 in ./.local/lib/python3.10/site-packages (from jupyter-events>=0.6.0->jupyter-server<3,>=2.4.0->notebook->jupyter) (2.0.7)
Requirement already satisfied: rfc3339-validator in ./.local/lib/python3.10/site-packages (from jupyter-events>=0.6.0->jupyter-server<3,>=2.4.0->notebook->jupyter) (0.1.4)
Requirement already satisfied: ptyprocess>=0.5 in ./.local/lib/python3.10/site-packages (from pexpect>4.3->ipython>=7.23.1->ipykernel->jupyter) (0.7.0)
Requirement already satisfied: certifi>=2017.4.17 in /usr/lib/python3.10/site-packages (from requests>=2.28->jupyterlab-server<3,>=2.22.1->notebook->jupyter) (2022.12.7)
Requirement already satisfied: urllib3<3,>=1.21.1 in ./.local/lib/python3.10/site-packages (from requests>=2.28->jupyterlab-server<3,>=2.22.1->notebook->jupyter) (2.0.4)
Requirement already satisfied: charset-normalizer<4,>=2 in ./.local/lib/python3.10/site-packages (from requests>=2.28->jupyterlab-server<3,>=2.22.1->notebook->jupyter) (3.2.0)
Collecting argon2-cffi-bindings
Using cached https://pypi.tuna.tsinghua.edu/packages/74/2b/73d767bfdaab25484f7e7901379d5f8793cccbb86c6e0cbc4c1b96f63896/argon2_cffi_bindings-21.2.0-cp36-abi3-musllinux_1_1_aarch64.whl (83 kB)
Requirement already satisfied: asttokens>=2.1.0 in ./.local/lib/python3.10/site-packages (from stack-data->ipython>=7.23.1->ipykernel->jupyter) (2.2.1)
Requirement already satisfied: executing>=1.2.0 in ./.local/lib/python3.10/site-packages (from stack-data->ipython>=7.23.1->ipykernel->jupyter) (1.2.0)
Requirement already satisfied: pure-eval in ./.local/lib/python3.10/site-packages (from stack-data->ipython>=7.23.1->ipykernel->jupyter) (0.2.2)
Requirement already satisfied: jsonpointer>1.13 in ./.local/lib/python3.10/site-packages (from jsonschema>=4.17.3->jupyterlab-server<3,>=2.22.1->notebook->jupyter) (2.4)
Collecting isoduration
Using cached https://pypi.tuna.tsinghua.edu/packages/7b/55/e5326141505c5d5e34c5e0935d2908a74e4561eca44108fbfb9c13d2911a/isoduration-20.11.0-py3-none-any.whl (11 kB)
Requirement already satisfied: fqdn in ./.local/lib/python3.10/site-packages (from jsonschema>=4.17.3->jupyterlab-server<3,>=2.22.1->notebook->jupyter) (1.5.1)
Requirement already satisfied: webcolors>=1.11 in ./.local/lib/python3.10/site-packages (from jsonschema>=4.17.3->jupyterlab-server<3,>=2.22.1->notebook->jupyter) (1.13)
Requirement already satisfied: uri-template in ./.local/lib/python3.10/site-packages (from jsonschema>=4.17.3->jupyterlab-server<3,>=2.22.1->notebook->jupyter) (1.3.0)
Collecting cffi>=1.0.1
Using cached https://pypi.tuna.tsinghua.edu/packages/2b/a8/050ab4f0c3d4c1b8aaa805f70e26e84d0e27004907c5b8ecc1d31815f92a/cffi-1.15.1.tar.gz (508 kB)
Preparing metadata (setup.py) ... done
Requirement already satisfied: pycparser in ./.local/lib/python3.10/site-packages (from cffi>=1.0.1->argon2-cffi-bindings->argon2-cffi->jupyter-server<3,>=2.4.0->notebook->jupyter) (2.21)
Collecting arrow>=0.15.0
Using cached https://pypi.tuna.tsinghua.edu/packages/67/67/4bca5a595e2f89bff271724ddb1098e6c9e16f7f3d018d120255e3c30313/arrow-1.2.3-py3-none-any.whl (66 kB)
Installing collected packages: cffi, beautifulsoup4, async-lru, anyio, jupyter-server-terminals, jupyter-client, jsonschema-specifications, arrow, argon2-cffi-bindings, jsonschema, isoduration, ipython, argon2-cffi, nbformat, ipywidgets, ipykernel, qtconsole, nbclient, jupyter-events, jupyter-console, nbconvert, jupyter-server, notebook-shim, jupyterlab-server, jupyter-lsp, jupyterlab, notebook, jupyter
DEPRECATION: cffi is being installed using the legacy 'setup.py install' method, because it does not have a 'pyproject.toml' and the 'wheel' package is not installed. pip 23.1 will enforce this behaviour change. A possible replacement is to enable the '--use-pep517' option. Discussion can be found at https://github/pypa/pip/issues/8559
Running setup.py install for cffi ... done
Successfully installed anyio-3.7.1 argon2-cffi-23.1.0 argon2-cffi-bindings-21.2.0 arrow-1.2.3 async-lru-2.0.4 beautifulsoup4-4.12.2 cffi-1.15.1 ipykernel-6.25.1 ipython-8.14.0 ipywidgets-8.1.0 isoduration-20.11.0 jsonschema-4.19.0 jsonschema-specifications-2023.7.1 jupyter-1.0.0 jupyter-client-8.3.0 jupyter-console-6.6.3 jupyter-events-0.7.0 jupyter-lsp-2.2.0 jupyter-server-2.7.2 jupyter-server-terminals-0.4.4 jupyterlab-4.0.5 jupyterlab-server-2.24.0 nbclient-0.8.0 nbconvert-7.7.4 nbformat-5.9.2 notebook-7.0.2 notebook-shim-0.2.3 qtconsole-5.4.3
"""
启动jupyter
jupyter-notebook --help-all | grep -A 5 -B 5 -n localhost
820---ServerApp.ip=<Unicode>
821- The IP address the Jupyter server will listen on.
822: Default: 'localhost'
ip address
4: wlan0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue state UP qlen 1000
link/ether 02:00:6f:c8:2a:61 brd ff:ff:ff:ff:ff:ff
inet 10.0.4.102/24
oneplus-enchilada:~$ mkdir jupyter_home ; cd jupyter_home/
jupyter-notebook --ServerApp.ip=0.0.0.0
#http://10.0.4.102:8888/tree?token=a64a4677d7fc685531f348599f0d460e0e33056279328623
!uname -a
#Linux oneplus-enchilada 6.3.2-sdm845 #1-postmarketos-qcom-sdm845 SMP PREEMPT Tue May 16 09:19:52 UTC aarch64 GNU/Linux
import numpy
z=numpy.zeros_like((3,4))
type(z)
#numpy.ndarray
小米note顶配版
高通紧急模式刷机(9008模式): 最终失败
mi-note-pro-leo-china-fastboot-recovery-rom
参考1
qualcomm-hs-usb-qdloader-9008
-
按住 音量-, 再按 开机键, 进入fastboot模式,此时oem没有解锁
-
下载并安装 高通9008驱动 qualcomm-hs-usb-qdloader-9008/QDLoaderHS_USB_Driver_64bit_Setup.exe
-
fastboot模式下 进入 高通9008模式
fastboot oem edl
- 下载、解压、运行XiaoMiFlash.exe: mi-note-pro-leo-china-fastboot-recovery-rom/MiFlash20220507.zip/XiaoMiFlash.exe
若 点击加载设备 后 报错 找不到路径*/log/*, 则在解压路径 E:\xiaomi_note_leo\MiFlash20220507下新建目录 log,再次打开XiaoMiFlash.exe 即可
9008刷机最终失败,报错:
COM6 System.Exception: configure failed!!!
在 XiaoMiFlash.code.bl.SerialPortDevice.ConfigureDDR(Int32 intSectorSize, Int32 buffer_sectors, String ddrType, Int32 m_iSkipStorageInit)
twrp卡刷:刷机成功
参考: 小米手机刷 TWRP 方法(解决卡米问题)
1. 小米bootload解锁
下载bootload解锁工具: miflash_unlock_7.6.727.43.zip
登录手机号(验证码或密码),以解锁。不要用其他方式登录,否则1004报错。
2. fastboot下刷入TWRP
音量- 、 电源 进入 fastboot, 刷入twrp:
fastboot flash recovery TWRP-20171031-3.1.1.0-leo.img
小米note顶配版leo, twrp下载,搜索leo
fastboot reboot
3. twrp下刷入zip包
下载:
-
下载miui_MINotePro_V9.2.3.0.NXHCNEK_1deef92a66_7.0.zip,
-
下载Magisk
步骤:
-
音量+ 、 电源, 进入twrp,允许修改System分区
-
此时电脑上可以看到手机存库空间,
-
将Magisk .zip 复制到 手机存储卡根目录, twrp下 安装 该zip
此步骤剔除了小米启动时验证完整性,没有这一步 启动后 停在 “mi” 界面,俗称 “卡米”?
- 将刷机包miui_MINotePro_V9.2.3.0.NXHCNEK_1deef92a66_7.0.zip复制到手机存储卡根目录 , twrp 下 安装,选 该zip,…, 重启 , 漫长等待 后 进入android系统。
版权声明:本文标题:mi note pro:QFIL线刷,ubuntu touch,高通bootloader:lk2nd, postmarket:nexu5|一加6刷|tegra3 surface rt移植 内容由网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://www.freenas.com.cn/jishu/1734985011h1686797.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论