Open mcerveny opened 3 years ago
Thanks, that confirms what we observed from another users that there are at least two different PS5000 revisions. We need to find an easy way to identify which model is which before the flash takes place. Most likely by running a PL command with android tools to check the memory address of each partition.
Also, some users with that RevB model (the one with user data at 0x0002b000) that flashed the userdata with our install script seem to have a corrupted userdata partition that does not flash cleanly. While that can be easily solved at Linux level, it’s not so clear how to automate the recovery of the corrupted partition via command line on windows. It seems it may require the users to run rkdevtool or a similar rock chip tool.
More questions:
Updated PS5000 uses (unknown) kernel 4.4.159 (I tested, that works with your rootfs image - rootfs_ps5000_20210806.img
).
I tried to use this buildroot repo, but I have two problems:
1) where are the sources to your modified kernel - configs/ps5000_defconfig: BR2_LINUX_KERNEL_CUSTOM_REPO_URL="file://$(TOPDIR)/../kernel"
(including dts/dtsi to enable serial console in your dtb) ?
2) where are the scripts to compose boot_ps5000_20210806.img
?
3) where are the scripts to split/build userdata_ps5000_20210806.img
and sdcard/*
?
For the kernel you only need the standard Linux kernel sources for 4.4.159. Just uncompress and create a symbolic link named kernel (one level above buildroot).
The boot is just a reconstituted boot from a dump of the internal firmware. It just includes the kernel image and the associated dtd’s. We will document how to do it in the future but it’s not relevant for this device.
The userdata does not need to contain anything other than a run and system folder. Run is mount binded to the chroot system upon boot. This is needed to obtain read/write permissions for udev population. System is basically a link to /mnt/sdcard so the default home is set to /userdata/system. We have not documented this but will do in the future. There are no scripts to roll do this currently but it’s just two folders to be added to an otherwise empty partition.
standard Linux kernel sources for 4.4.159
Nope. Standard Linux sources does not contain drivers "mali", "rkflash", "hevc_service", "vpu_service" ... Only https://github.com/rockchip-linux/kernel (synchronized to 4.4.194 now) and other forks. So if you distribute kernel binaries you should also disclosure your equivalent kernel sources. Do you known to HW/SW author (maybe somewhere https://github.com/rockchip-linux/kernel/network/members ) ?
Yes and no. For the kernel link that you need to build just rootfs you don’t need the modified kernel sources with rockchip specific patches.
However, you are correct that to get those rockchip specific kernel modifications you need to compile the kernel you need those modified sources from rockchip Linux, same repo as you point out (https://github.com/rockchip-linux/kernel). Our rootfs only requires a loop module to be compiled from the kernel, and that’s a general Linux module that does not require any of the rockchip modifications.
Same applies to rkscript, Linux-rga, Mali (specific rockchip flavor), etc. You can find a more up to date repo of all those in the Caesar Wang repo (https://github.com/Caesar-github), he’s one of the main rockchip contributors. The origin of the buildroot that we use comes from a blend between Caesars buildroot modifications to the main rockchip Linux buildroot, plus additional modifications based on batocera.Linux buildroot.
In any case, our current goal is to document everything, but time is limited. You are welcomed to create any pull requests and contribute to the project.
Please simply clarify (ps5000 is WX8 board):
Very thanks, Martin
Please simply clarify (ps5000 is WX8 board):
- yes/no - there is pcb schema for this WX8_V01/ 20200930 board.
No, at least I don’t have it.
yes/no - u-boot (based on rockchip-linux||caesar-github 2017-09 or upstream) build is done. There are sources of u-boot that are applicable to this board:
- configs/rk3128_ps5000_defconfig
- board/rockchip/ps5000_rk3128/*
- arch/arm/dts/rk3128-ps5000.dts
No. There is a defconfig for building the rootfs and a hierarchy of overlays for the specific consoles supported: a12/a13 and ps5000. The dts for ps5000 is not modified by the cfw, should be the same provided by the seller.
yes/no - linux (based on rockchip-linux||caesar-github 4.4 or 4.16 or upstream) build is done. There are sources of linux that are applicable to this board:
- arch/arm/configs/rockchip_ps5000_defconfig
- arch/arm/boot/dts/rk3128-ps5000.dts
No. As above, for the time being we only build the rootfs for ps5000.
Very thanks, Martin
Thanks for your interest!
And now the long story: we want to move to batocera to get a cleaner and more compatible environment. We are in the process. Another goal is building the whole system from scratch.
Regarding documentation, we want to add instructions to unpack (and repack) the boot partition so anyone is able to extract the dts. The sources of the official firmware are not being distributed by the seller, at least not to us, so the most we can provide are the steps to get the dts from the original partition. The only modification we do over the original boot partition for ps5000 is the splash screen to add version information and easily identify what the user flashed in case they are not skilled enough.
And now the longer story: we made the decision of distributing the boot image even though we didn’t get access to the sources because the seller of powkiddy a12/a13 devices introduced a modification in the dts to reset the device if you try to boot with a different rootfs. Thus, in those devices you need a modified dts to "free" the device.
Until we get stuff documented, the tools you can use to unpack/repack the boot partition are 7z and imageRePackerRK.
Best, Alberto.
Of course if you are able to compile a working full system for the ps5000 we will be more than happy to get rid of the OFW boot. We are focused on moving to batocera to ease the compilation process, so the full system build is still a later step for us, definitely something we want to achieve.
Thanks for clarification.
I am capable to work with lowlevel RK tools (ASUS Tinker, PINE ROCK64 ...) like u-boot/tools/, rkbin/, build/mk_uboot.sh|mk_image.sh. But I have serious problems to replicate working u-boot (with SDcard support) (dtb/dtc already extracted from vendor image and manually created some initial dts). Get many errors from close-sourced loader (Boot1 Release Time: Nov 6 2018 21:30:48, version: 2.54) and hung recompiled u-boot :-(
I've not tried on this device yet, but I got a working u-boot for the A12 before. The issue there was not the u-boot but the kernel, even with the extracted KCONFIG from the OFW kernel the kernel was not working and something failed (probably display init).
There's another developer trying to get the PS5000 to boot off an SDCARD, I'll post an update if I hear back.
Duplicate #53
I tried to rebuild u-boot with SDCARD support but I failed. I used caesar-u-boot. I cleaned and enabled all needed stuff (see my WIP branch).
Problems:
MIPI_DCS_GET_PIXEL_FORMAT
, MIPI_DCS_GET_DIAGNOSTIC_RESULT
, MIPI_DCS_GET_POWER_MODE
))
rockchip,rk3128-mipi-dphy
was removed from sourcesrockchip,rk3128-video-phy
is multioutput capable (MIPI, LVDS, RGB)
-> maybe new driver is untested and/or bad, maybe some unpublished initialization in "U-Boot 2017.09-gf468676-dirty (Jul 08 2021 - 10:53:40 +0800)"dmesg
shows crash stacks and errors about IRQ:
[ 2.398056] irq 35: nobody cared (try booting with the "irqpoll" option)
[ 2.398065] CPU: 0 PID: 85 Comm: vendor_storage_ Not tainted 4.4.159 #1047
[ 2.398067] Hardware name: Generic DT based system
[ 2.398099] [<c010dabc>] (unwind_backtrace) from [<c010a86c>] (show_stack+0x10/0x14)
[ 2.398111] [<c010a86c>] (show_stack) from [<c032b8a8>] (dump_stack+0x7c/0x98)
[ 2.398122] [<c032b8a8>] (dump_stack) from [<c01643c8>] (__report_bad_irq+0x24/0xc0)
[ 2.398132] [<c01643c8>] (__report_bad_irq) from [<c01646b8>] (note_interrupt+0x190/0x28c)
[ 2.398140] [<c01646b8>] (note_interrupt) from [<c0161fe4>] (handle_irq_event_percpu+0x50/0x128)
[ 2.398149] [<c0161fe4>] (handle_irq_event_percpu) from [<c01620f4>] (handle_irq_event+0x38/0x5c)
[ 2.398156] [<c01620f4>] (handle_irq_event) from [<c016524c>] (handle_fasteoi_irq+0xb0/0x124)
[ 2.398165] [<c016524c>] (handle_fasteoi_irq) from [<c0161754>] (generic_handle_irq+0x18/0x28)
[ 2.398172] [<c0161754>] (generic_handle_irq) from [<c0161a38>] (__handle_domain_irq+0xa0/0xb4)
[ 2.398180] [<c0161a38>] (__handle_domain_irq) from [<c01013f8>] (gic_handle_irq+0x50/0x94)
[ 2.398188] [<c01013f8>] (gic_handle_irq) from [<c010b194>] (__irq_svc+0x54/0x70)
[ 2.398191] Exception stack(0xde7e3d40 to 0xde7e3d88)
[ 2.398199] 3d40: 00000000 00208040 00000000 00000000 de7e2000 00000000 00000002 c0b3d940
[ 2.398207] 3d60: 0000000a 00000034 c0b3f7c8 de7e3d90 00000000 de7e3d90 c011cca8 c01014a8
[ 2.398211] 3d80: 60000113 ffffffff
[ 2.398218] [<c010b194>] (__irq_svc) from [<c01014a8>] (__do_softirq+0x68/0x200)
[ 2.398228] [<c01014a8>] (__do_softirq) from [<c011cca8>] (irq_exit+0x88/0xf4)
[ 2.398236] [<c011cca8>] (irq_exit) from [<c0161a18>] (__handle_domain_irq+0x80/0xb4)
[ 2.398243] [<c0161a18>] (__handle_domain_irq) from [<c01013f8>] (gic_handle_irq+0x50/0x94)
[ 2.398250] [<c01013f8>] (gic_handle_irq) from [<c010b194>] (__irq_svc+0x54/0x70)
[ 2.398253] Exception stack(0xde7e3e10 to 0xde7e3e58)
[ 2.398259] 3e00: 00000000 de6f0e80 00000000 60000013
[ 2.398266] 3e20: c0b3f7c8 c0b40108 00000000 00000000 c0b4888c 00000034 c0b3f7c8 c0b0a1ec
[ 2.398272] 3e40: 0000000f de7e3e60 c015efe0 c0160744 60000013 ffffffff
[ 2.398283] [<c010b194>] (__irq_svc) from [<c0160744>] (console_unlock+0x330/0x3ec)
[ 2.398293] [<c0160744>] (console_unlock) from [<c0160b40>] (vprintk_emit+0x340/0x48c)
[ 2.398302] [<c0160b40>] (vprintk_emit) from [<c0160da0>] (vprintk_default+0x1c/0x24)
[ 2.398314] [<c0160da0>] (vprintk_default) from [<c01a60f0>] (printk+0x28/0x3c)
[ 2.398327] [<c01a60f0>] (printk) from [<c0382a4c>] (vendor_init_thread+0x14/0x134)
[ 2.398338] [<c0382a4c>] (vendor_init_thread) from [<c0131b44>] (kthread+0xf4/0x104)
[ 2.398347] [<c0131b44>] (kthread) from [<c0106c28>] (ret_from_fork+0x14/0x2c)
[ 2.398349] handlers:
[ 2.398360] [<c03f327c>] vop_isr
[ 2.398362] Disabling IRQ #35
and
[ 6.280125] rockchip-vop 1010e000.vop: [drm:vop_wait_for_irq_handler] *ERROR* VOP vblank IRQ stuck for 10 ms
-> kernel original dts/dtb and rockchip drivers are buggy (some rockchip,grf
nodes missing... repaired but not better) and depends on some u-boot initialization, maybe some unpublished initialization
Please publish yours success / progress.
funny note: after reboot from running linux back to u-boot it starts display and show splash image (but with some corruption, same with testing images with u-boot rockchip_show_bmp logo_kernel.bmp
or rockchip_show_bmp logo_lowpower.bmp
...)
sad note: Aliexperess distributor refused to publish GPL sources and original designer ?"Shenzhen Sunchip Technology Co., Ltd."? did not respond. So there are candidates to report GPL violations.
some build notes:
cu -l /dev/ttyUSB0 -s 115200 -f
# ./Linux_Upgrade_Tool_v1.65/upgrade_tool pl
Program Data in /space/ps5000/Linux_Upgrade_Tool_v1.65
Partition Info(gpt):
NO LBA Size Name
01 0x00002000 0x00000800 uboot
02 0x00002800 0x00001000 trust
03 0x00003800 0x00004800 boot
04 0x00008000 0x00023000 rootfs
05 0x0002b000 0x0000addf userdata
# ./Linux_Upgrade_Tool_v1.65/upgrade_tool rl 0x00002000 0x00000800 uboot_backup.img
Program Data in /space/ps5000/Linux_Upgrade_Tool_v1.65
Read LBA from file 100%)
# ### verify "LOADER" tag
# dd if=uboot_backup.img bs=1 count=8 2>/dev/null
LOADER
$ export CHIP="rk3128"
$ export ARCH=arm
$ export CROSS_COMPILE=arm-linux-gnueabihf-
$ make wx8-rk3128_defconfig
...
$ make -j4
...
$ ls -l ls -l u-boot-dtb.bin
-rw-rw-r-- 1 martin martin 799197 Aug 31 08:21 u-boot-dtb.bin
# UBOOT=caesar-u-boot
# RKBIN=caesar-rkbin
# ### image is ~800kB and only ONE copy can fit 1MB uboot partition
# $UBOOT/tools/loaderimage --pack --uboot $UBOOT/u-boot-dtb.bin uboot.img --size 1024 1
# ### upload if in "loader" mode, BEAWARE "loader" mode key does not work after upgrade, you must stop new uboot with "CTRL-C" and enter to loader mode with u-boot command "=> rockusb 0 spinand 0"
# ./Linux_Upgrade_Tool_v1.65/upgrade_tool wl 0x00002000 uboot.img
# ### reset device ... (also CTRL-C and "=> reset" or start kernel with "=> boot_android spinand 0"
Thanks for the update @mcerveny , very good and detailed notes.
Not much progress here, actually the opposite, I tried to compile u-boot again yesterday and after a couple of tests and flashing different combinations I ended up with a (hopefully) soft-bricked PS5000. It's currently in MSC mode (as opposed to the normal MASKROM & LOADER modes).
Note: just re-read your updated notes, about the LOADER mode and using CTRL-C. I tried to do that, for some reason it's not working for me, I don't seem to be able to send any key codes to the screen session. will try again tomorrow
I'll get back to try once I figure out a way to switch back from MSC to LOADER/MASKROM. I've been focused on trying to get the system to boot from the SD card. The closest I got to something in that direction is this:
DDR Version 2.09 20181106 dbg uart0
In
ID:0xFFF
1A1A1B1A 3
DDR3
282C1B1A 3
39391B1A 3
Bus Width=16 Col=10 Bank=8 Row=15 CS=1 Die Bus-Width=16 Size=512MB
mach:9
OUT
Boot1 Release Time: Nov 6 2018 21:30:48, version: 2.54
ChipType = 0xa, 348
sfc_nand_init
sfc_nand id: ef aa 21
sfc_nand A0 = 0x0
sfc_nand B0 = 0x18
sfc_nand C0 = 0x2
read_lines = 2
prog_lines = 2
page_read_cmd = 6b
page_prog_cmd = 32
SFTL version: 5.0.48 20181009
mmc0:cmd5,20
SdmmcInit=0 0
BootCapSize=0
UserCapSize=29818MB
FwPartOffset=2000 , 0
run on sd0
StorageInit ok = 263130
GPT 0x632d7e00 signature is wrong
recovery gpt...
GPT: header_lba incorrect: 3A3CFFF
recovery gpt fail!
tag:LOADER error,addr:0x2000
hdr 632d77e0 + 0x0:0xfbf2e44d,0x895ef6d0,0x1feaa17d,0x1c01be61,
tag:LOADER error,addr:0x4000
hdr 632d77e0 + 0x0:0x50,0xfa,0x11,0xb4,0x5f,0x78,0x09,0xe8,0x42,0x9e,0x9b,0x5c,0xcb,0xe4,0x31,0x78,
Note the "run on sd0" mention. However all my efforts have resulted on what the system considers a GPT corrupted partition, and none of the actual SD card partitions are being read.
Some additional resource that may be helpful for your efforts: https://github.com/hyperkin-game/hyperkin-gb
The repo includes all the required elements to build a full sd image from scratch.
Additional update: Managed to recover the PS5000 from the MSC mode after flashing a SDcard with the correct partitions:
sudo dd if=idbloader-sdcard.img of=/dev/sdb seek=64 conv=sync,fsync
sudo dd if=uboot.img of=/dev/sdb seek=16384 conv=sync,fsync
sudo dd if=trust.img of=/dev/sdb seek=24576 conv=sync,fsync
sudo dd if=boot.img of=/dev/sdb seek=32768 conv=sync,fsync
sudo dd if=rootfs.img of=/dev/sdb seek=262144 conv=sync,fsync
Using the uboot compiled from @mcerveny sources, I was able to get to the autoboot prompt, press CTRL+C to stop and then enter rockusb 0 spinand 0
as Martin described above to get back to LOADER mode and flash my full backup image with upgrade_tool wl 0x0 backup.img
The most important thing si that the SD card that I created seems to work to get the system to boot directly. Still the partitions are not pointing to the right place and after loading the uboot the system looks for the rest of the partitions from the internal memory.
Note: idbloader_sdcard was generated with: u-boot/tools/mkimage -n rk3128 -T rksd -d rk3128_ddr_300MHz_v2.09_uart0_20181106.bin ./idbloader-sdcard.img
The script to generate it can be found on the hyperkin-gb repo
Yes. SDcard is u-boot bootable. My script (for .img or direct to /dev/sdc):
#!/bin/bash -exv
LOCALPATH=$(pwd)
UBOOT=caesar-u-boot
RKBIN=caesar-rkbin
CHIP="rk3128"
LOADER1_START=64
UBOOT_START=16384
TRUST_START=$(($UBOOT_START + 8192))
BOOT_START=$(($TRUST_START + 8192))
ROOTFS_START=$(($BOOT_START + 18432))
USERDATA_START=$(($ROOTFS_START + 143360))
if [ x"$1" = "x" ]; then
SIZE=220672
SYSTEM=system.img
dd if=/dev/zero of=${SYSTEM} count=0 seek=$SIZE
else
SYSTEM=/dev/sdc
for i in ${SYSTEM}[1-9]; do umount $i || true; done
dd if=/dev/zero of=${SYSTEM} bs=1M count=$(( $ROOTFS_START / 2 / 1024 + 1)) conv=sync
partprobe
fi
echo "Generate System image : ${SYSTEM} !"
parted -s ${SYSTEM} mklabel gpt
parted -s ${SYSTEM} unit s mkpart uboot ${UBOOT_START} $(( ${TRUST_START} - 1))
parted -s ${SYSTEM} unit s mkpart trust ${TRUST_START} $(( ${BOOT_START} - 1))
parted -s ${SYSTEM} unit s mkpart boot ${BOOT_START} $(( ${ROOTFS_START} - 1))
parted -s ${SYSTEM} set 3 boot on
parted -s ${SYSTEM} unit s mkpart rootfs ${ROOTFS_START} $(( ${USERDATA_START} - 1))
parted -s ${SYSTEM} -- unit s mkpart userdata ${USERDATA_START} -64s
partprobe
ROOT_UUID="614e0000-0000-4b53-8000-1d28000054a9"
gdisk ${SYSTEM} <<EOF
x
c
4
${ROOT_UUID}
w
y
EOF
# OMG, in some rockchip scripts, what is this:
#dd if=$RKBIN/bin/rk31/rk3128_ddr_300MHz_v2.12.bin of=DDRTEMP bs=4 skip=1
#$UBOOT/tools/mkimage -n rk3128 -T rksd -d DDRTEMP idbloader.img
$UBOOT/tools/mkimage -n rk3128 -T rksd -d $RKBIN/bin/rk31/rk3128_ddr_300MHz_v2.12.bin idbloader.img
cat $RKBIN/bin/rk31/rk3128x_miniloader_v2.57.bin >> idbloader.img
# 8192s -> 4MB -> 4 copies
$UBOOT/tools/loaderimage --pack --uboot $UBOOT/u-boot-dtb.bin uboot.img --size 1024 4
$UBOOT/tools/loaderimage --pack --trustos $RKBIN/bin/rk31/rk3126_tee_ta_v2.01.bin trust.img --size 1024 4
dd if=idbloader.img of=${SYSTEM} seek=${LOADER1_START} conv=notrunc,sync
dd if=uboot.img of=${SYSTEM} seek=${UBOOT_START} conv=notrunc,sync
dd if=trust.img of=${SYSTEM} seek=${TRUST_START} conv=notrunc,sync
dd if=boot.img of=${SYSTEM} conv=notrunc,sync seek=${BOOT_START}
dd if=rootfs.img of=${SYSTEM} conv=notrunc,sync seek=${ROOTFS_START}
But the problems persist. Not able to boot from sdcard (mmc dev 1
):
=> mmc dev 1
MMC error: The cmd index is 13, ret is -22
MMC error: The cmd index is 13, ret is -110
MMC error: The cmd index is 13, ret is -110
MMC error: The cmd index is 13, ret is -110
mmc_init: -110, time 27
I used spinand boot and rebooted from linux (not power on/off):
=> boot_android spinand 0
Could not find misc partition
ANDROID: reboot reason: "(none)"
Not AVB images, AVB skip
Kernel image @ 0x7be0d768 [ 0x000000 - 0x3dadf8 ]
DTB: rk-kernel.dtb
HASH(s): OK
Booting ZIMAGE kernel at 0x62008000(Uncompress to 0x60000000) with fdt at 0x68300000...
Fdt Ramdisk skip relocation
## Booting Android Image at 0x62007800 ...
Kernel load addr 0x62008000 size 3948 KiB
## Flattened Device Tree blob at 0x68300000
Booting using the fdt blob at 0x68300000
XIP Kernel Image from 0x62008000 to 0x62008000 ... OK
Using Device Tree in place at 68300000, end 6830e2a2
failed to reserve drm-cubic-lut memory
Adding bank: 0x60000000 - 0x68400000 (size: 0x08400000)
Adding bank: 0x69210000 - 0x80000000 (size: 0x16df0000)
Total: 182390.686 ms
Starting kernel ...
..............
[root@root:/]# reboot
Interrupt rebooted u-boot and the sdcard works:
.........
<debug_uart> MMC: dwmmc@10214000: 1
Using default environment
switch to partitions #0, OK
mmc1 is current device
Found IDB in SDcard
Boot from SDCARD
Bootdev: mmc 1
MMC1: Legacy, 26Mhz
PartType: EFI
........
Hit key to stop autoboot('CTRL+C'): 0
=> mmc dev 1
switch to partitions #0, OK
mmc1 is current device
=> mmc part
Partition Map for MMC device 1 -- Partition Type: EFI
Part Start LBA End LBA Name
Attributes
Type GUID
Partition GUID
1 0x00004000 0x00005fff "uboot"
attrs: 0x0000000000000000
type: 0fc63daf-8483-4772-8e79-3d69d8477de4
guid: a9ea64f2-f71b-4c98-998e-81b8d3a160f1
2 0x00006000 0x00007fff "trust"
attrs: 0x0000000000000000
type: 0fc63daf-8483-4772-8e79-3d69d8477de4
guid: 92c1a295-e156-4fcb-aacd-02bfdf94dfd3
3 0x00008000 0x0000c7ff "boot"
attrs: 0x0000000000000000
type: c12a7328-f81f-11d2-ba4b-00a0c93ec93b
guid: 6df3c492-bb6a-447a-8e48-249923b478a6
4 0x0000c800 0x0002f7ff "rootfs"
attrs: 0x0000000000000000
type: 0fc63daf-8483-4772-8e79-3d69d8477de4
guid: 614e0000-0000-4b53-8000-1d28000054a9
5 0x0002f800 0x01d2dfc0 "userdata"
attrs: 0x0000000000000000
type: 0fc63daf-8483-4772-8e79-3d69d8477de4
guid: 5b9ba82c-e10a-4028-99d5-1f8f5398b978
=> boot_android mmc 1
Could not find misc partition
ANDROID: reboot reason: "(none)"
Not AVB images, AVB skip
Kernel image @ 0x7bddfba8 [ 0x000000 - 0x3dadf8 ]
DTB: rk-kernel.dtb
Booting ZIMAGE kernel at 0x62008000(Uncompress to 0x60000000) with fdt at 0x68300000...
Fdt Ramdisk skip relocation
## Booting Android Image at 0x62007800 ...
Kernel load addr 0x62008000 size 3948 KiB
## Flattened Device Tree blob at 0x68300000
Booting using the fdt blob at 0x68300000
XIP Kernel Image from 0x62008000 to 0x62008000 ... OK
Using Device Tree in place at 68300000, end 6830e292
failed to reserve drm-cubic-lut memory
Adding bank: 0x60000000 - 0x68400000 (size: 0x08400000)
Adding bank: 0x69210000 - 0x80000000 (size: 0x16df0000)
Total: 67896.479 ms
Starting kernel ...
Something is bad in u-boot. Maybe PWM powers, interrupts, dmas ...
additional hint: I did many tests and I destroyed protected bootloader in spinand :-). so MASKROM mode must be forced by GND to DI or CLK on W25N01GV and upload testing u-boot (with NONSEC support) directly to RAM over USB:
# openssl rc4 -K 7c4e0304550509072d2c7b38170d1711 < rk3128_ddr_300MHz_v2.09_uart0_20181106.bin | rkflashtool/rkflashtool l
# openssl rc4 -K 7c4e0304550509072d2c7b38170d1711 < caesar-u-boot/u-boot-dtb.bin | rkflashtool/rkflashtool L
# ### or other loader like rk3128_usbplug_v2.63.bin, rk3128_loader_v2.12.263.bin ...
Ok, "repaired" SDcard boot, use only 1-bit (not 4-bit) mode (see https://github.com/mcerveny/caesar-u-boot/commit/7f2236ec5a587577416a774e470b409bec33845c) with actual code :-( .
Ok, "repaired" SDcard boot, use only 1-bit (not 4-bit) mode (see mcerveny/caesar-u-boot@7f2236e) with actual code :-( .
Very nice, I tried a different route by plugin a USB card to rule out whether there was a different issue, the USB booted "correctly":
Scanning usb 0:1...
Found /extlinux/extlinux.conf
Retrieving file: /extlinux/extlinux.conf
165 bytes read in 108 ms (1000 Bytes/s)
1: linux
Retrieving file: /extlinux/zImage
4042920 bytes read in 294 ms (13.1 MiB/s)
append: earlyprintk console=ttyS0,115200n8 rw root=/dev/mmcblk1p7 rootwait rootfstype=ext4 init=/sbin/init
Retrieving file: /extlinux/rk-kernel.dtb
45719 bytes read in 155 ms (287.1 KiB/s)
Fdt Ramdisk skip relocation
Kernel image @ 0x62008000 [ 0x000000 - 0x3db0a8 ]
## Flattened Device Tree blob at 0x68300000
Booting using the fdt blob at 0x68300000
Using Device Tree in place at 68300000, end 6830e296
No resource partition
No file: logo.bmp
Adding bank: 0x60000000 - 0x61000000 (size: 0x01000000)
Adding bank: 0x61200000 - 0x80000000 (size: 0x1ee00000)
Total: 8888.208 ms
Starting kernel ...
Just tried your uboot patch and I can confirm that fixes the SDMMC errors.
However the display is not properly initialized, the UART does not show anything (I need to change the kernel console to output to the same one) but the syslog shows the problem:
[ 63.286218] rockchip-vop 1010e000.vop: [drm:vop_wait_for_irq_handler] *ERROR* VOP vblank IRQ stuck for 10 ms
[ 63.386221] rockchip-vop 1010e000.vop: [drm:vop_wait_for_irq_handler] *ERROR* VOP vblank IRQ stuck for 10 ms
[ 63.486245] rockchip-vop 1010e000.vop: [drm:vop_wait_for_irq_handler] *ERROR* VOP vblank IRQ stuck for 10 ms
[ 63.586191] rockchip-vop 1010e000.vop: [drm:vop_wait_for_irq_handler] *ERROR* VOP vblank IRQ stuck for 10 ms
Full dmesg log: dmesg.log
Note that this is booting via spinand, since I needed the MMC.
In any case, impressive work @mcerveny !
"caesar" removed kernel git (https://github.com/Caesar-github/rockchip.git) :-( (I have local copy :-). Not all patches are in rockchip kernel git (https://github.com/rockchip-linux/kernel.git):
# git log --format=short HEAD...ada467d2718ff0f929d5512053a28b9238b57b4c > /tmp/additional_patches.txt
@mcerveny, @acmeplus, --Big disclaimer: I don't have any idea about how all this stuff works--
[ 63.286218] rockchip-vop 1010e000.vop: [drm:vop_wait_for_irq_handler] *ERROR* VOP vblank IRQ stuck for 10 ms [ 63.386221] rockchip-vop 1010e000.vop: [drm:vop_wait_for_irq_handler] *ERROR* VOP vblank IRQ stuck for 10 ms [ 63.486245] rockchip-vop 1010e000.vop: [drm:vop_wait_for_irq_handler] *ERROR* VOP vblank IRQ stuck for 10 ms [ 63.586191] rockchip-vop 1010e000.vop: [drm:vop_wait_for_irq_handler] *ERROR* VOP vblank IRQ stuck for 10 ms
I found this patch and I wonder whether the error above may be related to something similar.
I found this patch and I wonder whether the error above may be related to something similar.
Nope.
Rockchip repo (uboot and kernel) have lot of proprietary code and WX8 authors add some additional code and does not expose it to public thus violating GPL. As I wrote @ beginning I suppose that "original kernel" heavily depends on "original u-boot" initialization of HW that is awful. This messages arise when I used Rockchip (caesar) opensource u-boot with "original kernel".
Now I try to rebuild kernel from Rockchip opensources but I found many proprietary drivers/code in kernel config:
CONFIG_KEYBOARD_GPIO_VOLUME
CONFIG_KEYBOARD_GPIO_WX8
CONFIG_SCREEN_OFF
CONFIG_WX8_OTG_HOST
CONFIG_DRM_PANEL_SIMPLE_WX8OLED
CONFIG_DRM_PANEL_SIMPLE_LCD_RESET
CONFIG_EXFAT_FS # backported from kernel >=5.4
CONFIG_EXFAT_DISCARD # backported from kernel >=5.4
CONFIG_EXFAT_DEFAULT_CODEPAGE # backported from kernel >=5.4
CONFIG_EXFAT_DEFAULT_IOCHARSET # backported from kernel >=5.4
I queried Shenzhen Sunchip Technology Co., Ltd. over Alibaba chat (or direct) to get access to GPL licensed code and build script (uboot,kernel,buildroot...). Sunchip say, that they are the developer of PS5000 or here ... and 10% off in September. No answer, try it too.
I was partially successful to rebuild linux kernel (based on rockchipl-linux). As I wrote in previous post many "close source" mods exists.
export ARCH=arm; export CROSS_COMPILE=arm-linux-gnueabihf-; make wx8_defconfig; make -j4
compatible = "gpio-keys-volume"
) and not joystickscompatible = "rk30-adc-battery"
)compatible = "i2c0"
) that may be root cause of all problems that probably do something with power DCDC convertors.distroboot
(standard ext2 partition with extlinux/extlinux.conf
)hint*: boot from original uboot/kernel and then "reboot" by command to sdcard.
example of sdcard build script:
#!/bin/bash
LOCALPATH=$(pwd)
UBOOT=caesar-u-boot
RKBIN=caesar-rkbin
LINUX=rockchip-linux
LOADER1_START=64
UBOOT_START=16384
TRUST_START=$(($UBOOT_START + 8192))
BOOT_START=$(($TRUST_START + 8192))
ROOTFS_START=$(($BOOT_START + 18432))
USERDATA_START=$(($ROOTFS_START + 143360))
SDCARD_START=$(($USERDATA_START + 65536))
SYSTEM=/dev/sdc
echo DESTOROY ${SYSTEM} ?!?!?
read
for i in ${SYSTEM}[1-9]; do umount $i || true; done
dd if=/dev/zero of=${SYSTEM} bs=1M count=$(( $ROOTFS_START / 2 / 1024 + 1)) conv=sync
partprobe
echo PARTITIONS
parted -s ${SYSTEM} mklabel gpt
parted -s ${SYSTEM} unit s mkpart uboot ${UBOOT_START} $(( ${TRUST_START} - 1))
parted -s ${SYSTEM} unit s mkpart trust ${TRUST_START} $(( ${BOOT_START} - 1))
parted -s ${SYSTEM} unit s mkpart boot ${BOOT_START} $(( ${ROOTFS_START} - 1))
parted -s ${SYSTEM} set 3 boot on
parted -s ${SYSTEM} unit s mkpart rootfs ${ROOTFS_START} $(( ${USERDATA_START} - 1))
parted -s ${SYSTEM} unit s mkpart userdata ${USERDATA_START} $(( ${SDCARD_START} - 1))
parted -s ${SYSTEM} -- unit s mkpart sdcard ${SDCARD_START} -64s
partprobe
gdisk ${SYSTEM} <<EOF
x
c
4
${ROOT_UUID}
w
y
EOF
echo IMAGES
# OMG, in some rockchip scripts, what is this:
#dd if=$RKBIN/bin/rk31/rk3128_ddr_300MHz_v2.12.bin of=DDRTEMP bs=4 skip=1
#$UBOOT/tools/mkimage -n rk3128 -T rksd -d DDRTEMP idbloader.img
$UBOOT/tools/mkimage -n rk3128 -T rksd -d $RKBIN/bin/rk31/rk3128_ddr_300MHz_v2.12.bin idbloader.img
cat $RKBIN/bin/rk31/rk3128x_miniloader_v2.57.bin >> idbloader.img
# 8192s -> 4MB -> 4 copies
$UBOOT/tools/loaderimage --pack --uboot $UBOOT/u-boot-dtb.bin uboot.img --size 1024 4
$UBOOT/tools/loaderimage --pack --trustos $RKBIN/bin/rk31/rk3126_tee_ta_v2.01.bin trust.img --size 1024 4
echo COPY
dd if=idbloader.img of=${SYSTEM} seek=${LOADER1_START} conv=notrunc,sync
dd if=uboot.img of=${SYSTEM} seek=${UBOOT_START} conv=notrunc,sync
dd if=trust.img of=${SYSTEM} seek=${TRUST_START} conv=notrunc,sync
mkfs.ext2 -F ${SYSTEM}3
mount ${SYSTEM}3 /mnt
mkdir /mnt/extlinux
cp extlinux.conf /mnt/extlinux/
cp ${LINUX}/arch/arm/boot/zImage /mnt/extlinux/
cp ${LINUX}/arch/arm/boot/dts/rk3128-wx8.dtb /mnt/extlinux/kernel.dtb
umount /mnt
dd if=rootfs.img of=${SYSTEM} conv=notrunc,sync seek=${ROOTFS_START}
mkfs.ext2 -F ${SYSTEM}5
mkfs.vfat ${SYSTEM}6
mount ${SYSTEM}6 /mnt
tar xf sdcard.tar -C /mnt --no-same-owner
umount /mnt
echo DONE
example of extlinux.conf
:
DEFAULT linux
LABEL linux
KERNEL zImage
FDT kernel.dtb
APPEND earlycon=uart8250,mmio32,0x20060000 rootwait console=ttyFIQ0,115200n8 loglevel=7 swiotlb=1 root=PARTUUID=614e0000-0000-4b53-8000-1d28000054a9
sdcard.tar:
# tar tf sdcard.tar
./
./game/
./game/gba/
./game/gba/1823 - Pac-Man World(EU).gba
./music/
./music/test music (1).mp3
./video/
./video/one piece.mp4
./pic/
./pic/01.jpg
@mcerveny just to confirm that I can mostly reproduce your findings. Some minor differences/observations:
I'll do some additional tests this week.
* Direct boot from the sdcard (without the hint) and with HDMI connected basically gets me the expected HDMI EDID errors, so anything DRM based does not work, however SDL applications do work via HDMI. Tested SDLPoP and worked fine
DRM works, but display is not on, attach HDMI that is capable 960x544/59HZ.
* I can confirm only zpio core controls work, adc-pot ones don't respond (/dev/input only registers event0, no event2-5 or js0/js1)
I will try to read internal register settings and others in /sys/kernel/debug/... to decode used pins :-)
* Not really sure if I may have just overwritten something on my sdcard, but it looks like the boot from the sdcard still keeps the internal/spinand rootfs and not the one from the sdcard. I need to doublecheck that my extlinux append line is correct, it may just be a typo.
Try to change UUID (partition UUID and extlinux.conf reference)
* Finally, I've done the same tests with the Powkiddy A12, same SOC, different specs. SDcard works the same as with PS5K/WX8, although the display is initialized (incorrectly but is on) during boot.
This is weird. As I see A13 board display is connected with parallel RGB and not MIPI DSI.
* Direct boot from the sdcard (without the hint) and with HDMI connected basically gets me the expected HDMI EDID errors, so anything DRM based does not work, however SDL applications do work via HDMI. Tested SDLPoP and worked fine
DRM works, but display is not on, attach HDMI that is capable 960x544/59HZ.
Ok, will try a different monitor.
* I can confirm only zpio core controls work, adc-pot ones don't respond (/dev/input only registers event0, no event2-5 or js0/js1)
I will try to read internal register settings and others in /sys/kernel/debug/... to decode used pins :-)
I may be able to help there. Will give it a try.
* Not really sure if I may have just overwritten something on my sdcard, but it looks like the boot from the sdcard still keeps the internal/spinand rootfs and not the one from the sdcard. I need to doublecheck that my extlinux append line is correct, it may just be a typo.
Try to change UUID (partition UUID and extlinux.conf reference)
Yeah, I haven't had time but it's most likely that.
* Finally, I've done the same tests with the Powkiddy A12, same SOC, different specs. SDcard works the same as with PS5K/WX8, although the display is initialized (incorrectly but is on) during boot.
This is weird. As I see A13 board display is connected with parallel RGB and not MIPI DSI.
Yes, I noticed that, so it's probably something else that is activating that. It's only initialization, haven't tried to actually use the display. Update: just tested and initialization lights the display up with white background. After boot finishes display stays up but with black background. HDMI works as before, SDLPoP works on the HDMI, DRM does not. This is without the re-boot trick.
Busy the last few days, will try to find some time this week.
BTW, you can find @alpgarcia or @acmeplus on telegram or discord.
Resolved hint problem. Found master "enable" GPIO (part of closed source driver "gpio-keys-volume") so I moved last two keys VOL+/VOL- to generic GPIO keys (but volume control does not work due to need of direct scaling in PCM engine) see https://github.com/mcerveny/rockchip-linux/commit/432d410d98f580fac3c5835c4f45c8bfeaa8e1a1 . Master "enable" GPIO can be used over `/sys/class/gpio/`:
echo 93 > /sys/class/gpio/export
echo out > /sys/class/gpio/gpio93/direction
echo 1 > /sys/class/gpio/gpio93/value
Resolved hint* problem.
The display init issue? or the GPIO?
Found master "enable" GPIO (part of closed source driver "gpio-keys-volume") so I moved last two keys VOL+/VOL- to generic GPIO keys (but volume control does not work due to need of direct scaling in PCM engine) see mcerveny/rockchip-linux@432d410 . Master "enable" GPIO can be used over
/sys/class/gpio/*
:echo 93 > /sys/class/gpio/export echo out > /sys/class/gpio/gpio93/direction echo 1 > /sys/class/gpio/gpio93/value
Good, running /etc/init.d/S49alsa stop/start adds the master mixer too. Also changing the /etc/input-even-daemon to listen to /dev/input/event0 event links the volume control to the master. The way it was done on these device was via that listener. Other devices have proper mapping of volume to PCM.
I've tested what I have running internally+external sdcard working via external SDCard only, of course viaHDMI only.
Resolved hint* problem. The display init issue? or the GPIO?
MIPI DSI display. As I wrote, the MIPI DSI display was always initialized properly (in kernel, unknown in u-boot) only nothing shows due to this powersaving GPIO switch. The closed sourced driver exposes /sys/devices/platform/adc-pot/screen_off
to drive this GPIO and for audio volume /sys/devices/platform/adc-pot/scaled
....
Resolved hint* problem. The display init issue? or the GPIO?
MIPI DSI display. As I wrote, the MIPI DSI display was always initialized properly (in kernel, unknown in u-boot) only nothing shows due to this powersaving GPIO switch. The closed sourced driver exposes
/sys/devices/platform/adc-pot/screen_off
to drive this GPIO and for audio volume/sys/devices/platform/adc-pot/scaled
....
Yeah, I get it now... just checked and it's working both internally/externally. It's interesting because the adc-pot is misconfigured in the A12 console, and the volume control always complains about the adc-pot.
I'm going to try to consolidate the batocera test firmware I have with this setup.
Example of audio volume control (hdmi not tested):
# cat /sdcard/input-event-daemon.conf
[Global]
listen = /dev/input/by-path/platform-keys-event
[Keys]
VOLUMEUP = /bin/bash /sdcard/volctrl.sh up
VOLUMEDOWN = /bin/bash /sdcard/volctrl.sh down
# cat /sdcard/volctrl.sh
#!/bin/bash
if [ `cat /sys/class/drm/card0-HDMI-A-1/status` == "disconnected" ]; then
name='Master Playback Volume'
else
name='HDMI Playback Volume'
fi
value=$(amixer cget name="$name" | sed -n 's/^ :.*values=\([[0-9]*\).*/\1/p')
if [[ "$1" == "up" ]]; then
let value=value+9
if [[ $value -gt 99 ]]; then value=99; fi
else
let value=value-9
if [[ $value -lt 0 ]]; then value=0; fi
fi
amixer cset name="$name" $value
# input-event-daemon -c /sdcard/input-event-daemon.conf -v
# ### press V+/V-
key_event:
code : VOLUMEUP
source : /dev/input/by-path/platform-keys-event
exec : "/bin/bash /sdcard/volctrl.sh up"
numid=6,iface=MIXER,name='Master Playback Volume'
; type=INTEGER,access=rw---RW-,values=2,min=0,max=99,step=0
: values=63,63
| dBscale-min=-40.00dB,step=0.34dB,mute=0
key_event:
code : VOLUMEUP
source : /dev/input/by-path/platform-keys-event
exec : "/bin/bash /sdcard/volctrl.sh up"
numid=6,iface=MIXER,name='Master Playback Volume'
; type=INTEGER,access=rw---RW-,values=2,min=0,max=99,step=0
: values=72,72
| dBscale-min=-40.00dB,step=0.34dB,mute=0
key_event:
code : VOLUMEDOWN
source : /dev/input/by-path/platform-keys-event
exec : "/bin/bash /sdcard/volctrl.sh down"
numid=6,iface=MIXER,name='Master Playback Volume'
; type=INTEGER,access=rw---RW-,values=2,min=0,max=99,step=0
: values=63,63
| dBscale-min=-40.00dB,step=0.34dB,mute=0
key_event:
code : VOLUMEDOWN
source : /dev/input/by-path/platform-keys-event
exec : "/bin/bash /sdcard/volctrl.sh down"
numid=6,iface=MIXER,name='Master Playback Volume'
; type=INTEGER,access=rw---RW-,values=2,min=0,max=99,step=0
: values=54,54
| dBscale-min=-40.00dB,step=0.34dB,mute=0
# ### test it (aplay does not work without `-v` or other audio client must be started)
# aplay -v /usr/local/share/minigui/res/music/chord.wav
Resolved unknown I2C chip (address 0x4c):
#include <stdint.h>
#include <sys/types.h>
#include <sys/stat.h>
#include <unistd.h>
#include <fcntl.h>
#include <stdio.h>
#include <sys/ioctl.h>
#include <linux/i2c-dev.h>
#include <assert.h>
int main() { int addr = 0x4c; int file; uint8_t buf[15];
assert((file = open("/dev/i2c-0", O_RDWR)) >= 0);
assert(!ioctl(file, I2C_SLAVE, addr));
assert(read(file,buf,sizeof(buf)) == sizeof(buf));
//for(int i=0;i<sizeof(buf)/sizeof(buf[0]); i++) {
// printf("%2d %3d\n", i, buf[i]);
//}
printf("LV %3d\nLH %3d\nRV %3d\nRH %3d", buf[9], buf[7], buf[1], buf[3]);
}
cross compile:
use:
LV 169 LH 164 RV 166 RH 164
Created +-compatible joystick driver see https://github.com/mcerveny/rockchip-linux/commit/cdb8bee370ff1cf42ad2bc5bc7187f9ecaf86b50. Driver with keys emulation (directions,ABXY) enabled by default. To switch between keys emulation and joysticks put 0 or 1 to "/sys/.../key_type". Key emulation (default):
[root@root:/]# evtest /dev/input/event0
Input driver version is 1.0.1
Input device ID: bus 0x18 vendor 0x0 product 0x0 version 0x0
Input device name: "Driver for WX8 joysticks"
Supported events:
Event type 0 (EV_SYN)
Event type 1 (EV_KEY)
Event code 21 (KEY_Y)
Event code 30 (KEY_A)
Event code 45 (KEY_X)
Event code 48 (KEY_B)
Event code 103 (KEY_UP)
Event code 105 (KEY_LEFT)
Event code 106 (KEY_RIGHT)
Event code 108 (KEY_DOWN)
Event type 3 (EV_ABS)
Event code 0 (ABS_X)
Value 163
Min 95
Max 225
Fuzz 2
Flat 4
Event code 1 (ABS_Y)
Value 167
Min 95
Max 225
Fuzz 2
Flat 4
Event code 2 (ABS_Z)
Value 162
Min 95
Max 225
Fuzz 2
Flat 4
Event code 5 (ABS_RZ)
Value 163
Min 95
Max 225
Fuzz 2
Flat 4
Key repeat handling:
Repeat type 20 (EV_REP)
Repeat code 0 (REP_DELAY)
Value 250
Repeat code 1 (REP_PERIOD)
Value 33
Properties:
Testing ... (interrupt to exit)
Event: time 1213.870982, type 1 (EV_KEY), code 30 (KEY_A), value 1
Event: time 1213.870982, -------------- SYN_REPORT ------------
Event: time 1213.930827, type 1 (EV_KEY), code 30 (KEY_A), value 0
Event: time 1213.930827, -------------- SYN_REPORT ------------
Event: time 1216.070963, type 1 (EV_KEY), code 105 (KEY_LEFT), value 1
Event: time 1216.070963, -------------- SYN_REPORT ------------
Event: time 1216.191000, type 1 (EV_KEY), code 105 (KEY_LEFT), value 0
Event: time 1216.191000, -------------- SYN_REPORT ------------
Switch to joysticks ("1"):
[root@root:/]# find /sys -name key_type
/sys/devices/platform/20072000.i2c/i2c-0/0-004c/key_type
[root@root:/]# cat /sys/devices/platform/20072000.i2c/i2c-0/0-004c/key_type
0
[root@root:/]# echo 1 > /sys/devices/platform/20072000.i2c/i2c-0/0-004c/key_type
[root@root:/]# cat /sys/devices/platform/20072000.i2c/i2c-0/0-004c/key_type
1
[root@root:/]# evtest /dev/input/event0
Input driver version is 1.0.1
Input device ID: bus 0x18 vendor 0x0 product 0x0 version 0x0
Input device name: "Driver for WX8 joysticks"
Supported events:
Event type 0 (EV_SYN)
Event type 1 (EV_KEY)
Event code 21 (KEY_Y)
Event code 30 (KEY_A)
Event code 45 (KEY_X)
Event code 48 (KEY_B)
Event code 103 (KEY_UP)
Event code 105 (KEY_LEFT)
Event code 106 (KEY_RIGHT)
Event code 108 (KEY_DOWN)
Event type 3 (EV_ABS)
Event code 0 (ABS_X)
Value 163
Min 95
Max 225
Fuzz 2
Flat 4
Event code 1 (ABS_Y)
Value 167
Min 95
Max 225
Fuzz 2
Flat 4
Event code 2 (ABS_Z)
Value 161
Min 95
Max 225
Fuzz 2
Flat 4
Event code 5 (ABS_RZ)
Value 167
Min 95
Max 225
Fuzz 2
Flat 4
Key repeat handling:
Repeat type 20 (EV_REP)
Repeat code 0 (REP_DELAY)
Value 250
Repeat code 1 (REP_PERIOD)
Value 33
Properties:
Testing ... (interrupt to exit)
Event: time 1312.891016, type 3 (EV_ABS), code 2 (ABS_Z), value 162
Event: time 1312.891016, -------------- SYN_REPORT ------------
Event: time 1312.901030, type 3 (EV_ABS), code 2 (ABS_Z), value 163
Event: time 1312.901030, -------------- SYN_REPORT ------------
Event: time 1312.920820, type 3 (EV_ABS), code 5 (ABS_RZ), value 166
Event: time 1312.920820, -------------- SYN_REPORT ------------
Event: time 1312.951078, type 3 (EV_ABS), code 5 (ABS_RZ), value 165
Event: time 1312.951078, -------------- SYN_REPORT ------------
Event: time 1313.751213, type 3 (EV_ABS), code 2 (ABS_Z), value 162
Event: time 1313.751213, -------------- SYN_REPORT ------------
Event: time 1313.770868, type 3 (EV_ABS), code 5 (ABS_RZ), value 166
Event: time 1313.770868, -------------- SYN_REPORT ------------
Event: time 1313.780876, type 3 (EV_ABS), code 2 (ABS_Z), value 161
Event: time 1313.780876, -------------- SYN_REPORT ------------
Event: time 1313.791052, type 3 (EV_ABS), code 2 (ABS_Z), value 160
Event: time 1313.791052, -------------- SYN_REPORT ------------
Event: time 1313.810824, type 3 (EV_ABS), code 2 (ABS_Z), value 156
Event: time 1313.810824, -------------- SYN_REPORT ------------
Event: time 1313.840822, type 3 (EV_ABS), code 2 (ABS_Z), value 134
Event: time 1313.840822, -------------- SYN_REPORT ------------
Event: time 1313.871064, type 3 (EV_ABS), code 2 (ABS_Z), value 112
Event: time 1313.871064, -------------- SYN_REPORT ------------
Event: time 1313.900894, type 3 (EV_ABS), code 2 (ABS_Z), value 108
Event: time 1313.900894, -------------- SYN_REPORT ------------
Event: time 1313.930830, type 3 (EV_ABS), code 2 (ABS_Z), value 117
Event: time 1313.930830, -------------- SYN_REPORT ------------
Event: time 1313.960905, type 3 (EV_ABS), code 2 (ABS_Z), value 162
Event: time 1313.960905, -------------- SYN_REPORT ------------
Event: time 1316.041041, type 3 (EV_ABS), code 1 (ABS_Y), value 168
Event: time 1316.041041, -------------- SYN_REPORT ------------
Event: time 1316.051030, type 3 (EV_ABS), code 1 (ABS_Y), value 169
Event: time 1316.051030, -------------- SYN_REPORT ------------
Event: time 1316.071243, type 3 (EV_ABS), code 0 (ABS_X), value 171
Event: time 1316.071243, -------------- SYN_REPORT ------------
Event: time 1316.100814, type 3 (EV_ABS), code 0 (ABS_X), value 194
Event: time 1316.100814, -------------- SYN_REPORT ------------
I try to connect both (keys + joys (emulated EV_KEY or joystick EV_ABS)) to retroarch but mostly unsuccessful. Keys does not work for me. I found the retroarch accept only ENV "ID_INPUT_JOYSTICK=1" udevs :-( Is there anyone capable to debug this (problem with original "china-version" retroarch?) ? So I do this to set ENV for keys:
cp -r /etc/udev/rules.d/ /tmp/
cat > /tmp/rules.d/99-keys.rules << EOT
KERNEL=="event1", ENV{ID_INPUT_JOYSTICK}="1"
EOT
mount --binding /tmp/rules.d/ /etc/udev/rules.d/
udevadm control --reload-rules
sleep 1
udevadm trigger /dev/input/event1
sleep 1
udevadm info /dev/input/event1
### see ID_INPUT_JOYSTICK
# testing # evtest /dev/input/event1
# testing # evtest /dev/input/event0
Update to HDMI with original rootfs:
# xxd -g1 /sys/devices/platform/display-subsystem/drm/card0/card0-HDMI-A-1/edid
00000000: 00 ff ff ff ff ff ff 00 35 ee 32 bc 01 01 01 01 ........5.2.....
00000010: 09 1a 01 03 80 22 13 78 3e ee 91 a3 54 4c 99 26 .....".x>...TL.&
00000020: 0f 50 54 01 08 00 d1 c0 d1 e8 d1 fc 95 00 90 40 .PT............@
00000030: 81 80 81 40 81 c0 02 3a 80 18 71 38 2d 40 58 2c ...@...:..q8-@X,
00000040: 25 00 58 c1 10 00 00 1e 00 00 00 fc 00 4d 6f 6e %.X..........Mon
00000050: 69 74 6f 72 0a 20 20 20 20 20 00 00 00 ff 00 64 itor. .....d
00000060: 65 6d 6f 73 65 74 2d 31 0a 20 30 20 00 00 00 fd emoset-1. 0 ....
00000070: 00 32 4b 54 54 13 01 0a 20 20 20 20 20 20 01 72 .2KTT... .r
00000080: 02 03 24 f2 41 10 e2 00 d5 e3 05 c0 00 23 09 7f ..$.A........#..
00000090: 07 83 01 00 00 67 03 0c 00 10 00 38 3c e6 06 05 .....g.....8<...
000000a0: 01 62 62 00 02 3a 80 18 71 38 2d 40 58 2c 25 00 .bb..:..q8-@X,%.
000000b0: 55 50 21 00 00 1e 01 1d 80 18 71 1c 16 20 58 2c UP!.......q.. X,
000000c0: 25 00 55 50 21 00 00 9e 00 00 00 00 00 00 00 00 %.UP!...........
000000d0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
000000e0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
000000f0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 52 ...............R
1920x1080p60 1280x720p60 1920x1080p120 1920x1080p100 1920x1080p60 1920x1080p60 1400x1050p60 1280x1024p60 1440x900p60 1280x960p60 1280x720p60 1024x768p60 800x600p60
1280x720p60
- HDMI automatically switched over /etc/udev/rules.d/60-drm.rules -> /usr/bin/drm-hotplug.sh
- HDMI audio works and volume can be modified by hotkeys `input-event-daemon -c /sdcard/input-event-daemon.conf -v` (see previous posts)
input-event-daemon: Start listening on 1 devices... key_event: code : VOLUMEDOWN source : /dev/input/by-path/platform-keys-event exec : "/bin/bash /sdcard/volctrl.sh down"
numid=7,iface=MIXER,name='HDMI Playback Volume' ; type=INTEGER,access=rw---RW-,values=2,min=0,max=99,step=0 : values=85,85 | dBscale-min=-40.00dB,step=0.40dB,mute=0
key_event: code : VOLUMEDOWN source : /dev/input/by-path/platform-keys-event exec : "/bin/bash /sdcard/volctrl.sh down"
numid=7,iface=MIXER,name='HDMI Playback Volume' ; type=INTEGER,access=rw---RW-,values=2,min=0,max=99,step=0 : values=76,76 | dBscale-min=-40.00dB,step=0.40dB,mute=0
I try to connect both (keys + joys (emulated EV_KEY or joystick EV_ABS)) to retroarch but mostly unsuccessful. Keys does not work for me. I found the retroarch accept only ENV "ID_INPUT_JOYSTICK=1" udevs :-( Is there anyone capable to debug this (problem with original "china-version" retroarch?) ?
With the lastest change that you have done I have all keys and joysticks working under retroarch.
Test one, with UDEV input driver
Test two, with SDL2 input driver
Not sure if this helpful, note that the retroarch version is 1.9.7 compiled with udev + sdl2, the one from the Chinese firmware is 1.7.4 or something like that.
With the lastest change that you have done I have all keys and joysticks working under retroarch.
Good news :-)
* L3/R3 don't work (I believe that's expected)
I HW traced R3 button (push joystick):
Awesome work @mcerveny and @acmeplus!
I've been able to create a bootable SD that runs into RetroArch. For completeness, I'm detailing the sources and small tweaks I applied so anyone else can reproduce them. I didn't test HDMI and headphones output yet.
I added the following snippet to Martin's script to create the extlinux.conf
file.
PARTUUID=`blkid -o export ${SYSTEM}4 | grep PARTUUID`
echo "Create extlinux.conf"
cat > extlinux.conf << EOF
DEFAULT linux
LABEL linux
KERNEL zImage
FDT kernel.dtb
APPEND earlycon=uart8250,mmio32,0x20060000 rootwait console=ttyFIQ0,115200n8 loglevel=7 swiotlb=1 root=${PARTUUID}
EOF
echo "---- extlinux.conf ----"
cat extlinux.conf
echo "-----------------------"
The rootfs needs some modifications:
/etc/fstab
to mount userdata
and sdcard
partitions (I believe the two lines to mount misc
and oem
doesn't work and can be removed):
/dev/mmcblk0p5 /userdata ext2 sync 0 2
/dev/mmcblk0p6 /mnt/sdcard vfat rw,uid=1000,gid=1000,dmask=022,fmask=133,noatime,sync 0 2
/lib/udev/rules.d/61-sd-cards-auto-mount.rules
file./etc/init.d/S50launcher
needs to be updated to init the internal screen by adding the lines mentioned on https://github.com/Ruka-CFW/rk3128-cfw/issues/51#issuecomment-915067980 and to point to the RetroArch config file (/mnt/sdcard/retroarch_ps5000.cfg
).Volume buttons are not being recognized in Retroarch (VOLUMEUP and VOLUMEDOWN), however volume can still be set by configuring the RetroArch hotkeys.
/sdcard/cores
.I tried to enable u-boot display/DSI support to show "logo" (splash screens). It partially works:
#!/bin/bash -exv
LOCALPATH=$(pwd) UBOOT=caesar-u-boot RKBIN=caesar-rkbin LINUX=rockchip-linux
LOADER1_START=64
UBOOT_START=16384
TRUST_START=$(($UBOOT_START + 8192))
BOOT_START=$(($TRUST_START + 8192))
ROOTFS_START=$(($BOOT_START + 18432))
USERDATA_START=$(($ROOTFS_START + 143360))
SDCARD_START=$(($USERDATA_START + 65536))
ROOT_UUID=fd800c6c-2fdb-4502-82cb-e61f66b9a221
SYSTEM=/dev/sdc
echo DESTOROY ${SYSTEM} ?!?!? read
for i in ${SYSTEM}[1-9]; do umount $i || true; done dd if=/dev/zero of=${SYSTEM} bs=1M count=$(( $ROOTFS_START / 2 / 1024 + 1)) conv=sync partprobe
echo PARTITIONS
parted -s ${SYSTEM} mklabel gpt parted -s ${SYSTEM} unit s mkpart uboot ${UBOOT_START} $(( ${TRUST_START} - 1)) parted -s ${SYSTEM} unit s mkpart trust ${TRUST_START} $(( ${BOOT_START} - 1)) parted -s ${SYSTEM} unit s mkpart boot ${BOOT_START} $(( ${ROOTFS_START} - 1)) parted -s ${SYSTEM} set 3 boot on parted -s ${SYSTEM} unit s mkpart rootfs ${ROOTFS_START} $(( ${USERDATA_START} - 1)) parted -s ${SYSTEM} unit s mkpart userdata ${USERDATA_START} $(( ${SDCARD_START} - 1)) parted -s ${SYSTEM} -- unit s mkpart sdcard ${SDCARD_START} -64s partprobe
gdisk ${SYSTEM} <<EOF x c 4 ${ROOT_UUID} w y EOF
echo IMAGES
${UBOOT}/tools/mkimage -n rk3128 -T rksd -d ${RKBIN}/bin/rk31/rk3128_ddr_300MHz_v2.12.bin idbloader.img cat ${RKBIN}/bin/rk31/rk3128x_miniloader_v2.57.bin >> idbloader.img
${UBOOT}/tools/loaderimage --pack --uboot ${UBOOT}/u-boot-dtb.bin uboot.img --size 1024 4 ${UBOOT}/tools/loaderimage --pack --trustos ${RKBIN}/bin/rk31/rk3126_tee_ta_v2.01.bin trust.img --size 1024 4
echo COPY
dd if=idbloader.img of=${SYSTEM} seek=${LOADER1_START} conv=notrunc,sync dd if=uboot.img of=${SYSTEM} seek=${UBOOT_START} conv=notrunc,sync dd if=trust.img of=${SYSTEM} seek=${TRUST_START} conv=notrunc,sync
${LINUX}/scripts/bmpconvert logo_uboot.bmp ${LINUX}/scripts/bmpconvert logo_kernel.bmp cp ${LINUX}/arch/arm/boot/dts/rk3128-wx8.dtb rk-kernel.dtb ${UBOOT}/tools/resource_tool rk-kernel.dtb logo_kernel.bmp logo_uboot.bmp logo_lowpower.bmp ${UBOOT}/scripts/mkbootimg --kernel ${LINUX}/arch/arm/boot/zImage --second resource.img --out boot.img dd if=boot.img of=${SYSTEM} conv=notrunc,sync seek=${BOOT_START}
dd if=rootfs.img of=${SYSTEM} conv=notrunc,sync seek=${ROOTFS_START}
mkfs.ext2 -F ${SYSTEM}5
mkfs.vfat ${SYSTEM}6 mount ${SYSTEM}6 /mnt tar xf sdcard.tar -C /mnt --no-same-owner umount /mnt
echo DONE
- bmp images must be "specially optimized" for rockchip - `${LINUX}/scripts/bmpconvert ...`
- packed with `rk-kernel.dtb` to ANDROID resource blob - `${UBOOT}/tools/resource_tool ...`
- and finally combined with zImage `${UBOOT}/scripts/mkbootimg ...`
- simply replaces EXT2FS
- bootargs can be placed to DTS/DTB - https://github.com/mcerveny/rockchip-linux/commit/f970198d335e96aba016abbd7d3835b9fbcb557c
- I also use different `PARTUUID` - `uuidgen` generated
- example of images - [bmp.zip](https://github.com/Ruka-CFW/rk3128-cfw/files/7157022/bmp.zip)
- bmp images must be "specially optimized" for rockchip -
${LINUX}/scripts/bmpconvert ...
- packed with
rk-kernel.dtb
to ANDROID resource blob -${UBOOT}/tools/resource_tool ...
- and finally combined with zImage
${UBOOT}/scripts/mkbootimg ...
- simply replaces EXT2FS
- bootargs can be placed to DTS/DTB - mcerveny/rockchip-linux@f970198
- I also use different
PARTUUID
-uuidgen
generated- example of images - bmp.zip
Excellent progress @mcerveny . I've seen the bootargs commit, and the comments there. I observe a similar thing:
* Display starts with about 20% displaced to the right
I found and resolve problem with logo corruption (but not in random error of IRQ). Resolved with undocumented setting to "1" - see https://github.com/mcerveny/rockchip-linux/commit/29624eeea5bb2b1463331b17b7c33f0605ca706c .
You can remove&free drm-logo and test&reset display also with modetest -M rockchip -s 62@59:960x544-59
(also with Waylant/Weston start ...).
Test your images with fbv -i /usr/local/share/ruka/img/no_sdcard_ps5k.png
? Does not work without allocated FB before ?
* Display starts with about 20% displaced to the right
I found and resolve problem with logo corruption (but not in random error of IRQ). Resolved with undocumented setting to "1" - see mcerveny/rockchip-linux@29624ee .
Looking good. I have full sd image that boots almost the same as the original internal flashed image.
Some notes:
Questions:
* Do you think we could move to a higher kernel version? or are the RockChip changes too specific into version 4.4 and will they require tons of porting to get to a higher version?
Probably not (actual kernel versions for reference) :
I do not known why Rockckip stoped to support its old chips. Rockchip is supporting only new chips including rk3326 (handhelds Odroid-Go, RGB10, RGB20, RG351 ... but 2x price increase and no HDMI output). I try to switch/use/prefer Allwinner chips/bords in all other projects with much better support from community.
* Main reason to move to a higher version would be to try to use the open source mesa-LIMA drivers instead of the closed source MALI blobs
Lima was upstreamed in Mesa 19.1 and Linux kernel 5.2. So impossible.
More findings with PCB measurment: 'enable' enables 3x DC/DC boost supply from battery voltage (~3-4V) to 5V and also -3.2V and 4.8V. It is required for backlight (see earlier posts) and now preenabled in u-boot.
echo 93 > /sys/class/gpio/export
echo out > /sys/class/gpio/gpio93/direction
# boosters 5V,-3.2V,4.8V on
echo 1 > /sys/class/gpio/gpio93/value
# boosters off
echo 0 > /sys/class/gpio/gpio93/value
Backlight PWM0 does not have any impact (probably totally irrelevant for DSI/MIPI display (probably running at maximum backlight power) but maybe relevant for unconnected/unpopulated RGB display).
# ### test irrelevant changes
# cat /sys/devices/platform/backlight/backlight/backlight/brightness
# echo 0 > /sys/devices/platform/backlight/backlight/backlight/brightness
# echo 255 > /sys/devices/platform/backlight/backlight/backlight/brightness
# ### see also "platform/20050000.pwm"
# cat /sys/kernel/debug/pwm
If you have connected USB power (OTG connector), the host USB connector works. If you disconnect USB power, the 5V voltage must be provided from 5V DC/DC boost and enabled with GPIO 41 ("1" to enable) and disable loop back to vcc_sys with GPIO 117 ("1" to disable). (My buildroot is extended by BR2_PACKAGE_IW, BR2_PACKAGE_WPA_SUPPLICANT, BR2_PACKAGE_DHCPCD, BR2_PACKAGE_FPING ..., my kernel has CONFIG_RTL8XXXU, CONFIG_RTL8XXXU_UNTESTED ... and firmware is added to rootfs /lib/firmware/rtlwifi/rtl8192cufw_TMSC.bin..)
# ### disconnect USB power
# ### enable boosters
# echo 93 > /sys/class/gpio/export
# echo out > /sys/class/gpio/gpio93/direction
# echo 1 > /sys/class/gpio/gpio93/value
# ### disable from USB to VCC_SYS
# echo 117 > /sys/class/gpio/export
# echo out > /sys/class/gpio/gpio117/direction
# echo 1 > /sys/class/gpio/gpio117/value
# ### enable 5V to both USB connectors
# echo 41 > /sys/class/gpio/export
# echo out > /sys/class/gpio/gpio41/direction
# echo 1 > /sys/class/gpio/gpio41/value
# ### now have USB devices - RTL8188CUS 802.11n WLAN Adapter over USB-micro-B-plug - USB-A-receptacle converter
# lsusb
Bus 002 Device 002: ID 0bda:8176
Bus 001 Device 001: ID 1d6b:0002
Bus 002 Device 001: ID 1d6b:0002
Bus 003 Device 001: ID 1d6b:0001
# iw dev
phy#0
Interface wlan0
ifindex 2
wdev 0x1
addr 00:13:ef:f5:1e:b6
type managed
txpower 20.00 dBm
# ip link set wlan0 up
# iw dev wlan0 scan
# wpa_supplicant -B -D nl80211 -i wlan0 -c /sdcard/wpa_supplicant.conf
# ip a
1: lo: <LOOPBACK> mtu 65536 qdisc noop qlen 1
link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
2: wlan0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq qlen 1000
link/ether 00:13:ef:f5:1e:b6 brd ff:ff:ff:ff:ff:ff
inet 192.168.2.245/24 brd 192.168.2.255 scope global wlan0
valid_lft forever preferred_lft forever
# ping -c2 www.github.com
PING www.github.com (140.82.121.3): 56 data bytes
64 bytes from 140.82.121.3: seq=0 ttl=52 time=18.058 ms
64 bytes from 140.82.121.3: seq=1 ttl=52 time=17.877 ms
--- www.github.com ping statistics ---
2 packets transmitted, 2 packets received, 0% packet loss
round-trip min/avg/max = 17.877/17.967/18.058 ms
L3/R3 buttons are HW unconnected as expected (updates issue #55). I corrected both L3/R3 PCB paths (2x solder bridges and one 56kΩ pull-up) and now I have working L3/R3 - https://github.com/mcerveny/rockchip-linux/commit/a343afcf5cf8e3f3547cef99cdc40086272bc6e0.
# evtest /dev/input/event1
Input driver version is 1.0.1
Input device ID: bus 0x19 vendor 0x1 product 0x1 version 0x100
Input device name: "keys"
Supported events:
Event type 0 (EV_SYN)
Event type 1 (EV_KEY)
Event code 19 (KEY_R)
Event code 21 (KEY_Y)
Event code 28 (KEY_ENTER)
Event code 30 (KEY_A)
Event code 32 (KEY_D)
Event code 33 (KEY_F)
Event code 38 (KEY_L)
Event code 44 (KEY_Z)
Event code 45 (KEY_X)
Event code 46 (KEY_C)
Event code 48 (KEY_B)
Event code 54 (KEY_RIGHTSHIFT)
Event code 103 (KEY_UP)
Event code 105 (KEY_LEFT)
Event code 106 (KEY_RIGHT)
Event code 108 (KEY_DOWN)
Event code 114 (KEY_VOLUMEDOWN)
Event code 115 (KEY_VOLUMEUP)
Key repeat handling:
Repeat type 20 (EV_REP)
Repeat code 0 (REP_DELAY)
Value 250
Repeat code 1 (REP_PERIOD)
Value 33
Properties:
Testing ... (interrupt to exit)
Event: time 49.130261, type 1 (EV_KEY), code 32 (KEY_D), value 1
Event: time 49.130261, -------------- SYN_REPORT ------------
Event: time 49.270342, type 1 (EV_KEY), code 32 (KEY_D), value 0
Event: time 49.270342, -------------- SYN_REPORT ------------
Event: time 50.210223, type 1 (EV_KEY), code 33 (KEY_F), value 1
Event: time 50.210223, -------------- SYN_REPORT ------------
Event: time 50.390233, type 1 (EV_KEY), code 33 (KEY_F), value 0
Event: time 50.390233, -------------- SYN_REPORT ------------
HW mods (need external pullup 56kΩ resistor for R3 because GPIO0_D6 has only pulldown resistor):
How to teardown PS5000 - https://www.youtube.com/watch?v=DVia_eR4l8k
@alpgarcia @mcerveny some updates:
WIP is in my branch
@mcerveny I forgot about this. While compiling your latest version of caesar-u-boot I see this problem:
common/built-in.o:(.data.init_sequence_r+0x48): undefined reference to `board_early_init_r'
Renaming that int rockchip_dnl_key_pressed(void)
back to int board_early_init_r
seems to fix compilation. I know you mentioned that you were working on the download but it was not working via sdcard.
@mcerveny I forgot about this. While compiling your latest version of caesar-u-boot I see this problem:
common/built-in.o:(.data.init_sequence_r+0x48): undefined reference to `board_early_init_r'
Forget to update configs/wx8-rk3128_defconfig - https://github.com/mcerveny/caesar-u-boot/commit/634b85f106c0eb3d5167c989729b564253d60816
I found "mirrors" with updated rockchip kernels https://github.com/JeffyCN/mirrors/tree/kernel and https://github.com/JeffyCN/rockchip_mirrors/tree/kernel (check also other branches :-) ). There are +366 patches. So I make new kernel develop-4.4-updates
branch (https://github.com/mcerveny/rockchip-linux/tree/develop-4.4-updates) and new branch wx8-updates
with applied WIP (https://github.com/mcerveny/rockchip-linux/tree/wx8-updates) so you can try it too.
* Updated the buildroot uboot and kernel packages to use @mcerveny repos directly (@mcerveny let me know if you are ok with this or you would rather have us forking those)
Ok. I will make more WIP/testing in subbranch to avoid instability. Still missing some features and persists some problems:
GPIO 41
)@mcerveny @alpgarcia some updates regarding batocera build:
output/ps5000/host/lib/gcc-linaro-arm-linux-gnueabihf
. Compile it manually once the buildroot fails at that step, and then generate a .stamp_built file (touch .stamp_built
) and resume compilation with make
.CONFIG_BLK_DEV_INITRD=y
arch/arm/boot/dts/wx8-rk3128.dts
BR2_PACKAGE_MALI_MP400_GBM=y
and add BR2_PACKAGE_MALI_MP400_WAYLAND=y
cd batocera.linux
make O=$PWD/output/ps5000 BR2_EXTERNAL=$PWD -C $PWD/buildroot batocera-ps5000_defconfig
cd output/ps5000
make
(grab a coffee... several ones in fact...)
Notes:
batocera.linux/configs/batocera-ps5000_defconfig
file and change the batocera package selection to look like this:
# Batocera System
BR2_PACKAGE_BATOCERA_SYSTEM=y
BR2_PACKAGE_BATOCERA_ALL_SYSTEMS=n
BR2_PACKAGE_BATOCERA_TOOLS=n
BR2_PACKAGE_BATOCERA_EXTRAS=n
BR2_PACKAGE_BATOCERA_KODI19=n
BR2_PACKAGE_BATOCERA_LINUX_FIRMWARES=n
After the build is complete, the full SD image is generated in the output/ps5000/images/batocera/images/ps5000
folder. Burn the image with dd or any other tool and test it.
Additional notes:
board/batocera/
\_ rockchip
\_ rk3128
\_ ps5000
\_ powkiddy_a12
\_ Q400
[...]
batocera.linux/package/batocera/core/batocera-system/Config.in
file. Just add a rules like if BR2_PACKAGE_BATOCERA_TARGET_PS5000
to enable/disable specific batocera packagesUpdate:
Audio "working" after adding dedicated overlay. Still no mixer controls, although volume controls work during boot (splash screen volume can be modified via volume keys)
Pipewire still having issues:
Starting pipewire: Connection failure: Connection refused
pa_context_connect() failed: Connection refused
Connection failure: Connection refused
pa_context_connect() failed: Connection refused
Connection failure: Connection refused
Connection failure: Connection refused
Connection failure: Connection refused
[E][00263.841696][ pulse-server.c: 539 do_set_client_name()] pulse-server 0x1fea110: failed to connect client: Host is down
[W][00263.848143][ reply.c: 72 reply_error()] client 0x1ffc7c0 [pactl]: ERROR command:9 (SET_CLIENT_NAME) tag:1 error:6 (Host is down)
Slow/idle boot
Switched to Mali wayland and did an experimental build:
Updated kernel board/batocera/rockchip/ps5000/linux-defconfig-fragment.config
to include RTL wifi support as per Martin's previous comment
Hello.
Update script
ruka_install_ps5000.sh (ruka_cfw_3.0_beta_1_20210806.tgz)
partition table does not match for userdata_ps5000_20210806.img partition (offset 0x00028800). I received updated version with different LBA offset 0x0002b000 !