ophub / amlogic-s9xxx-armbian

Support for Armbian in Amlogic, Rockchip and Allwinner boxes. Support a311d, s922x, s905x3, s905x2, s912, s905d, s905x, s905w, s905, s905l, rk3588, rk3568, rk3399, rk3328, h6, etc.
GNU General Public License v2.0
5.69k stars 1.83k forks source link

我有个x96 air 2g +16G wifi rtl8189ftv的盒子,请问下这个能否刷入emmc #105

Closed lx7741 closed 2 years ago

lx7741 commented 2 years ago

我使用x96 air的dtb-100可以跑起来,但是一直报rtl871x错误。 使用x96 max+刷入emmc无法启动。 微信图片_20220209184328 微信图片_20220209184336

dinhchinh82 commented 2 years ago

If the configuration you write to the box is exactly the same as the configuration that was started by the usb, and the write cannot be used, it means that it is a locked area and can only be used on the usb.

@ophub I also tested 5.4 kernel and unable to boot from eMMC. By the way, the old firmware from Balbes150 can boot from eMMC. That's strange point I still have not found the reason.

ophub commented 2 years ago

You try to restore the original Android system first, and then install armbian

dinhchinh82 commented 2 years ago

You try to restore the original Android system first, and then install armbian

Yes. I always restore default Android firmware before booting Armbian from USB and then install to eMMC.

luoluo888 commented 2 years ago

首先能用USB/SD进入系统,再用flippy大神install-to-emmc.sh试一下

ophub commented 2 years ago

首先能用USB/SD进入系统,再用flippy大神install-to-emmc.sh试一下

你发的这是半年前的命令了,OpenWrt的写入命令现在更名了是:openwrt-install-amlogic

luoluo888 commented 2 years ago

首先能用USB/SD进入系统,再用flippy大神install-to-emmc.sh试一下

你发的这是半年前的命令了,OpenWrt的写入命令现在更名了是:openwrt-install-amlogic

嗯,我知道。openwrt是新的,但是armbian没更新。我有个x96max+/2+16的板子,写入emmc后,要么黑屏,要么有线网卡无法识别。最后用install-to-emmc.sh写入后,正常用emmc启动,有线网卡正常,2+16也正常

ophub commented 2 years ago

你用的f大哪个版本的固件,s905x3+o的?你看看你使用了哪个dtb和u-boot

你测试的我哪个固件是黑屏或无网络?是不是我打包的固件默认的dtb不对?

luoluo888 commented 2 years ago

用的是56+o的install-to-emmc.sh,用的是u-boot-x96max.bin,dtb是meson-sm1-sei610.dtb。你的固件不管是5.10或者5.4都会黑屏或者网卡驱动不了

luoluo888 commented 2 years ago
#!/bin/bash

cat <<EOF
请选择 Amlogic Box 的类型:
-----------------------------------------------------------------------------------
1. Phicomm N1 (斐讯N1 或 S905X、S905D等盒子), 默认跳过 EMMC 的前面 700MB
2. X96 Max, X96 Max+ (或与之相当的 S905X2、S905X3 盒子),默认跳过 EMMC 的前面 1350MB
3. 自定义要跳过的空间(单位: MB)
0. 我看错了, 不刷了
-----------------------------------------------------------------------------------
EOF

SKIP=700
BOOT=256

read select
case $select in 
    1) SKIP=700;;
        2) SKIP=1350;;
    3) echo -ne "请输入要跳过的大小(MB), 只能是 (68-2048) 范围(如果数值不合理,有变砖可能) : "
       read skip
       if [ -z "$skip" ];then
           echo "输入错误"
           exit 1
       fi
       if (( $skip >= 68  && $skip <= 2048 ));then
           SKIP=$skip
       else
           echo "输入错误: $skip"
           exit 1
       fi
       ;;
    *) exit;;
esac

echo "SKIP = $SKIP MB"
systemctl stop armbian-resize-filesystem.service
systemctl disable armbian-resize-filesystem.service

