adamfowleruk / deskpi-super6c

A repo to hold useful information and files for my exploration of the DeskPi Super6C CM4 carrier board
Apache License 2.0
17 stars 0 forks source link

Board boots Debian with cm4 io board dtb #2

Open PBXForums opened 2 years ago

PBXForums commented 2 years ago

I just thought I would try putting a module in that I had in the cm4 board.

It boots just fine in Debian and I can see the NVME too.

Just thought I would let you know.

Also, I'm just realzing, there is no way to hook up a serial device to this for debugging??

tcdude commented 2 years ago

I have successfully booted the Manjaro image from Friday and I saw the NVMe too at that point. I wasn't able to move the root partition to the NVMe though, even after putting the PCIe module into extlinux.conf though.

What also still doesn't work (at least for me with that image) is rebooting the board. I need to force it off by press and holding the power button on the board and press again to start normal boot, which is sort of a deal breaker for me, given that I really don't want to kill power to all 6 modules.

By cm4 board, do you mean the official cm4io board? Do you have an eMMC chip on your module? Because on that I'm currently struggling with the SD card to be recognized.

And yes, no UART on for any of the 6 modules is quite the oversight IMHO..

Just to make sure, we are talking about the soquartz module here, right? If so, could you please link that Debian image here so I can test that and have another DT to compare to what we have now?

PBXForums commented 2 years ago

@tcdude I manually built the debian, I think I can probably reboot just fine. I'm working right now so can't test until later. I have my image on the emmc, I haven't tried SD.

I will try all this later and update you, also I'll make an image, I'm using partuuid in the extlinux.conf so it boots of sd or emmc and yes I'm referring to the soquartz board and the dts for the soquartz with cm4-io board.

PBXForums commented 2 years ago

Just ran out of time, that nasty work again!

This should do you for now though: https://www.t95plus.com/forums/downloads/armbian-bullesye-soquartz-cm4-io.img.gz

It should boot off sd or emmc.

ssh with user root and password 1234

After first login please immediately type reboot.

After rebooting you will have a new MAC address and a new IP.

This is so if you have multiple boards they all get individual MACs. Without this they all have the same MAC.

PBXForums commented 2 years ago

I have no idea why but it took a couple of reboots to get all 4 nvme showing, they got there in the end, two came up first time with it, two without, all good now though:

root@soquartz-4:~# lspci
00:00.0 PCI bridge: Fuzhou Rockchip Electronics Co., Ltd Device 3566 (rev 01)
01:00.0 Non-Volatile memory controller: Kingston Technology Company, Inc. Device 500f (rev 03)
tcdude commented 2 years ago

I'm unable to boot that image from the SD card.. from the serial output I get it looks like a similar problem that I encountered with the Manjaro image.. I ordered eMMC for testing, but that could still take a while until I get those. In the mean time I'm trying to figure out why the cm4io board doesn't like being booted from SD card...

PBXForums commented 2 years ago

I haven't tried it with SD card on the super6c only emmc. It works fine with that, I have 4 running now and have reflashed them multiple times

Is this the official cm4io board you are using? I have 100% booted this image on there from SD?

PBXForums commented 2 years ago

From u-boot interrupt it with ctrl-c or whatever

You should be able to do something like mmc list to get a list of sd/emmc etc

This is from memory as I'm not home right now.

Then select your device with mmc dev X where X is device number

Then mmc part should give you a list of partitions...

Regardless, you want to boot on that image from partition 4 so you can try

sysboot mmc 0:4 any 0x8000 /boot/extlinux/extlinux.conf

or

sysboot mmc 1:4 any 0x8000 /boot/extlinux/extlinux.conf

That any and 0x8000 may be the wrong way round, just type sysboot on its own, it will give you a syntax example.

I would expect one of those two commands to boot it.

tcdude commented 2 years ago

I haven't tried it with SD card on the super6c only emmc. It works fine with that, I have 4 running now and have reflashed them multiple times

Is this the official cm4io board you are using? I have 100% booted this image on there from SD?

On the super6c I had no troubles with booting from SD.. this only happens on the official cm4io board...

I'm currently trying all my SD cards I have to rule out broken/bugged cards. I will also try to interrupt u-boot and give sysboot a try.

PBXForums commented 2 years ago

I'm away for a week now but 100% that image booted from SD on the official cm4 io board

tcdude commented 2 years ago

So it did boot after trying out 4 other SD cards I finally landed on one that worked. Strange that I either have a bunch of bad SD cards or the board is really picky in that regard. Anyways, thanks a bunch.

With your image I can now also reboot the module w/o problem and I saw the NVMe drive every boot so far.

Could you maybe give some more information about the kernel config, dts, patches you used/applied to build this image once you get back?

remy415 commented 2 years ago

I'm not new to SBCs but I'm new to CM4...have you ruled out power issues? SBCs tend not to read NVMe when they don't have enough power (usually caused by deficient power bricks or low-quality USB cables), just curious if it works the same way with these.

tcdude commented 2 years ago

I think I can safely rule out power issues on my side in terms of power brick and cable. Both the CM4IO and the Super6C get their power through a barrel jack and the power bricks I've used deliver more than enough power than a single module plus an NVMe could draw even at peak.

Also, I haven't had any problems with the NVMe drive after getting @PBXForums image to run. The main issue that remains, for me at least is the SD card, where I've only managed to boot with 2 out of 11 cards I tested so far.

PBXForums commented 2 years ago

These are the exact brand I have been using without issue.

https://www.amazon.co.uk/gp/product/B08GY9NYRM

