文档地址:https://github.com/remote-android/redroid-doc/tree/master
Ubuntu 22.04安装 🔗
sudo apt install linux-modules-extra-`uname -r`
# 用于加载 Linux 内核中的 binder_linux 模块,该模块为 Android 的 Binder 通信机制提供支持
sudo modprobe binder_linux devices="binder,hwbinder,vndbinder"
#添加开机启动(可选)
sudo echo "binder_linux" | sudo tee -a /etc/modules
# (可选)
sudo modprobe ashmem_linux
docker run -itd --rm --privileged \
--pull always \
-v ~/data11:/data \
-p 5555:5555 \
--name redroid11 \
redroid/redroid:12.0.0_64only-latest
docker运行 🔗
version: '3.0'
services:
redroid:
image: registry.cn-guangzhou.aliyuncs.com/xuchen/proxy:redroid-12.0.0_64only-latest
container_name: redroid-12
stdin_open: true
tty: true
privileged: true
ports:
- 5555:5555
volumes:
- /home/abner/Document/redroid:/data:rw
-v /dev/dri:/dev/dri #GPU硬件加速需挂载设备:-v /dev/dri:/dev/dri 并设置redroid.gpu.mode=host。
command:
- androidboot.redroid_width=1080
- androidboot.redroid_height=1920
- androidboot.redroid_dpi=480
- androidboot.redroid_fps=60
- androidboot.redroid_gpu_mode=host #auto, host(使用GPU), guest(软件模拟)
- androidboot.redroid_net_ndns=1 #dns
- androidboot.redroid_net_dns1=114.114.114.114
- androidboot.hardware=mt6891 #cpu
- androidboot.serialno=861503068361145 #设置设备序列号,用于ADB识别
- androidboot.verifiedbootstate=orange #系统验证状态:green(官方锁定)、orange(已解锁Bootloader)
- androidboot.selinux=permissive #enforcing, permissive 强制模式或宽容模式
- ro.secure=0 #0允许root shell,1限制为普通用户
- ro.build.product=chopin #设备型号标识
- ro.product.manufacturer=Xiaomi #设备制造商信息
redroid参数查看 🔗
- redroid: 容器专属参数
- androidboot:内核启动参数,通过U-Boot设置bootargs → 内核设备树(DTB)的/chosen/bootargs节点 → 系统启动后通过/proc/cmdline查看
- ro:只读系统属性,运行
adb shell getprop | grep "ro\."
可查看所有只读属性
QtScrcpy 🔗
#报错解决
sudo apt-get update
sudo apt-get install libqt5multimedia5
QtScrcpy问题 🔗
- 讯飞输入支持键盘,其他不好使
- QtScrcpy 键盘映射 在软件keymap目录下,目前不好使
QtScrcpy 键盘映射 🔗
在线调试地址:https://github.com/barry-ran/QtScrcpy/blob/dev/docs/KeyMapDes.md