Jump to content

Recommended Posts

Posted

Hello, I am currently using a TV BOX X96 Mini running Android TV 9 and using AMLOGIC S905W CPU. Then I was intending to run on ARMBIAN, so I followed the instructions on this WEB: [https://i12bretro.github.io/tutorials/0316.html] After doing the full setup steps, I used 2 ways :
Method 1:

Press the reset button on the TVBOX to boot (But not in armbian but in android ]
Method 2:

I used the application available on the TVbox which is [UPDATE] to run [aml.autoscript.zip], and after I press the update button it enters the Download Mode of the TV box and gives an error, and that's me Can't get into ARMBIAN

IMG_20230226_201713.jpg

IMG_20230226_201719.jpg

Posted

Please try with the instructions on this site (where you originally posted this) using current downloads.

 

I have multiple of these boxes and the reset button should work.

Describe what happens when you use the reset button (complete description like how long you are holding reset, what is shown on the screen, when you are adding power etc.)

 

  • SteeMan changed the title to Problems installing on X96 mini
Posted

Since I meet the same issue with the thread owner, then I reply this thread.

Historical data: On the same box I made it successfully with the steps (but I do not remember that I make it works either using an sd card or USB, or the exact image), I remember I used u-boot-s905x-s912 , then I move all the data to eMMC successfully too (I remember the LAN works ok, wifi worked with a  Wifi USB Dongle). Now after 2 years the OS was broken because the disk is full, I tried again and see this issue. I actually do not set high expectation for this box: Just a place where I can install small tools like Pihole, I do not need wifi just the Ethernet.

 

As I tried and failed many times so I tried to flash the eMMC to Android & now I can use the Android OS.

 

Here is my configuration:

Hardware:

X905W 2G RAM, 16GB eMMC storage.

 

Software: 

 

Try this Armbian_20.10_Arm-64_focal_current_5.9.0_desktop.img.xz (both Balena Etcher & Rufus 3.12)

Also try this: Armbian_23.02.2_Aml-s9xx-box_bullseye_current_6.1.11.img.xz

 

u-boot.ext copied from u-boot-s905x-s912 (635kB) (copied not moved)

 

extlinux.conf (also tried with meson-gxl-s905x-p212.dtb)

LABEL Armbian
LINUX /uImage
INITRD /uInitrd

#FDT /dtb/amlogic/meson-gxbb-p200.dtb
#FDT /dtb/amlogic/meson-gxl-s905x-p212.dtb
#FDT /dtb/amlogic/meson-gxl-s905w-tx3-mini.dtb
FDT /dtb/amlogic/meson-gxl-s905w-p281.dtb
#FDT /dtb/amlogic/meson-gxm-q200.dtb
#FDT /dtb/amlogic/meson-g12a-x96-max.dtb
#FDT /dtb/amlogic/meson-g12b-odroid-n2.dtb

append root=UUID=afbf3a1b-d905-4b27-b78a-3682d3db0dca rootflags=data=writeback console=ttyAML0,115200n8 console=tty0 rw no_console_suspend consoleblank=0 fsck.fix=yes fsck.repair=yes net.ifnames=0 splash plymouth.ignore-serial-consoles

 

Note: The above extlinux.conf is generated with the build Armbian_23.02.2_Aml-s9xx-box_bullseye_current_6.1.11.img.xz, for Armbian_20.10_Arm-64_focal_current_5.9.0_desktop.img.xz the last line is slightly different: root=UUID=ROOTFS ...

Tried on both SD Card(32GB & 64GB) & USB (16GB)  and get the same issue, I cannot boot to the install screen.

- Using Method 2 I got the same error as the thread owner shows.

- Using Method 1 (the toothpick method): I hold the toothpick and see that the screen show X96 Mini screen (same as when I boot to the Android OS) then it boot again to that screen and make it a forever loop, if I withdraw the toothpick there will be no HDMI signal, the monitor will turn off.

 

Thank you so much if you have any suggestion.

 

Posted
On 3/5/2023 at 11:03 AM, AlexanderTN said:

- Using Method 1 (the toothpick method): I hold the toothpick and see that the screen show X96 Mini screen (same as when I boot to the Android OS) then it boot again to that screen and make it a forever loop, if I withdraw the toothpick there will be no HDMI signal, the monitor will turn off.

How long are you holding the reset button.  Try different lengths of time between 2 and 10 seconds.  It sounds like you are holding it too long and it is booting into android recovery).  If you are seeing repeated booting, you are holding it too long.

 

