Posts by pocng

    Hi there,
    A little information about TV boxes in general.
    Some BOX RK322x are really lowcost, so lowcost that the manufacturer to save a few cents do not populated certain component.

    Here's an example of a box we recently received:
    The motherboard is a R29_5G_LP3_V1.2_00523 and when we analyze the PCB we can see that the manufacturer hasn't installed the decoupling capacitors back of RK3228a CPU :( => This will make the box unstable.

    Decoupling capacitors play a multiple role. Among other things, they act as local energy reservoirs, providing the chips with instantaneous high-frequency energy. As a result, they absorb high frequencies and limit noise propagation via power supplies between chips. The closer the ceramic capacitors are placed to the chips, the more efficient they will be, given the parasitic inductance of the tracks and vias.

    The manufacturer had foreseen the installation of these decoupling capacitors... but didn't install them!
    If your box is unstable, check that they are present: If they are not present I advise you (if it is still possible) to return this! ....

    PoC.ng

    Hi ilmich

    When I wrote that the wifi card is not detected, it's because I don't have any SDIO device information in the dmesg (dmesg | grep -i sdio => nothing). I think I've got a DTS problem, probably something missing...
    I've read the article https://community.silabs.com/s/article/linu…?language=en_US and for the moment it's not a driver problem but more a mmc/sdio dts config problem, I'm going to have another look at the configs and prepare debug files to share. (same things with r29 tv box posted above...)

    Thanks for rtl8822bs-aml git projet, I'll test it as soon as I get to detect SDIO :)

    PS: for the r329q v3.1 I've finally made the merge request for boot support on the emmc :) and share this patched LibreElec built here

    PS2: the Android dmesg / dts / firmware / pictures for H20 and R29 box is shared here :)

    Hi @ilmich,

    I once again fell for a box on special offer for less than $7 (including postage, just received), an H20 (board tagged H20-221-1.8-B).
    The DTS decompiled from Android is almost identical to the DTS of the R2 _5G_LP3_V3.0-231005 box (quoted posts above but another wifi chipset).

    With the "R29" DTB:
    Boot on SDcard: OK
    Ethernet: OK
    HDMI/video Playback : OK (for over 3 hours)
    Power/Standby LED : OK

    UART Port Pin : OK
    SDIO WIFI : not detected :( => wifi is sdio 02e7/9086 / smartchip sci S9082H (on armbian forum i can see : its a clone of some wifi rtl chips , its closse source , no linux support)

    I've added this tvbox info (photo, android dts, backup...) to this share: http://sandbox02.poc.ng/tvbox/H20-221-V1_8-B/

    Hi @ilmich,

    I quickly checked the GPIOs for Wlan and so far I haven't found the source of the problem. At first glance, the pins are indeed those defined in the dtb...


    To help me identify the pinctrl from the gpio kernel debug file, I've made myself a correspondence table, I don't know if it can help other people but i share it here : http://sandbox02.poc.ng/tvbox/rk322x_linux_gpio.txt
    :)

    To be continue ... :)

    Hi ilmich

    You will find on this share : http://sandbox02.poc.ng/tvbox/r29/
    - the backup made with multitools
    - 100MB first rom backup (FIRST100MB-R29_5G_LP3_V3.0-231005_mxqpro4k.img.xz)
    - the android device tree in FS mode (R29_5G_LP3_V3.0-231005_android_dtbfs.tar.gz )
    - the source device tree created from devicetree fs android (R29_5G_LP3_V3.0-231005_android.dts)
    - the gpio kernel debug file (R29_5G_LP3_V3.0-231005_gpio.txt)
    - Board pictures (R29_5G_LP3_V3.0-231005-Photos.pdf)

    guerrero2694 can you confirm that you have the same? (look http://sandbox02.poc.ng/tvbox/r29/R29_…1005-Photos.pdf)

    Hi guerrero2694,

    You could provide the reference of the board (you have to remove the 4 screws hidden behind the little anti-slip pads).
    I also bought a model with the same reference "MXQ PRO 5g 4K" recently (today :) ), the reference of my card inside is: r29_5g_lp3_v3.0 231005

    I quickly tested the tvbox (on libreelec with r29 dtb):

    boot on SDcard : ok
    Ethernet: OK
    HDMI/video playback: ok
    USB : OK

    console UART Ok (requires soldering)
    maskrom pin : I'll need to look for it...

    Install to emmc : NO OK ( strange thing is that if I boot with multitool, and then reboot with quick removing the SD card, I manage to boot correctly... otherwise on cold boot the emmc is not detected by the uboot..)

    wifi : no detected

    For info => Android GPIO debug + dmesg :

    PrivateBin
    Visit this link to see the note. Giving the URL to anyone allows them to access the note, too.
    privatebin.net

    Hi ilmich ,

    Same thing : not working :(

    I'm going to check the changes I've made on my side (and how work fine) and I'll get back to you soon (with an MR I think), I'm out of town for the next two weeks...
    See you soon!

    log:

    Hi ilmich, thanks for this build, but... No new build not boot : same things

    Can you share your modification (diff?) to compare?

    for max-frequency I based it on a DTS with the same emmc (a samsung iot dev platform) and on another box that uses the same eemc component (an Amlogic Phicomm N1 box) => max-frequency = <0x2faf080>.


    Hi ilmich ,

    For the moment I'm trying to understand what this patch does exactly to set best option :) if you ever have good resources on understanding the possible options in DTS I'm interested, I'll do some testing, if I get something conclusive I'll open an MR. For the moment I've compiled the uboot present (tar.gz + patch) in your repository as standalone (for my tests), I've also set up the compilation chain for LibreElec with your repository but I'll have to read the manuals for good contributing ;) )


    Regards

    Hi ilmich , WIP :)

    I change dts and rebuild u-boot file based on https://github.com/paolosabatino/…vbox.patch#L107 -> to 137 patch



    hi,

    Yes, I'm 99% sure it's an eMMC. The chip on the mothercard is a KLM8G1GEME, and if I look at the Samsung datasheet, it's an eMMC (eMMC 5.1). Maybe enabling sdhci (Secure Digital Host Contoller Interdace) support in uboot ?

    When i seen "dm tree" on multitool mshc is used...

    mmc [ + ] rockchip_rk3288_dw_mshc |-- dwmmc@30000000
    blk [ + ] mmc_blk | `-- [email protected]
    mmc [ + ] rockchip_rk3288_dw_mshc |-- dwmmc@30020000
    blk [ ] mmc_blk | `-- [email protected]


    regards,

    Hi ilmich

    Thanks for your test build, but the same :(

    Do you think putting the dtb of "rk322x-box-mxq4kpro_r329q" in the u-boot build would help?
    I've tried to recompile multiboot but so far nothing conclusive (I'll have to read some docs on how to properly generate the image for this platform ;) ) .

    Any idea what the difference is between loading u-boot from the SD card and from the eMMC?

    Thanks for your support :)

    (from sdcard this test build work...)

    Full log:

    Hello everyone!
    First, thank @ilmich for this great port for rk322x devices!.

    I have a tv box (crylight TVbox Art no 4412) based on the "r329q" motherboard in version 3.1 (cpu : rk3229 / ram K4B4G0446Q, emmc Samsung KLM8G1GEME).
    Boot from SD card works perfectly and dtb rk322x-box-mxq4kpro_r329q is OK :) it's perfect.

    I'm now trying to install on the eMMC (using multitool or rkflashtool or rkdeveloptool)... Flash works fine, but when the box reboots, it can't find the MMC under UBOOT (when I break the boot process and use the mmc info command, I get no information):

    Image used: LibreELEC-RK322X.arm-11.0-nightly-20240218-d7324fb-rk322x.img.gz (also tested with 20240312)

    From multitool UBOOT :

    Boot from LibreElec on eMMC :

    If I boot Libreelec from SD card and force the boot from the eMMC : it's works! :

    Code
    I can see all mmc devices :
    => mmc list
    dwmmc@30000000: 1 (SD)
    dwmmc@30020000: 0


    I can even boot from it:
    devnum=0; run mmc_boot
    and everything works fine...

    So I'm having a problem with uboot at startup from eMMC, but I can't figure out what it is.

    Any idea?

    Thanks :)