Jump to content

Efforts to develop firmware for H96 MAX V56 RK3566 8G/64G


Hqnicolas

Recommended Posts

8 hours ago, mvpwar said:

I found the 0x0000A000 is the dtb partition start address of Android image , I want to know your GPT partition table of emmc

You find it!

Nice!

Uboot for 8gb devices are newer

So the loadder use address instead of name 

Just change the GPT address on parameter.txt

I don't have this device to test, but it looks a great start 

Edited by hotnikq
Link to comment
Share on other sites

4 hours ago, hotnikq said:

The GPT parameters you will find on

Parameter.Txt

FIRMWARE_VER: 12.0
MACHINE_MODEL: H96_Max_V56
MACHINE_ID: 007
MANUFACTURER: rockchip
MAGIC: 0x5041524B
ATAG: 0x00200800
MACHINE: rk3566_box
CHECK_MASK: 0x80
PWR_HLD: 0,0,A,0,1
TYPE: EXT4
CMDLINE: console=ttyFIQ0 androidboot.console=ttyFIQ0 root=UUID=c79ae8c4-0a9a-479b-b57f-ed7575bf5017 rw rootfstype=ext4 no_console_suspend consoleblank=0 fsck.fix=yes fsck.repair=yes net.ifnames=0 splash plymouth.ignore-serial-consoles mtdparts=rk29xxnand:0x00002000@0x00004000(security),0x00002000@0x00006000(uboot),0x00002000@0x00008000(trust),-@0x0010800(root:grow)
uuid:root=c79ae8c4-0a9a-479b-b57f-ed7575bf5017

 

this parameter.txt is not useful when the TYPE is EXT4,  Only parameter.txt with GPT type is available, like the parameter.txt of unpacked Android image 

FIRMWARE_VER: 11.0
MACHINE_MODEL: H96_Max_RK3566
MACHINE_ID: 007
MANUFACTURER: rockchip
MAGIC: 0x5041524B
ATAG: 0x00200800
MACHINE: rk356x_box
CHECK_MASK: 0x80
PWR_HLD: 0,0,A,0,1
TYPE: GPT
CMDLINE:mtdparts=rk29xxnand:0x00002000@0x00004000(uboot),0x00002000@0x00006000(trust),0x00002000@0x00008000(misc),0x00002000@0x0000a000(dtbo),0x00000800@0x0000c000(vbmeta),0x00014000@0x0000c800(boot),0x00002000@0x00020800(security),0x00030000@0x00022800(recovery),0x000c0000@0x00052800(backup),0x000d7fff@0x00112800(cache),0x00008000@0x001ea7ff(metadata),0x00000400@0x001f27ff(frp),0x00000800@0x001f2bff(baseparameter),0x00008000@0x001f33ff(logo),0x006b8000@0x001fb3ff(super),-@0x008b33ff(userdata:grow)

 

 I want to know your GPT partition table which outputed by clicking the "Dev Partition" in the RKDevTool 

 

If the box inconvenient to shut down, can you execute the “blkid” command in the shell  @hotnikq

 

the result of my box by clicking the "Dev Partition"  as below

image.png.2bb0744fb1b2b9da7e16549c1fd76cc7.png

Edited by mvpwar
Link to comment
Share on other sites

11 hours ago, mvpwar said:

I want to know your GPT partition table which outputed by clicking the "Dev Partition" in the RKDevTool 



Create an Parameter.txt File like this
 