Posted (edited)

@SteeManThank you for the reply. I tried different lengths of time between 2 and 10 seconds, and the result is the same:

- If I hold it too long it boots forever. It can only boot into android recovery if I ejected the SD card.

- If I release the toothpick it will be "No signal" from the screen monitor (while the box shows blue light).

 

P/S: I tried different ROM like  TX3Mini-20171220-Tanix_Box_Com.img, X96_Mini_Amlo_S905W_290421_9.0_Amlo.zip - do you think the Android ROM could be the issue? What is the Android ROM you are using for your X96W boxes?

Edited by AlexanderTN
Posted
7 minutes ago, AlexanderTN said:

P/S: I tried different ROM like  TX3Mini-20171220-Tanix_Box_Com.img, X96_Mini_Amlo_S905W_290421_9.0_Amlo.zip - do you think the Android ROM could be the issue? What is the Android ROM you are using for your X96W boxes?

Why do you mention android roms?  The reset button has nothing to do with installing android roms.

Posted (edited)
Quote

Why do you mention android roms?  The reset button has nothing to do with installing android roms.

@SteeManBecause I thought that I should bring the box back to its original state by reinstalling the Android ROM (I use USB Burning tool to flash the Android ROM). Then from that starting point, I do install the Armbian using the toothpick method.

So my assumption is wrong?

Edited by AlexanderTN
Posted

So I had some more time today, I restored my test x96 mini box back to android, then downloaded the current jammy 23.02 build: Armbian_23.02.2_Aml-s9xx-box_jammy_current_6.1.11.img.xz, installed it onto sd card using balenea, copied u-boot-s905x-s912 -> u-boot.ext, edited the extlinux.conf to use: FDT /dtb/amlogic/meson-gxl-s905w-p281.dtb

Inserted the sd card, pressed and held reset button, plugged in power, waited about 2 seconds, released the reset button and it booted into Armbian jammy.

 

So it works for me.  Things to check for: are you sure you are using a quality sd card? Are you sure you have properly copied the u-boot.ext?

While I don't think it would be an issue with the android firmware you are using, especially as you have tried different ones, the one I am using (don't know where I got it, as I downloaded it years ago) is of size: 1,566,582,416

 

 

Posted

Hi @SteeMan

Really thank you for taking the time to help me.

The SD card I used was the one I used to install Manjaro on another box so I think it's ok (although it's not class 10).

I want to update you that I finally found out that somehow the HDMI signal does not work, but it actually boots.

- I go to check the router and from the DHCP section, I found out that the armbian device is running with an IP.