fstype=$1
case $fstype in 
      xfs) fstype=xfs;;
    btrfs) fstype=btrfs;;
     f2fs) fstype=f2fs;;
        *) fstype=ext4;;
esac

echo "Start script create MBR and filesystem"

hasdrives=$(lsblk | grep -oE '(mmcblk[0-9])' | sort | uniq)
if [ "$hasdrives" = "" ]
then
    echo "UNABLE TO FIND ANY EMMC OR SD DRIVES ON THIS SYSTEM!!! "
    exit 1
fi
avail=$(lsblk | grep -oE '(mmcblk[0-9]|sda[0-9])' | sort | uniq)
if [ "$avail" = "" ]
then
    echo "UNABLE TO FIND ANY DRIVES ON THIS SYSTEM!!!"
    exit 1
fi
runfrom=$(lsblk | grep /$ | grep -oE '(mmcblk[0-9]|sda[0-9])')
if [ "$runfrom" = "" ]
then
    echo " UNABLE TO FIND ROOT OF THE RUNNING SYSTEM!!! "
    exit 1
fi
emmc=$(echo $avail | sed "s/$runfrom//" | sed "s/sd[a-z][0-9]//g" | sed "s/ //g")
if [ "$emmc" = "" ]
then
    echo " UNABLE TO FIND YOUR EMMC DRIVE OR YOU ALREADY RUN FROM EMMC!!!"
    exit 1
fi
if [ "$runfrom" = "$avail" ]
then
    echo " YOU ARE RUNNING ALREADY FROM EMMC!!! "
    exit 1
fi
if [ $runfrom = $emmc ]
then
    echo " YOU ARE RUNNING ALREADY FROM EMMC!!! "
    exit 1
fi
if [ "$(echo $emmc | grep mmcblk)" = "" ]
then
    echo " YOU DO NOT APPEAR TO HAVE AN EMMC DRIVE!!! "
    exit 1
fi

DEV_EMMC="/dev/$emmc"

echo $DEV_EMMC

# 判断内核版本是否 >= 5.10
KERNEL_VERSION=$(uname -r)
K_VER=$(echo "$KERNEL_VERSION" | cut -d '.' -f1)
K_MAJ=$(echo "$KERNEL_VERSION" | cut -d '.' -f2)

if [ $K_VER -eq 5 ];then
    if [ $K_MAJ -ge 10 ];then
        K510=1
    else
        K510=0
    fi
elif [ $K_VER -gt 5 ];then
    K510=1
else
    K510=0
fi

echo "Start backup u-boot default"
dd if="${DEV_EMMC}" of=/root/u-boot-default-aml.img bs=1M count=4 conv=fsync
exists_pts=$(parted ${DEV_EMMC} print |grep 'primary'|wc -l)
if [ $exists_pts -gt 0 ];then
    i=1
    while [ $i -le $exists_pts ]
    do
        parted -s ${DEV_EMMC} rm $i 2>/dev/null
        let i=i+1
    done
fi
dd if=/dev/zero of=${DEV_EMMC} bs=512 count=1 conv=fsync

echo "Start create MBR and partittion"
parted -s "${DEV_EMMC}" mklabel msdos 2>/dev/null
parted -s "${DEV_EMMC}" mkpart primary fat32 $((SKIP*1024*1024))b $(( (SKIP+BOOT)*1024*1024 - 1 ))b 2>/dev/null
parted -s "${DEV_EMMC}" mkpart primary ext4 $(( (SKIP+BOOT)*1024*1024 ))b 100% 2>/dev/null

echo "Start restore u-boot"
dd if=/root/u-boot-default-aml.img of="${DEV_EMMC}" conv=fsync bs=1 count=442 
dd if=/root/u-boot-default-aml.img of="${DEV_EMMC}" conv=fsync bs=512 skip=1 seek=1

sync
echo "Done"

echo "Start copy system for eMMC."