With regards to power, I have four soquartz in my Super6c with 4 NVME, all poodling along quite nicely now.

tcdude commented 2 years ago

Funny, this is exactly one of the two I have that work..

I specifically ordered 6 of these:

https://www.kingston.com/en/memory-cards/canvas-select-plus-microsd-card

which don't work at all on the CM4IO board but work when booting the Manjaro image on the Super6c board. (I did not try to boot the armbian image directly on the Super6c with that model of SD card)

adamfowleruk commented 2 years ago

This is great progress, thanks all! I'll be looking at this again tonight and see what I can coax out of the bootloader trying to boot my custom image. I suspect it's a boot image modification issue that'll be fixed once I convince the build recipe to use the soquartz-super6c dts instead of the soquartz-cm4 as it does by default. Any manual changes to extlinux.conf on the emmc seems to immediately cause the device to not boot. Reflashing to a saved (.img on my mac) version that uses the soquartz-cm4 version boots just fine. I'll double check the config tonight, rebuild with this as the default option, and see where I end up.

adamfowleruk commented 2 years ago

Yeah my attempts failed. Now got hold of an RPi CM4 lite but that's not booting either. Ordered a CM4 IO board to work on that. Once booting there I'll transfer to the Super6C, complete the new DTS work using PiOS, then take that now-working DTS and get a Manjaro full build working with it. That's the current plan anyway.

PBXForums commented 2 years ago

Just managed to get the balbes150 ubuntu current image working.

It wasn't straightforward but they will probably be much better images, more to follow:

root@quartz64a:~# uname -a
Linux quartz64a 5.19.7-station-p2 #trunk SMP PREEMPT Mon Sep 5 13:11:27 UTC 2022 aarch64 aarch64 aarch64 GNU/Linux
root@quartz64a:~# cat /etc/issue
Armbian 22.11.0-trunk Jammy \l
PBXForums commented 2 years ago

This image should be much better, I have tested on emmc and sdcard on cm4 io board only. No reason to thing it won't work on super6c

Its the balbes150 image just with a different u-boot and dtb

Boot up you module, give it a couple of minutes to resize sdcard/emmc and then find its IP

Log in via SSH root/1234 and it will take you through the armbian first boot process.

https://www.t95plus.com/forums/downloads/Armbian_22.11.0-trunk_soquartz_jammy_current_5.19.7.img.gz

PBXForums commented 2 years ago

USB works on the Super6C with that latest version I just posted above. The DTB was updated last night.

[ 3596.201031] usb 1-1.3: new high-speed USB device number 3 using xhci-hcd
[ 3596.402896] usb 1-1.3: New USB device found, idVendor=0781, idProduct=5575, bcdDevice= 1.00
[ 3596.402959] usb 1-1.3: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[ 3596.402987] usb 1-1.3: Product: Cruzer Glide
[ 3596.403009] usb 1-1.3: Manufacturer: SanDisk
[ 3596.403031] usb 1-1.3: SerialNumber: 4C530599951201114092
[ 3596.414291] usb-storage 1-1.3:1.0: USB Mass Storage device detected
[ 3596.416227] scsi host0: usb-storage 1-1.3:1.0
[ 3596.474494] usbcore: registered new interface driver uas
[ 3597.439276] scsi 0:0:0:0: Direct-Access     SanDisk  Cruzer Glide     1.00 PQ: 0 ANSI: 6
[ 3597.442876] sd 0:0:0:0: Attached scsi generic sg0 type 0
[ 3597.444878] sd 0:0:0:0: [sda] 30605312 512-byte logical blocks: (15.7 GB/14.6 GiB)
[ 3597.446591] sd 0:0:0:0: [sda] Write Protect is off
[ 3597.446646] sd 0:0:0:0: [sda] Mode Sense: 43 00 00 00
[ 3597.447896] sd 0:0:0:0: [sda] Write cache: disabled, read cache: enabled, doesn't support DPO or FUA
[ 3597.465767]  sda: sda1
[ 3597.468164] sd 0:0:0:0: [sda] Attached SCSI removable disk

Also NVME working fine:

root@soquartz-1:~# lspci
00:00.0 PCI bridge: Rockchip Electronics Co., Ltd RK3568 Remote Signal Processor (rev 01)
01:00.0 Non-Volatile memory controller: Kingston Technology Company, Inc. Device 500f (rev 03)

Oh, and also, though I have disabled mine, WIFI is working.

PBXForums commented 1 year ago

Using the above image will boot on most boards.

jaymcd commented 1 year ago

does hdmi or a csi display work with this image ?

jaymcd commented 1 year ago

This image should be much better, I have tested on emmc and sdcard on cm4 io board only. No reason to thing it won't work on super6c

Its the balbes150 image just with a different u-boot and dtb

Boot up you module, give it a couple of minutes to resize sdcard/emmc and then find its IP

Log in via SSH root/1234 and it will take you through the armbian first boot process.

https://www.t95plus.com/forums/downloads/Armbian_22.11.0-trunk_soquartz_jammy_current_5.19.7.img.gz

I cannot seem to get HMDI working on this with a BigtreeTech PAD 5. Also anyone get a DSI screen working?

tcdude commented 1 year ago

@ndmgrphc I played around with the dtb to try and get the SD card working. I was successful with a tiny subset of all the SD cards I had available but no change to the device tree would enable me to use all cards I have. I gave up for now and got eMMC modules to use as boot drive instead, which work reliably. Sorry, got no better news than that for now...

moosepr commented 1 year ago

I have just got this image to boot using the official cm4 i/o board and an SD card

has anyone tried NVME boot?