- then I ping/ssh to that IP and voila` I can control it (using the default username password root/1234).

 

Now it's time to modify the dtb (as with my box, I have to change the max_frequency value inside dts to 50000000 so that I can recognize the eMMC disk) and try to install to eMMC.

 

Again, thank you!

 

Posted

I have X96mini on hardware revision Q6X v2.3 18186 with SanDisk nand chip and I'm facing same issue: it can't boot into Armbian. 

I've tried images:

* `Armbian_23.02.2_Aml-s9xx-box_bullseye_current_6.1.11.img`
* `Armbian_23.02.2_Aml-s9xx-box_jammy_current_6.1.11.img`
* `Armbian_23.05.0_amlogic_s905w_jammy_5.15.106_server_2023.04.06.img`
* `Armbian_23.05.0_amlogic_s905w_bullseye_6.1.22_server_2023.04.05.img`

I've copied `u-boot-s905x-s912` to `u-boot.ext` and changed `extlinux.conf` to use `meson-gxl-s905w-p281.dtb` DTB.

It doesn't matter how long I press reset button, if it's pressed it boots straight into Android Recovery. I've tried factory reset from said recovery, but no luck.

At the same time I have no issues booting into CoreELEC (`CoreELEC-Amlogic-ng.arm-21.0-Omega_nightly_20230402-Generic.img`) with `gxl_p281_2g.dtb`, just by inserting SD card without even touching reset button. It boots even from USB stick inserted in white port.

Btw, is there any way to force u-boot to log to HDMI instead of uart in aml_autoscript/boot.scr?

Thanks!

Posted

@yopp  I assume you are following these instructions: https://forum.armbian.com/topic/17106-installation-instructions-for-tv-boxes-with-amlogic-cpus

 

And you specifically are following this note: 

 

Note: If you have previously run other distributions on the box such as coreelec the below installation will not work.  You will need to restore the original android firmware before attempting the install.  coreelec changes the boot environment in ways that are incompatible with these Armbian builds.

 

If you have previously booted coreelec, armbian will not boot.

Posted (edited)

@SteeMan, thanks for the link! I don't have original firmware around, but I do have 10 boxes :)

I've flashed `Armbian_23.02.2_Aml-s9xx-box_jammy_current_6.1.11` on sd card and inserted it in fresh box, that was only booted in stock Android 

And with following configuration
 

$ md5sum u-boot.ext u-boot-s905x-s912
81af2e7c3577b983e4ec88ff870c5ffb  u-boot.ext
81af2e7c3577b983e4ec88ff870c5ffb  u-boot-s905x-s912
$ cat extlinux/extlinux.conf
LABEL Armbian
LINUX /uImage
INITRD /uInitrd

#FDT /dtb/amlogic/meson-gxbb-p200.dtb
#FDT /dtb/amlogic/meson-gxl-s905x-p212.dtb
FDT /dtb/amlogic/meson-gxl-s905w-p281.dtb
#FDT /dtb/amlogic/meson-gxm-q200.dtb
#FDT /dtb/amlogic/meson-g12a-x96-max.dtb
#FDT /dtb/amlogic/meson-g12b-odroid-n2.dtb

  append root=UUID=89c45261-1cd5-4b2d-9970-1b5a56ff98e2 rootflags=data=writeback console=ttyAML0,115200n8 console=tty0 rw no_console_suspend consoleblank=0 fsck.fix=yes fsck.repair=yes net.ifnames=0 splash plymouth.ignore-serial-consoles


I'm getting  black screen if I hold reset for 2,3,4,5 seconds. With 6 seconds and more I get X96mini splash screen for a second and then black screen again. 

I tried using `gxl_p281_2g.dtb` from coreelec image, but result is the same — black screen.

Edited by yopp
Posted

Okay, wild thing: I've tried to poke UART with jumper wire with a help of my friend, who plugged/unplugged power on my command. We did that without HDMI cable connected. I finally was able to see serial port logs and guess what... it booted! 

 

At first I've thought that I haven't waited long enough for it to boot. I've attached HDMI cable back, rebooted and... same black screen. I've detached HDMI thinking of asking friend to do power thing again. I thought maybe I've shorted something around while I was poking UART. I've plugged power back and went for a friend.

 

Accidentally I left ping pinging IP of the box and when I was back... host was responding to ICMP. And I was able to SSH into the host, I've attached HDMI back and voila: I had terminal on a screen. I've installed Armbian on emmc using `install-aml.sh` script and without USB stick it behaved the same: if HDMI is plugged there is no output after boot. 

I've tried to verify my findings on another brand new box. My steps:

  • Plugged USB stick with 
  • Plugged network cable
  • Held reset button
  • Plugged power
  • Waited about 2-5 seconds and released reset button
  • Waited until box acquired IP over DHCP
  • Plugged HDMI cable
  • Got terminal output on screen

I suppose there is some bug in video initialization at early stages of boot (u-boot?) that breaks HDMI when cable plugged in. Is there a place I can report it? I contribute boot logs over UART with cable both plugged and unplugged. 

 

 

Posted
21 hours ago, yopp said:

if HDMI is plugged there is no output after boot. 

What do you mean by this?  There is no output at all, or no output after boot?

 

What image are you using?

 

Have you tried different hdmi monitors and different hdmi cables?

 

 

Posted

Try different monitor indeed helps.

So this is my case (just have time to test it this morning) that explain the issue I met):

- in 2020 I tried a full HD Dell monitor and I can see the boot screen and logs from that monitor

- in 2023 I tried again on a 2K LG monitor and it shows nothing on screen

 

So as SteeMan said : SD card quality and  monitor type are the factor we need to check when we encounter this 'HDMI boot issue'

Cheers.

Posted (edited)
18 hours ago, SteeMan said:

What do you mean by this?  There is no output at all, or no output after boot?

 

If HDMI cable plugged in on power-on there is no video signal at all. If HDMI cable is not plugged in on power-on and attached 30 seconds later, there is video signal and everything work as expected. 
 

18 hours ago, SteeMan said:

What image are you using?


So far I've tried `Armbian_23.02.2_Aml-s9xx-box_jammy_current_6.1.11` and `Armbian_23.02.2_Aml-s9xx-box_bullseye_current_6.1.11`. Both have same issues 

 

18 hours ago, SteeMan said:

Have you tried different hdmi monitors and different hdmi cables?


I don't have other monitors around, only this one. I don't think it's either cable, monitor or SD card, as CoreELEC and stock android work just fine on the same hardware.

 

On monday, I'll try to dump boot logs for both cases when HDMI attached and not attached at boot. I'm curios whose fault is that: u-boot or kernel. 

Edited by yopp
Posted (edited)

@AlexanderTN In my case this monitor does work, but only if cable plugged in after boot.

 

Hum, my monitor is 4K, and since your FHD worked and 2K does not, it might be related to resolutions that are higher than supported by GPU. Maybe it tries to initialize HDMI using max resolution reported obtained by HDMI's EDID and defaults to some hard-coded "safe" value if there is no device to initialize from, hence no resolution is reported by monitor. 

Edited by yopp
Posted (edited)

 

As I suspected, that's HDMI subsystem issue. Here is `dmesg`  where we can see driver crash:

[    5.636243] [drm] Initialized lima 1.1.0 20191231 for d00c0000.gpu on minor 2
[    5.645822] ------------[ cut here ]------------
[    5.676515] [CRTC:42:meson_crtc] vblank wait timed out
[    5.693403] WARNING: CPU: 0 PID: 623 at drivers/gpu/drm/drm_atomic_helper.c:1635 drm_atomic_helper_wait_for_vblanks.part.23+0x274/0x290
[    5.717231] Modules linked in: meson_gxl dwmac_generic lima hid_logitech_dj(+) gpu_sched dw_hdmi_i2s_audio dwmac_meson8b rtc_meson_vrtc simpledrm drm_shmem_helper
[    5.743721] CPU: 0 PID: 623 Comm: irq/28-dw_hdmi_ Not tainted 6.1.11-meson64 #23.02.2
[    5.763529] Hardware name: Amlogic Meson GXL (S905W) P281 Development Board (DT)
[    5.783127] pstate: 60000005 (nZCv daif -PAN -UAO -TCO -DIT -SSBS BTYPE=--)
[    5.802271] pc : drm_atomic_helper_wait_for_vblanks.part.23+0x274/0x290
[    5.821299] lr : drm_atomic_helper_wait_for_vblanks.part.23+0x274/0x290
[    5.840179] sp : ffff80000ac93960
[    5.857939] x29: ffff80000ac93960 x28: 0000000000000000 x27: 0000000000000014
[    5.877352] x26: ffff00007af4a800 x25: 0000000000000000 x24: 0000000000000001
[    5.896681] x23: 0000000000000038 x22: 0000000000000001 x21: ffff0000091cf400
[    5.915863] x20: ffff00007af4d080 x19: 0000000000000000 x18: 0000000000000010
[    5.934906] x17: 0000000000000040 x16: 0000000000000000 x15: 000000000000014c
[    5.953744] x14: ffff80000ac93720 x13: 00000000ffffffea x12: ffff80000993b840
[    5.972520] x11: 0000000000000003 x10: 0000000000000001 x9 : ffff800009923858
[    5.991193] x8 : 0000000000017fe8 x7 : c0000000ffffefff x6 : ffff800009923800
[    6.009806] x5 : 0000000000057fa8 x4 : 0000000000000000 x3 : ffff80000ac93718
[    6.028367] x2 : ffff8000098cb750 x1 : c1fc788129109500 x0 : 0000000000000000
[    6.046955] Call trace:
[    6.064029]  drm_atomic_helper_wait_for_vblanks.part.23+0x274/0x290
[    6.081904]  drm_atomic_helper_commit_tail_rpm+0x64/0x80
[    6.099072]  commit_tail+0xa4/0x1a8
[    6.116140]  drm_atomic_helper_commit+0x170/0x188
[    6.133272]  drm_atomic_commit+0x94/0x120
[    6.150312]  drm_client_modeset_commit_atomic.isra.14+0x208/0x278
[    6.167851]  drm_client_modeset_commit_locked+0x60/0x1a0
[    6.184945]  drm_client_modeset_commit+0x30/0x58
[    6.201828]  __drm_fb_helper_restore_fbdev_mode_unlocked+0xcc/0x110
[    6.219351]  drm_fb_helper_set_par+0x3c/0x78
[    6.236194]  drm_fb_helper_hotplug_event.part.33+0x98/0xf8
[    6.253010]  drm_fbdev_client_hotplug+0x3c/0x1b8
[    6.269862]  drm_client_dev_hotplug+0x80/0xe0
[    6.286283]  drm_kms_helper_connector_hotplug_event+0x34/0x48
[    6.302452]  drm_helper_hpd_irq_event+0x120/0x130
[    6.318352]  dw_hdmi_top_thread_irq+0x78/0xa0
[    6.333911]  irq_thread_fn+0x2c/0xa8
[    6.349003]  irq_thread+0x11c/0x220
[    6.363653]  kthread+0x10c/0x118
[    6.377897]  ret_from_fork+0x10/0x20
[    6.391643] ---[ end trace 0000000000000000 ]---
<snip>
[   17.893803] meson-drm d0100000.vpu: [drm] *ERROR* flip_done timed out
[   17.894628] meson-drm d0100000.vpu: [drm] *ERROR* [CRTC:42:meson_crtc] commit wait timed out
[   28.133780] meson-drm d0100000.vpu: [drm] *ERROR* flip_done timed out
[   28.134579] meson-drm d0100000.vpu: [drm] *ERROR* [CONNECTOR:34:HDMI-A-1] commit wait timed out
[   38.373778] meson-drm d0100000.vpu: [drm] *ERROR* flip_done timed out
[   38.374576] meson-drm d0100000.vpu: [drm] *ERROR* [PLANE:36:meson_primary_plane] commit wait timed out
[   38.485778] ------------[ cut here ]------------
[   38.485800] [CRTC:42:meson_crtc] vblank wait timed out
[   38.489921] WARNING: CPU: 3 PID: 734 at drivers/gpu/drm/drm_atomic_helper.c:1635 drm_atomic_helper_wait_for_vblanks.part.23+0x274/0x290
[   38.501923] Modules linked in: hid_logitech_hidpp meson_gxl dwmac_generic lima hid_logitech_dj gpu_sched dw_hdmi_i2s_audio dwmac_meson8b rtc_meson_vrtc simpledrm drm_shmem_helper
[   38.517710] CPU: 3 PID: 734 Comm: plymouthd Tainted: G        W          6.1.11-meson64 #23.02.2
[   38.526418] Hardware name: Amlogic Meson GXL (S905W) P281 Development Board (DT)
[   38.533750] pstate: 60000005 (nZCv daif -PAN -UAO -TCO -DIT -SSBS BTYPE=--)
[   38.540648] pc : drm_atomic_helper_wait_for_vblanks.part.23+0x274/0x290
[   38.547203] lr : drm_atomic_helper_wait_for_vblanks.part.23+0x274/0x290
[   38.553759] sp : ffff800009e0b960
[   38.557036] x29: ffff800009e0b960 x28: 0000000000000000 x27: 0000000000000014
[   38.564109] x26: ffff00007af4a800 x25: 0000000000000000 x24: 0000000000000001
[   38.571181] x23: 0000000000000038 x22: 0000000000000001 x21: ffff00000935ea00
[   38.578253] x20: ffff00007af4d080 x19: 0000000000000000 x18: 0000000000000010
[   38.585326] x17: 00480168027808ca x16: 0882087808ca0870 x15: 0000000000000186
[   38.592398] x14: ffff800009e0b720 x13: 00000000ffffffea x12: ffff80000993b840
[   38.599471] x11: 0000000000000003 x10: 0000000000000001 x9 : ffff800009923858
[   38.606544] x8 : 0000000000017fe8 x7 : c0000000ffffefff x6 : ffff800009923800
[   38.613616] x5 : 0000000000057fa8 x4 : 0000000000000000 x3 : ffff800009e0b718
[   38.620689] x2 : ffff8000098cb750 x1 : c1fc788129109500 x0 : 0000000000000000
[   38.627762] Call trace:
[   38.630178]  drm_atomic_helper_wait_for_vblanks.part.23+0x274/0x290
[   38.636387]  drm_atomic_helper_commit_tail_rpm+0x64/0x80
[   38.641647]  commit_tail+0xa4/0x1a8
[   38.645097]  drm_atomic_helper_commit+0x170/0x188
[   38.649755]  drm_atomic_commit+0x94/0x120
[   38.653723]  drm_atomic_helper_set_config+0xdc/0x118
[   38.658639]  drm_mode_setcrtc+0x194/0x780
[   38.662606]  drm_ioctl_kernel+0xc0/0x178
[   38.666488]  drm_ioctl+0x1fc/0x490
[   38.669851]  __arm64_sys_ioctl+0xa8/0xe8
[   38.673733]  invoke_syscall+0x44/0x108
[   38.677441]  el0_svc_common.constprop.3+0x94/0xf8
[   38.682099]  do_el0_svc+0x2c/0xc8
[   38.685376]  el0_svc+0x20/0x50
[   38.688395]  el0t_64_sync_handler+0x98/0xc0
[   38.692535]  el0t_64_sync+0x170/0x174
[   38.696158] ---[ end trace 0000000000000000 ]---

 

Spoiler
Edited by yopp
Posted

Temporary workaround is to add 

 

drm_kms_helper.edid_firmware=HDMI-A-1:edid/1920x1080.bin video=HDMI-A-1:1920x1080-24@60

 

at the end of `append` in  `extlinux.conf`. 

Video signal now appears after kernel initializes

Posted
1 hour ago, yopp said:

Temporary workaround is to add 

 

drm_kms_helper.edid_firmware=HDMI-A-1:edid/1920x1080.bin video=HDMI-A-1:1920x1080-24@60

 

at the end of `append` in  `extlinux.conf`. 

Video signal now appears after kernel initializes

That makes sense, you at telling the kernel which display settings to use, instead of trying to discover the correct settings for the attached monitor.  I'm curious how you figured this out?  Is there some reference you used, that you could link here for others to read more about how/why this works?

Posted
19 hours ago, SteeMan said:

I'm curious how you figured this out?  Is there some reference you used, that you could link here for others to read more about how/why this works?

 

Pure chance, some random knowledge about HDMI protocol and some googling around 🙂

 

If video output works with other distributions on the same hardware, then it's most likely not a hardware issue. Since it works when OS booted without HDMI and @AlexanderTN said that it worked with FHD display and failed on 2K and my display is 4k and it didn't work, then it might be related to resolution. HDMI-equipped output devices have a feature to exchange information about supported video modes: EDID. So my hypothesis was when HDMI is plugged on boot, then it negotiates resolution that is not supported by GPU. And x96mini support max of FHD. 

I've googled is there a way to force linux kernel to use specific resolution regardless of what EDID presented and boom: there is an `drm_kms_helper.edid_firmware` option exactly for that. 

 

References: 
 

 

I wonder how to fix that in u-boot aml_autoboot script.

 

When Armbian is installed on eMMC, for some reason changes in `/boot` are rolled back after reboot. I've bricked one device by trying to use one of the `armbian-*` scripts (don't remember which one), that offered boot partition update. Not a big deal at this point, I'll try to re-flash some compatible android image using AML Tools later.

 

But still, it would be nice to find a way to fix this in bootloader.

Posted

after I followed the method you said https://forum.armbian.com/topic/26893-problems-installing-on-x96-mini/?do=findComment&comment=161517 I couldn't make changes to extlinux.conf after burning the firmware

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...

Important Information

Terms of Use - Privacy Policy - Guidelines