FIRMWARE_VER: 12.0
MACHINE_MODEL: H96_Max_V56
MACHINE_ID: 007
MANUFACTURER: rockchip
MAGIC: 0x5041524B
ATAG: 0x00200800
MACHINE: rk3566_box
CHECK_MASK: 0x80
PWR_HLD: 0,0,A,0,1
TYPE: EXT4
CMDLINE: console=ttyFIQ0 androidboot.console=ttyFIQ0 root=UUID=c79ae8c4-0a9a-479b-b57f-ed7575bf5017 rw rootfstype=ext4 no_console_suspend consoleblank=0 fsck.fix=yes fsck.repair=yes net.ifnames=0 splash plymouth.ignore-serial-consoles mtdparts=rk29xxnand:0x00002000@0x00004000(uboot),0x00002000@0x00006000(trust),0x00002000@0x00008000(misc),0x00002000@0x0000a000(dtbo),0x00000800@0x0000c000(vbmeta),-@0x0000d000(root:grow)
uuid:root=c79ae8c4-0a9a-479b-b57f-ed7575bf5017

 

 

Extract from your android image 
uboot.img
trust.img
misc.img
dtbo.img
vbmeta.img
and the "root,img" file you pickup from tutorial root image from this topic.

put it all inside image folder on rockdev
on rockdev folder edit the file package-file 

 

# NAME		Relative path
#
#HWDEF		HWDEF
package-file	package-file
bootloader	Image/MiniLoaderAll.bin
parameter	Image/parameter.txt
trust		Image/dtbo.img
uboot		Image/uboot.img
security		Image/parameter.txt
#resource	Image/resource.img
#kernel		Image/kernel.img
root		Image/root.img
#recovery	Image/recovery.img
#rootfs		Image/rootfs.img
#oem		Image/oem.img
#userdata	Image/userdata.img
#backup		RESERVED
#update-script	update-script
#recover-script	recover-script


@mvpwar


This is the 4gb/32gb device

diskcs.jpg.d92992eb5b1dea3bbd927809e5b3c6d4.jpg

 

This is the 4gb/32gb device

diskcs2.jpg.56ea4fec500ee520134613e5b47aa47e.jpg

Edited by hotnikq
Link to comment
Share on other sites

9 hours ago, mvpwar said:

is your 4G/32G box only using the emmc without sd card?

First I add SD card to test the dtb files faster

Then I create the internal flash 2 step

Now I just flash the MMC when I need to clean install

No SD SD card since v0.7 firmware

remembering that you should change only the update.img file that initializes the device 

The root.img contains dtb file that works on both 4gb and 8gb devices

Edited by hotnikq
Link to comment
Share on other sites

11 hours ago, hotnikq said:

remembering that you should change only the update.img file that initializes the device 

The root.img contains dtb file that works on both 4gb and 8gb devices

 

the problem is "Failed to mount ext2 filesystem" or Could not find the partition with the kernel and dtb file @hotnikq

 

BTW, your old ubuntu firmware works, and then I flashed the armbian v0.7 root.img to rootfs partition, armbian works but the kernel and dtb can not be change since it use boot.img and empty /boot dir of root.img

Edited by mvpwar
Link to comment
Share on other sites

package-file

 

# NAME		Relative path
#
#HWDEF		HWDEF
package-file	package-file
bootloader	Image/MiniLoaderAll.bin
parameter	Image/parameter.txt
trust		Image/dtbo.img
uboot		Image/uboot.img
security		Image/parameter.txt
root		Image/root.img

 

parameter.txt

 

FIRMWARE_VER: 11.0
MACHINE_MODEL: H96_Max_RK3566
MACHINE_ID: 007
MANUFACTURER: rockchip
MAGIC: 0x5041524B
ATAG: 0x00200800
MACHINE: rk356x_box
CHECK_MASK: 0x80
PWR_HLD: 0,0,A,0,1
TYPE: EXT4
CMDLINE: console=ttyFIQ0 androidboot.console=ttyFIQ0 root=UUID=614e0000-0000-4b53-8000-1d28000054a9 rw rootfstype=ext4 no_console_suspend consoleblank=0 fsck.fix=yes fsck.repair=yes net.ifnames=0 splash plymouth.ignore-serial-consoles mtdparts=rk29xxnand:0x00002000@0x00004000(security),0x00002000@0x00006000(uboot),0x00002000@0x00008000(trust),-@0x0000a000(root:grow)
uuid:root=614e0000-0000-4b53-8000-1d28000054a9

 