mkdir -p /ddbr
chmod 777 /ddbr

PART_BOOT="${DEV_EMMC}p1"
PART_ROOT="${DEV_EMMC}p2"
DIR_INSTALL="/ddbr/install"

if [ -d $DIR_INSTALL ] ; then
    rm -rf $DIR_INSTALL
fi
mkdir -p $DIR_INSTALL

if grep -q $PART_BOOT /proc/mounts ; then
    echo "Unmounting BOOT partiton."
    umount -f $PART_BOOT
fi
echo -n "Formatting BOOT partition..."
mkfs.vfat -n "BOOT_EMMC" $PART_BOOT
echo "done."

mount -o rw $PART_BOOT $DIR_INSTALL

echo -n "Copying BOOT..."
cp -r /boot/* $DIR_INSTALL && sync
rm -rf $DIR_INSTALL/'System Volume Information' 2>/dev/null
echo "done."

echo -n "Edit init config..."
lines=$(wc -l < $DIR_INSTALL/uEnv.txt)
let lines=lines-1
head -n $lines $DIR_INSTALL/uEnv.txt > $DIR_INSTALL/uEnv-emmc.txt

case $fstype in 
    btrfs) cat >> $DIR_INSTALL/uEnv-emmc.txt <<EOF
APPEND=root=LABEL=ROOTFS_EMMC rootfstype=btrfs rootflags=compress=zstd console=ttyAML0,115200n8 console=tty0 no_console_suspend consoleblank=0 fsck.fix=yes fsck.repair=yes net.ifnames=0 cgroup_enable=cpuset cgroup_memory=1 cgroup_enable=memory swapaccount=1
EOF
;;
          xfs) cat >> $DIR_INSTALL/uEnv-emmc.txt <<EOF
APPEND=root=LABEL=ROOTFS_EMMC rootfstype=xfs rootflags=rw console=ttyAML1,115200n8 console=tty0 no_console_suspend consoleblank=0 fsck.fix=yes fsck.repair=yes net.ifnames=0 cgroup_enable=cpuset cgroup_memory=1 cgroup_enable=memory swapaccount=1
EOF
;;
         f2fs) cat >> $DIR_INSTALL/uEnv-emmc.txt <<EOF
APPEND=root=LABEL=ROOTFS_EMMC rootfstype=f2fs rootflags=rw console=ttyAML1,115200n8 console=tty0 no_console_suspend consoleblank=0 fsck.fix=yes fsck.repair=yes net.ifnames=0 cgroup_enable=cpuset cgroup_memory=1 cgroup_enable=memory swapaccount=1
EOF
;;
         ext4) cat >> $DIR_INSTALL/uEnv-emmc.txt <<EOF
APPEND=root=LABEL=ROOTFS_EMMC rootflags=data=writeback rw console=ttyAML1,115200n8 console=tty0 no_console_suspend consoleblank=0 fsck.fix=yes fsck.repair=yes net.ifnames=0 cgroup_enable=cpuset cgroup_memory=1 cgroup_enable=memory swapaccount=1
EOF
;;
esac

mv $DIR_INSTALL/uEnv-emmc.txt $DIR_INSTALL/uEnv.txt
touch $DIR_INSTALL/uEnv.txt
cp -v $DIR_INSTALL/uEnv.txt /root/uEnv.emmc
if [ $K510 -eq 1 ];then
    cp -v $DIR_INSTALL/uEnv.txt /boot/uEnv.emmc
fi
cp -v /boot/uEnv.txt  /root/uEnv.sd
rm $DIR_INSTALL/s9*
rm $DIR_INSTALL/aml*
mv -f $DIR_INSTALL/boot-emmc.ini $DIR_INSTALL/boot.ini
sed -e "s/u-boot.ext/u-boot.emmc/g" -i "$DIR_INSTALL/boot.ini"
mv -f $DIR_INSTALL/boot-emmc.scr $DIR_INSTALL/boot.scr
mv -f $DIR_INSTALL/boot-emmc.cmd $DIR_INSTALL/boot.cmd
if [ -f /boot/u-boot.ext ] ; then
    if [ $K510 -eq 1 ];then
        cp -v $DIR_INSTALL/u-boot.ext $DIR_INSTALL/u-boot.emmc
    else
        mv -f $DIR_INSTALL/u-boot.sd $DIR_INSTALL/u-boot.emmc
    fi
fi
sync
echo "done."

umount $DIR_INSTALL

if grep -q $PART_ROOT /proc/mounts ; then
    echo "Unmounting ROOT partiton."
    umount -f $PART_ROOT
fi

echo "Formatting ROOT partition..."
case $fstype in 
    btrfs) mkfs.btrfs -f -L ROOTFS_EMMC -m single $PART_ROOT
        ;;
      xfs) mkfs.xfs -f -L ROOTFS_EMMC $PART_ROOT
        ;;
     f2fs) mkfs.f2fs -f -l ROOTFS_EMMC $PART_ROOT
        ;;
     ext4) mkfs.ext4 -F -L ROOTFS_EMMC $PART_ROOT
        ;;
esac
echo "done."

echo "Copying ROOTFS."

case $fstype in 
    btrfs) mount -t btrfs -o compress=zstd $PART_ROOT $DIR_INSTALL
        ;;
      xfs) mount -t xfs $PART_ROOT $DIR_INSTALL
        ;;
         f2fs) mount -t f2fs $PART_ROOT $DIR_INSTALL
        ;;
     ext4) mount -t ext4 $PART_ROOT $DIR_INSTALL
        ;;
esac

cd /
echo "Copy BIN"
tar -cf - bin | (cd $DIR_INSTALL; tar -xpf -)
echo "Copy BOOT"
mkdir -p $DIR_INSTALL/boot
#tar -cf - boot | (cd $DIR_INSTALL; tar -xpf -)
echo "Create DEV"
mkdir -p $DIR_INSTALL/dev
#tar -cf - dev | (cd $DIR_INSTALL; tar -xpf -)
echo "Copy ETC"
tar -cf - etc | (cd $DIR_INSTALL; tar -xpf -)
echo "Copy HOME"
tar -cf - home | (cd $DIR_INSTALL; tar -xpf -)
echo "Copy LIB"
tar -cf - lib | (cd $DIR_INSTALL; tar -xpf -)
echo "Copy LIB64"
tar -cf - lib64 | (cd $DIR_INSTALL; tar -xpf -)
echo "Create MEDIA"
mkdir -p $DIR_INSTALL/media
#tar -cf - media | (cd $DIR_INSTALL; tar -xpf -)
echo "Create MNT"
mkdir -p $DIR_INSTALL/mnt
#tar -cf - mnt | (cd $DIR_INSTALL; tar -xpf -)
echo "Copy OPT"
tar -cf - opt | (cd $DIR_INSTALL; tar -xpf -)
echo "Create PROC"
mkdir -p $DIR_INSTALL/proc
echo "Copy ROOT"
tar -cf - root | (cd $DIR_INSTALL; tar -xpf -)
echo "Create RUN"
mkdir -p $DIR_INSTALL/run
echo "Copy SBIN"
tar -cf - sbin | (cd $DIR_INSTALL; tar -xpf -)
echo "Copy SELINUX"
tar -cf - selinux | (cd $DIR_INSTALL; tar -xpf -)
echo "Copy SRV"
tar -cf - srv | (cd $DIR_INSTALL; tar -xpf -)
echo "Create SYS"
mkdir -p $DIR_INSTALL/sys
echo "Create TMP"
mkdir -p $DIR_INSTALL/tmp
echo "Copy USR"
tar -cf - usr | (cd $DIR_INSTALL; tar -xpf -)
echo "Copy VAR"
tar -cf - var | (cd $DIR_INSTALL; tar -xpf -)
sync

echo "Copy fstab"

rm $DIR_INSTALL/etc/fstab
case $fstype in
    btrfs) cat > $DIR_INSTALL/etc/fstab<<EOF
/dev/root       /               btrfs           defaults,noatime,compress=zstd      0 1
EOF
;;
      xfs) cat > $DIR_INSTALL/etc/fstab<<EOF
/dev/root       /               xfs             defaults,noatime                        0 1
EOF
;;
     f2fs) cat > $DIR_INSTALL/etc/fstab<<EOF
/dev/root       /               f2fs            defaults,noatime                        0 1
EOF
;;
     ext4) cat > $DIR_INSTALL/etc/fstab<<EOF
/dev/root       /               ext4            defaults,noatime,errors=remount-ro      0 1
EOF
;;
esac

if [ $K510 -eq 1 ];then
    BOOT_LABEL="BOOT"
else
    BOOT_LABEL="BOOT_EMMC"
fi

cat >> $DIR_INSTALL/etc/fstab <<EOF
LABEL=${BOOT_LABEL} /boot           vfat            defaults                                0 0
tmpfs           /tmp            tmpfs           defaults,nosuid                         0 0
EOF
echo "done"

rm $DIR_INSTALL/root/install-to-emmc.sh
rm -f $DIR_INSTALL/root/fstab
rm $DIR_INSTALL/usr/bin/ddbr

cd /
sync

umount $DIR_INSTALL

echo "*******************************************"
echo "Complete copy OS to eMMC "
echo "*******************************************"

if [ $K510 -eq 1 ];then
    echo "由于内核版本 >= 5.10, 只能用 tf卡 或 U盘 启动,因此请不要拔掉启动介质!"
    echo "备份 /boot/uEnv.txt 至  /boot/uEnv.sd(如果将来需要进入救援模式,可以把 /boot/uEnv.sd 改名成/boot/uEnv.txt"
    cp -v /boot/uEnv.txt /boot/uEnv.sd
    echo "把 /boot/uEnv.emmc 改名为 /boot/uEnv.txt"
    cp -v /boot/uEnv.emmc /boot/uEnv.txt
    sync
    echo "完成"
fi
echo "安装过程结束,请重启"
ophub commented 2 years ago

如果是+o版,没使用u-boot,那区别就是dtb了,meson-sm1-sei610.dtb 这个我的默认里没,需要手动改uEnv.txt。但是我看了下你发的安装脚本,难道是跳过区域的区别?你是不是手工改了uEnv.txt里面的dtb,安装的时候选择的是2吧? 2) SKIP=1350;; 我是都统一为了跳过700M,难道是覆盖了不安全的区域?

你用我的5.4的固件,手工改uEnv.txt里面的dtb为meson-sm1-sei610.dtb,在usb上使用时屏幕和网卡正常的吧?是写入后才不正常的吧?如果是这样的表现,那就是要区别对待他们的跳过区域了。

lx7741 commented 2 years ago

如果是+o版,没使用u-boot,那区别就是dtb了,meson-sm1-sei610.dtb 这个我的默认里没,需要手动改uEnv.txt。但是我看了下你发的安装脚本,难道是跳过区域的区别?你是不是手工改了uEnv.txt里面的dtb,安装的时候选择的是2吧? 2) SKIP=1350;; 我是都统一为了跳过700M,难道是覆盖了不安全的区域?

你用我的5.4的固件,手工改uEnv.txt里面的dtb为meson-sm1-sei610.dtb,在usb上使用时屏幕和网卡正常的吧?是写入后才不正常的吧?如果是这样的表现,那就是要区别对待他们的跳过区域了。

还真有可能要跳过1350以上,我上次也是改了这个跳过后才正常的,上次用Balbes150大佬的包,他跳过1000M但是跑几天后bootloader就坏了。怀疑要跳过超过1000M

luoluo888 commented 2 years ago

用的是5.4的固件,首先手动改uEnv.txt里面的dtb为meson-sm1-sei610.dtb。用u盘屏幕+网卡正常,但只能识别1G内存。如果再把u-boot-x96max.bin改成u-boot.ext,屏幕+网卡+2G内存正常

lx7741 commented 2 years ago

用的是5.4的固件,首先手动改uEnv.txt里面的dtb为meson-sm1-sei610.dtb。用u盘屏幕+网卡正常,但只能识别1G内存。如果再把u-boot-x96max.bin改成u-boot.ext,屏幕+网卡+2G内存正常

我也用5.4固件,目前5.4固件出现一直打印wifi日志,我直接把wifi关闭了。还有如果刷入desktop鼠标键盘就动不了了,不知道为什么,不过我是x96 air不是max。其他都正常的。网络和wifi都可以识别到。

ophub commented 2 years ago

好的👌今天太晚了就不打扰f大了,明天我再问一下他,确定一下写入脚本的跳过区域。

luoluo888 commented 2 years ago

好的👌今天太晚了就不打扰f大了,明天我再问一下他,确定一下写入脚本的跳过区域。

刚才我试了一下,调成1350后刷入emmc可以启动

lx7741 commented 2 years ago

好的👌今天太晚了就不打扰f大了,明天我再问一下他,确定一下写入脚本的跳过区域。

刚才我试了一下,调成1350后刷入emmc可以启动

你刷入的内核是5.10版本吗?

ophub commented 2 years ago

好的👌明天我一块问一下其他soc的区域。刚才我看了一下op的没有跳过这么大。

luoluo888 commented 2 years ago

好的👌明天我一块问一下其他soc的区域。刚才我看了一下op的没有跳过这么大。

好的,谢了大神。5.4的固件,跳过1350并写入emmc后屏幕+网口正常,内存只有1G。反应一下

ophub commented 2 years ago

2022-03-04 12 33 17

armbian-install: https://github.com/ophub/amlogic-s9xxx-armbian/commit/1c5e4b5394f74456360f3fce7ad1600861b0d9e9

根据f大的指导,参照OpenWrt系统的设置分类调整了写入EMMC的安装脚本设置。根据f大分析过的盒子,905x2, s905x3, s922x的布局都是相同的。

关于在5.4内核里启用u-boot.ext会让盒子识别成2G内存的问题,f大解释说理论上u-boot.ext不涉及内存初始化,那是在acs.bin里完成的。dts里有一段关于内存大小的,但一般都没什么影响。比如dtb里的 reg = <0x0 0x0 0x0 0x80000000>; 是2GB,实际上4GB也一样用。如果你测试的结果是有效果的就继续这样使用吧,在5.4里启用u-boot.ext后的可见变化是会二次重载,会增加10秒左右的启动时间,如果是由路由器DHCP随机分配IP的话,第二次分配的IP才是可用的,如果是MAC绑定IP的话就1个固定的。

luoluo888 commented 2 years ago

2022-03-04 12 33 17

armbian-install: 1c5e4b5

根据f大的指导,参照OpenWrt系统的设置分类调整了写入EMMC的安装脚本设置。根据f大分析过的盒子,905x2, s905x3, s922x的布局都是相同的。

关于在5.4内核里启用u-boot.ext会让盒子识别成2G内存的问题,f大解释说理论上u-boot.ext不涉及内存初始化,那是在acs.bin里完成的。dts里有一段关于内存大小的,但一般都没什么影响。比如dtb里的 reg = <0x0 0x0 0x0 0x80000000>; 是2GB,实际上4GB也一样用。如果你测试的结果是有效果的就继续这样使用吧,在5.4里启用u-boot.ext后的可见变化是会二次重载,会增加10秒左右的启动时间,如果是由路由器DHCP随机分配IP的话,第二次分配的IP才是可用的,如果是MAC绑定IP的话就1个固定的。

好的,一会我测试一下。辛苦大神。这么说内存只是显示的问题,显示1G实际上是2G用。是真的理解吧

ophub commented 2 years ago

你识别成2G理论上不是因为增加了u-boot.ext的原因。

ophub commented 2 years ago

@luoluo888 今天打包的固件写入EMMC可以使用了吧? 你的X96 AIR 2+16G 是不是这款? https://www.gearbest.com/tv-box/pp_3002885621272175.html 是S905X3还是S905X2呢?u-boot-x96max.bin这个是S905X2的。你能确认下你的配置信息吗?你前面提到使用的:

meson-sm1-sei610.dtb
u-boot-x96max.bin

我的安装脚本里面没有添加这个设备的写入信息,你是怎么修改的?你可以使用下面的命令查看写入EMMC后用的文件是否正确 cat /etc/ophub-release

另外你试试这个dtb是否可以使用?有没有wifi?我看产品信息说明里写2G版的无wifi

# 用于 X96 air 千兆版
#FDT=/dtb/amlogic/meson-sm1-x96-air-1000.dtb
# 用于 X96 air 百兆版
#FDT=/dtb/amlogic/meson-sm1-x96-air-100.dtb
luoluo888 commented 2 years ago

我的是x96max+ 2+16 ![Uploading 1646378890437..jpg…]()

ophub commented 2 years ago

好的,我以为你是air

ophub commented 2 years ago

@lx7741 @dinhchinh82 反馈的usb可以使用,写入黑屏的问题应该也是这个跳过分区的原因了,原来是700m,现在改为1350m应该也可以了。

lx7741 commented 2 years ago

@lx7741 楼主反馈的usb可以使用,写入黑屏的问题应该也是这个跳过分区的原因了,原来是700m,现在改为1350m应援也可以了。

好的,我这边试试,谢谢!@ophub

luoluo888 commented 2 years ago

https://m.gearbest.com/tv-box/pp_3007604889413717.html?wid=2000001 我的是x96 max+ 2+16

ophub commented 2 years ago

好的

luoluo888 commented 2 years ago

cat了一下dtb是:sm1_ac213_2g

ophub commented 2 years ago

/boot/uEnv.txt 里可以看dtb,你写入主线u-boot了没?

ophub commented 2 years ago
# 类似这样建立你的安装信息
63:X96 Max 2+16G:s905x3:meson-sm1-sei610.dtb:u-boot-x96maxplus.bin:/usr/lib/u-boot/x96maxplus-u-boot.bin.sd.bin:NA:4C@2100Mhz,2GB Mem,100M Nic,Wifi
luoluo888 commented 2 years ago

只要写入/usr/lib/u-boot/x96maxplus-u-boot.bin.sd.bin都卡在hit any key to stop autoboot。正常读秒是5-4-3-2-1-0。只要写入后读秒直接为0。我晕了!用meson-sm1-sei610.dtb或者meson-sm1-x96-air-100.dtb加上手动改的u-boot.ext(u-boot-x96max.bin)。屏幕+网卡+2G内存正常只要写入emmc后2G变1 G。如果不手动改u-boot.ext,屏幕+网卡+1G。

ophub commented 2 years ago

你是100M的网卡?

luoluo888 commented 2 years ago

是的,一般2+16都是100M网卡

ophub commented 2 years ago

https://github.com/ophub/amlogic-s9xxx-armbian/commit/929659bcda3c456646c4887dda94b1a01351bb8d

以你的实际测试结果添加了63编号的x96max 100M设备,你测试wifi能用不。

luoluo888 commented 2 years ago

测试了,还是1G内存

luoluo888 commented 2 years ago

X96 Max+(2+16):s905x3:meson-sm1-x96-air-100.dtb:u-boot-x96maxplus.bin:NA:NA:4C@2100Mhz,2GB Mem,100M Nic。用u盘启动是1G。写入emmc后成2G

ophub commented 2 years ago

63:X96 Max+ 100Mb:s905x3:meson-sm1-sei610.dtb:u-boot-x96max.bin:NA:NA:4C@2100Mhz,2GB+16GB,100M Nic

这个呢?

luoluo888 commented 2 years ago

63:X96 Max+ 100Mb:s905x3:meson-sm1-sei610.dtb:u-boot-x96max.bin:NA:NA:4C@2100Mhz,2GB+16GB,100M Nic

这个呢?

试了,刷完后1G

ophub commented 2 years ago

你手动改一下安装脚本为u-boot-x96maxplus.bin再试一次

63:X96 Max+ 100Mb:s905x3:meson-sm1-sei610.dtb:u-boot-x96maxplus.bin:NA:NA:4C@2100Mhz,2GB+16GB,100M Nic

ophub commented 2 years ago

或者你就使用air100M的安装选项吧

luoluo888 commented 2 years ago

或者你就使用air100M的安装选项吧

昨晚最后用air100刷入emmc。max+(2+16)和air100安卓固件通刷,就连变砖连接点都一样。马甲了

dinhchinh82 commented 2 years ago

@ophub today I just tried to install latest version (Armbian_22.05.0_Aml_s905x3_bullseye_5.15.26_2022.03.05.1324.img.gz) to my X96 max + (S905X3 2+16G, 100M LAN). After install to eMMC the box still unable to boot.

There are some configurations I already tried: 60:X96 Air 100Mb:s905x3:meson-sm1-x96-air-100.dtb:u-boot-x96maxplus.bin:NA:NA:4C@2100Mhz,2GB Mem,100M Nic,Wifi 59:X96 Air 1Gb:s905x3:meson-sm1-x96-air-1000.dtb:u-boot-x96maxplus.bin:NA:NA:4C@2100Mhz,2GB Mem,1Gb Nic,Wifi

51:X96 Max+:s905x3:meson-sm1-x96-max-plus.dtb:u-boot-x96maxplus.bin:/usr/lib/u-boot/x96maxplus-u-boot.bin.sd.bin:/usr/lib/u-boot/hk1box-bootloader.img:4C@2100Mhz,4GB Mem,1Gb Nic,rtl8822cs wifi

ophub commented 2 years ago

First restore to the original Android TV system, restore the normal partition table information. Then install armbian, select 60 serial number

dinhchinh82 commented 2 years ago

First restore to the original Android TV system, restore the normal partition table information. Then install armbian, select 60 serial number

I will restore again then report the result step by step.

dinhchinh82 commented 2 years ago

First restore to the original Android TV system, restore the normal partition table information. Then install armbian, select 60 serial number

I confirm the solution by changing the dtb file of USB from meson-sm1-x96-max-plus-100m.dtb to meson-sm1-x96-air-100.dtb in uEvn.txt file and using install-to-emmc.sh script.

Then the X96 max+ (2+16G, 100Mb LAN) can boot from eMMC (Kernel 5.4.182).

ophub commented 2 years ago

ok 👌 Before, because the partition only skipped 700mb, it was necessary to skip 1350mb for safe use, and now it has been corrected. If you write emmc before and can't start, you can use to restore the original Android TV system, and then reinstall armbian to solve the problem

dinhchinh82 commented 2 years ago

ok 👌 Before, because the partition only skipped 700mb, it was necessary to skip 1350mb for safe use, and now it has been corrected. If you write emmc before and can't start, you can use to restore the original Android TV system, and then reinstall armbian to solve the problem

I still confused why X96 max + (4G+32G) still boot well from eMMC before?

ophub commented 2 years ago

https://github.com/ophub/amlogic-s9xxx-armbian/issues/105#issuecomment-1058826615

My x96maxplus 4+64 has also been used for a year. But some 2+16 devices can't. I asked flippy to adjust it according to the normal security partition.

luoluo888 commented 2 years ago

最终结果出来了。我今天从网上下载了安卓原厂2/16固件,用u盘启动armbian。2GB内存回来了,在写入emmc也是2GB。由此可见正确的安卓原系统很重要,刷错了原厂固件会有很多问题!完结撒花