the root.img is Debian_23.08.0-H96MAX_RK3566_bookworm_ROOT_edge_6.2.16_xfce_desktop.img, also try the other root.img, the same result ...

 

start to make update.img...
Android Firmware Package Tool v1.66
------ PACKAGE ------
Add file: ./package-file
Add file: ./package-file done,offset=0x800,size=0xe1,userspace=0x1
Add file: ./Image/MiniLoaderAll.bin
Add file: ./Image/MiniLoaderAll.bin done,offset=0x1000,size=0x6a9c0,userspace=0xd6
Add file: ./Image/parameter.txt
Add file: ./Image/parameter.txt done,offset=0x6c000,size=0x269,userspace=0x1
Add file: ./Image/dtbo.img
Add file: ./Image/dtbo.img done,offset=0x6c800,size=0x26f,userspace=0x1
Add file: ./Image/uboot.img
Add file: ./Image/uboot.img done,offset=0x6d000,size=0x400000,userspace=0x800
Add file: ./Image/parameter.txt
Add file: ./Image/parameter.txt done,offset=0x46d000,size=0x25d,userspace=0x1
Add file: ./Image/root.img
Add file: ./Image/root.img done,offset=0x46d800,size=0x189ff6600,userspace=0x313fed
Add CRC...
Make firmware OK!
------ OK ------
********RKImageMaker ver 1.66********
Generating new image, please wait...
Writing head info...
Writing boot file...
Writing firmware...
Generating MD5 data...
MD5 data generated successfully!
New image generated successfully!
Making ./Image/update.img OK.

 

image.png.2d40afbf1d1dd9e5dd85a54f2621c637.png

what the hell...

Edited by mvpwar
Link to comment
Share on other sites

2 hours ago, mvpwar said:

what the hell...

Welcome to Linux

3 hours ago, mvpwar said:

BTW, your old ubuntu firmware works

My god, you have that old image?

It works on 8gb devices?

Please Share it here with Google drive 

I have deleted it

@Kenneth Hidalgo need your image to 8gb devices

Edited by hotnikq
Link to comment
Share on other sites

2 hours ago, mvpwar said:

works but the kernel and dtb can not be change since it use boot.img and empty /boot dir of root.img

This is a problem?

It's running kernel 6.2? Or the old kernel 4.2?

Edited by hotnikq
Link to comment
Share on other sites

3 minutes ago, hotnikq said:
2 hours ago, mvpwar said:

works but the kernel and dtb can not be change since it use boot.img and empty /boot dir of root.img

This is a problem?

It's running kernel 6.2?

your Ubuntu firmware works, but it's memory is only 4g though the 8g box, flash the armbian root.img to rootfs partition, armbian works, but the kernel is also 4.x , not 6.2 @hotnikq

Link to comment
Share on other sites

maybe i upgrade debian 10.10 firmware and then flash the armbian root.img, my box can run the armbian , 8g ram, but the docker need kernel6.2, the kernel version of this debian firmware is 4.19.193

Edited by mvpwar
Link to comment
Share on other sites

23 minutes ago, hotnikq said:

It's running kernel 6.2? Or the old kernel 4.2?

4.2, I don't know how to change the dtb and kernel , the /boot is empty , maybe the boot.img include kernel and dtb , but i can't unpack the boot.img using bootimg.exe and unpack_bootimg.py @hotnikq

Link to comment
Share on other sites

6 hours ago, mvpwar said:

your Ubuntu firmware works, but it's memory is only 4g though the 8g box, flash the armbian root.img to rootfs partition, armbian works, but the kernel is also 4.x , not 6.2


ah it's to prevent Kernel panic on 4.19

it's my old kernel 😁

we are still at the ground point in this project for 8gb device......

 

20 hours ago, mvpwar said:

I will try your method later


waiting for your patch
i will delete my 8gb update images since your test got an error on uboot
 

9 hours ago, mvpwar said:

the problem is "Failed to mount ext2 filesystem" or Could not find the partition with the kernel and dtb file

 

I'll try again a desperate adaptation

 

Edited by hotnikq
Link to comment
Share on other sites

On 7/3/2023 at 11:59 PM, hotnikq said:
security		Image/parameter.txt

actually the security partition of your box had been flashed the parameter.txt ?

On 7/3/2023 at 11:59 PM, hotnikq said:

 

diskcs2.jpg.56ea4fec500ee520134613e5b47aa47e.jpg

 

and the dtb.img include the root partition uuid of bootargs?

Link to comment
Share on other sites

2 hours ago, hotnikq said:

I'll try again a desperate adaptation


Result:
update.img V4

execute step 1 with V4 update.img
execute step 2 with root.img (from tutorial)
set Address on 0x0000A000
set Name on root


 

update.img V5

execute step 1 with V5 update.img
execute step 2 with root.img (from tutorial)

set Address will be different value "0x00xxxx??????", 
you will need to seach for partition named root
Please share this value if this image works



For update.img V5 i used a different pattern for Linux Pack Firmware

Edited by hotnikq
Link to comment
Share on other sites

3 minutes ago, mvpwar said:

actually the security partition of your box had been flashed the parameter.txt ?

just to bloat the file inside, it works on my 4gb device

 

3 minutes ago, mvpwar said:

and the dtb.img include the root partition uuid of bootargs?

absolutly NOT, it's basically the same original android img file 

Link to comment
Share on other sites

4 hours ago, Kenneth Hidalgo said:

great, I'm desperate for a working OS on h96 max v56

 

You can also test it. I suspect that some steps may have been taken incorrectly,  I'm a bit busy for other things now @Kenneth Hidalgo

 

BTW, do you know the origin of  debian 10 linaro firmware ? link?

Edited by mvpwar
Link to comment
Share on other sites

5 hours ago, hotnikq said:

Please test the V5 and V4 Before another different approach

 

the v4,v5 update.img can't not be read by RKDevTool @hotnikq

image.png.82f8dc3cc23220ea7213c0493da0a087.png

 

I try your rockdev of 8G_Linux_Pack_Firmware.zip , mkupdate.sh can genarate the update.img which can be loaded by RKDevTool,  so the 8G_Linux_Pack_Firmware.zip is correct.  are you using the same 8G_Linux_Pack_Firmware.zip for making image?

 

the command "./rkImageMaker -unpack update.img output " also return the error

 

./rkImageMaker -unpack update.img output

********RKImageMaker ver 1.66********
Unpacking image, please wait...
Error:Check update.img failed!

 

Edited by mvpwar
Link to comment
Share on other sites

44 minutes ago, mvpwar said:

I tried, the rockdev works, but your firmwares get corrupted , you can  check it at your pc

Generating files again....
 

 
Result
Update.img V4 

execute step 1 with V4 update.img
execute step 2 with root.img (from tutorial)
set Address on 0x0000A000
set Name on root


 

Update.img V5

execute step 1 with V5 update.img
execute step 2 with root.img (from tutorial)

set Address will be different value "0x00xxxx??????", 
you will need to seach for partition named root
Please share this value if this image works



For update.img V5 i used a different pattern for Linux Pack Firmware

Edited by hotnikq
Link to comment
Share on other sites

Test Result

 

v4:  failed...

U-Boot 2017.09-g32ed8ff-210328-dirty #pc (Apr 21 2021 - 20:51:20 +0800)

Model: Rockchip RK3568 Evaluation Board
PreSerial: 2, raw, 0xfe660000
DRAM:  7.7 GiB
Sysmem: init
Relocation Offset: ed39f000, fdt: eb9f8e18 
Using default environment

Hotkey: ctrl+`
dwmmc@fe2b0000: 1, dwmmc@fe2c0000: 2, sdhci@fe310000: 0
Bootdev(atags): mmc 0
MMC0: HS200, 200Mhz
PartType: EFI
No misc partition
boot mode: None
FIT: No boot partition
No resource partition
No resource partition
Failed to load DTB
Failed to get kernel dtb, ret=-19
io-domain: OK
Model: Rockchip RK3568 Evaluation Board
rockchip_set_serialno: could not find efuse/otp device
CLK: (sync kernel. arm: enter 816000 KHz, init 816000 KHz, kernel 0N/A)
  apll 816000 KHz
  dpll 390000 KHz
  gpll 1188000 KHz
  cpll 1000000 KHz
  npll 24000 KHz
  vpll 24000 KHz
  hpll 24000 KHz
  ppll 100000 KHz
  armclk 816000 KHz
  aclk_bus 150000 KHz
  pclk_bus 50000 KHz
  aclk_top_high 300000 KHz
  aclk_top_low 200000 KHz
  hclk_top 150000 KHz
  pclk_top 50000 KHz
  aclk_perimid 300000 KHz
  hclk_perimid 150000 KHz
  pclk_pmu 50000 KHz
Net:   No ethernet found.
Hit key to stop autoboot('CTRL+C'):  0 
## Booting FIT Image FIT: No boot partition
FIT: No FIT image
Could not find misc partition
ANDROID: reboot reason: "(none)"
optee api revision: 2.0
TEEC: Reset area[0] info...
TEEC: Reset area[1] info...
Not AVB images, AVB skip
android_image_load_by_partname: Can't find part: boot
Android image load failed
Android boot failed, error -1.
MMC error: The cmd index is 1, ret is -110
Card did not respond to voltage select!
mmc_init: -95, time 10
switch to partitions #0, OK
mmc0(part 0) is current device
Failed to mount ext2 filesystem...
** Unrecognized filesystem type **
starting USB...
Bus dwc3@fcc00000: usb maximum-speed not found
Register 2000140 NbrPorts 2
Starting the controller
USB XHCI 1.10
Bus dwc3@fd000000: usb maximum-speed not found
Register 2000140 NbrPorts 2
Starting the controller
USB XHCI 1.10
scanning bus dwc3@fcc00000 for devices... 1 USB Device(s) found
scanning bus dwc3@fd000000 for devices... 1 USB Device(s) found
       scanning usb for storage devices... 0 Storage Device(s) found

Device 0: unknown device
No ethernet found.
missing environment variable: pxeuuid
missing environment variable: bootfile
Retrieving file: pxelinux.cfg/00000000
No ethernet found.
missing environment variable: bootfile
Retrieving file: pxelinux.cfg/0000000
No ethernet found.
missing environment variable: bootfile
Retrieving file: pxelinux.cfg/000000
No ethernet found.
missing environment variable: bootfile
Retrieving file: pxelinux.cfg/00000
No ethernet found.
missing environment variable: bootfile
Retrieving file: pxelinux.cfg/0000
No ethernet found.
missing environment variable: bootfile
Retrieving file: pxelinux.cfg/000
No ethernet found.
missing environment variable: bootfile
Retrieving file: pxelinux.cfg/00
No ethernet found.
missing environment variable: bootfile
Retrieving file: pxelinux.cfg/0
No ethernet found.
missing environment variable: bootfile
Retrieving file: pxelinux.cfg/default-arm-rockchip
No ethernet found.
missing environment variable: bootfile
Retrieving file: pxelinux.cfg/default-arm
No ethernet found.
missing environment variable: bootfile
Retrieving file: pxelinux.cfg/default
No ethernet found.
Config file not found
No ethernet found.
No ethernet found.

v5:  failed ... the same problem @hotnikq

Edited by mvpwar
Link to comment
Share on other sites

Just now, hotnikq said:

what is the address that you flash the root.img partition on tutorial part 2?

 the same 0x0000A000 ,since the v5 update.img would not change the GPT partition

 

when i unpace the v5 update.img , the TYPE of parameter.txt is EXT4, which would cause the partition table  keep the same @hotnikq

Link to comment
Share on other sites

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