-
Posts
15 -
Joined
-
Last visited
Recent Profile Visitors
The recent visitors block is disabled and is not being shown to other users.
-
@primoitt: @ilmich solved it for me by compiling a libreleec 11 build with mpv binary included- Everything works, h264/hevc/mpeg2 ..... brilliant.
-
@ilmich Thanks a million, a small mpv binary that uses hardware to decode directly to screen from CLI is all I really need. In most posts on the libreelec forum thay said mpv is impossible to use/install/develop/whatever, so I did not ask for it at all. If you can help me with an "ad-hoc" build of librelec that a) does not load any interface at all or does just minimal gpu/screen initialization (optional...I do not really care if it loads b) has a .config file to give it a static ipv4 address..somewhere or any way to give it a static ip address via cli or whatever c) answers to a standard ssh on port 22 for controlling it (libreeelec does it) d) has an mpv binary that uses the hardware of the rockchip GPU for h265/hevc (low-res, 8bit) decoding I'll be forever grateful and a happier man.
-
Thanks @jock. I already tried the mpv binaries you compiled, long ago, and could not make them work properly.Dependencies also were a pain and the whole thing seemed too unstable for the use case I need (i.e. get ad udp video stream from the network and playt it). LIbreelec works, but has a weird lag problem with network streams, it always gets a 4/5 seconds delay, whatever parameters I use. LIbreelec on x86_64 does not have this problem, mpv on x86_64 w/VAAPI on Intel/AMD works perfectly/realtime with skinny distros (i.e. Alpine LInux or similar). Since libreelec/kodi/xbmc it's an old-school binary "frankenstein" blob that was born on consoles (xbox) it's impossible to launch a proper mpv inside it, or stop the interface from loading, and a lot of parameters are hardcoded in the binary itself. Libreleec developers are also extremely proud of their ultra-patched binary Golem creature they worship and do not want to assist anyone with a small mpv binary, which would be trivial to add, and that sucks. I'd love to compile a working ffmpeg/mpv for rockchip 322x: I think it should be this github: https://github.com/jernejsk/FFmpeg but it's totally unclear if it's the ffmpeg I need, since there is a TON of information scattered around forums that contradict each other and is a total mess. I'm -sadly- buying x86_64 hardware for my project, since this rockchip h264/hevc hardware acceleration thing has grown into a messy hairball of patches that "should work" but nobody knows how and -as of today - there are no userland tools to use it.
-
Hello fellow rk322x-hackers. I have a question: is hardware video decoding finally supported in this chip on the latest nightly builds ? Is there a binary mpv that works with accelerated GPU decoding for h264/hevc for these rx322x boxes ? I see @ilmich released a libreelec 11 with kernel 6.1 for the box, and works well,but LIbreELEC is not suited for my purposes, I just need a barebones linux (cli environment) with a working mpv with hardware decoding functional. Is it possible/available anywhere ? Is it included in the nightly builds ? Thanks a lot.
-
Just to let you know, and maybe give you some inspiration: playing with OpenWRT on this device (see my post), I've discovered that now there's support for LXC containers. So I installed a Debian-bullseye minimal rootfs as a LXC container in the device and now I run a pi-hole in it. So I get the router part via OpenWRT and the adblocker + a very fast and reliable dns/dhcp w/pihole together in the same device. Indeed very cool, with a $9 device, also quite fast. I'm amazed.
-
I have uploaded the OpenWRT-22.03-rc6 image for rk322x on my google drive here's the link: https://drive.google.com/file/d/1MxEDd1COSNiQDrocZLgSscracWDXdVqT/view?usp=sharing NOTES/INSTRUCTIONS: The .dtb for booting is the GENERIC rk3229 from LibreELEC made by @ilmich. Other .dtb files are in the FIRST PARTITION (fat32/boot) of the image. Copy & overwrite the one you prefer to rk322x-box.dtb. i.e.: Once the box has booted, enter the console via an attached keyboard and: mount /dev/mmcblk0p1 /mnt cp /mnt/<name of the dtb you prefer>.dtb /mnt/rk322x-box.dtb umount /mnt reboot The .dtb files are fom LIbreELEC 10 - check this post https://forum.libreelec.tv/thread/25236-unofficial-rk3228-rk3229-libreelec-10-x-builds/ on "supported devices" for names/clock etc. ON FIRST BOOT the eth0 (br-lan) interface has default IP to 192.168.1.1 SOMETIMES ON FIRST BOOT - AND ONLY FIRST ONE - eth0 gets "stuck" and does not respond: to make it work just enter the console with an attached keyboard and do a ping 192.168.1.xxx with xxx as a "live" host on your network: after a couple of pings the interface responds. It happened to me a couple of times, just on FIRST BOOT. Once you configure the interface in OpenWRT everything is ok. Point your browser to 192.168.1.1, configure OpenWRT. P.S. obviously you have to configure br-lan with an appropriate gateway/dns to install/upgrade packages. Check OpenWRT docs if in doubt. WIFI is disabled by default: to enable it, do : echo <name of wifi module> > /etc/modules.d/<name of wifi module> example: echo ssv6051 > /etc/modules.d/ssv6051 (do not enable ssv6051: for some reason it slows down everything) Enjoy.
-
@jock I've noticed that enabling wifi (i.e. loading module ssv6051) decreases performance A LOT in OpenWRT. Everything slows down 60/70 percent. With module NOT LOADED OpenWRT becomes VERY responsive and way faster. I think it would be better to keep it disabled/unloaded: the performance of those chips is terrible, their behaviour erratic, they're attached to the mmc bus, and I think they somewhat screw up things. The wifi interface maxes out at around 28Mbps at 1mt distance, and drops to 5/6Mbps at just 2,5 metres away. Overall they're useless in my opinion. This on your kernel 5.16.11 from bullseye. Is it a known issue ?
-
Since I'm not really a developer but a Linux System Administrator with hacky tendencies, that's what I usually do to use different Linux-es on these rk322x boxes: - I use MultiTool to burn a .. Multitool image on the internal flash of the box, so I get a fat32 uboot/extlinux partition that boots - I boot from Multitool again, drop to a shell and repartition the internal flash w fdisk, then I modify the extlinux.conf with the kernel boot parameters I need (kernel, initrd, dtb ..) In OpenWRT case it was pretty easy: it has no initrd, and it's as bare-bone as it can be: you just have to add a line "init=/sbin/init" to the kernel line and youre basically good to go. The challenge was to find a suitable arch: rpi2b (bcm 2709) is the perfect match i.e.: arm_cortex-a7_neon-vfpv4: So I grabbed the .img from OpenWRT, put it into the multitool SD card, mounted it with a loop device, and did a simple "cp -R" of the whole sys partition to the second partition of the internal flash. Then I extracted a 5.16.11-rk322x kernel & modules & firmware from bullseye-minimal build from @jock, and copied them into /lib. The next step was to find a suitable .dtb to boot: I used @ilmich dtbs from his LIbreELEC 10.0 builds, since they worked beautifully in the tvboxes rk3228a/rev 3.1 I own. Then I modified the /etc/modules.d files of OpenWRT to load proper modules for the rk322x board: wifi, thermal, etc. Then I added the bootup "hardware-optimization" armbian script, just to optimize things further, IRQ routing, eth0 queues etc. Sync & reboot: OpenWRT is up & running, awaiting connection on default address 192.168.1.1 on the ethernet port. All packages work, kmods are simply written in the wrong directory inside /lib/modules but the kernel gets them from the right place /lib/modules/$(uname -r) so in practice everything is 100% OK, as long as the modules are present. I copied ALL the modules since I have a lot of free space in the internal flash, it's a full ext4 install, not a squashfs rootfs. Even updates are OK. I'm fine-tuning some parameters, then I'll add link to the .gz image, ready to flash w Multitool, later today.
-
Today I assembled a fully working image of OpenWRT 22.03.0 for this rk322x tvbox. It's a patchwork/mix from multitool/debian kernel 5.16.11 and the userland from the latest OpenWRT I could find for raspberry PI 2/B (same cpu arch): OpenWrt 22.03.0-rc6 r19590-042d558536 / LuCI openwrt-22.03 branch git-22.213.35949-d09fbe0 I've tested wireguard/vxlan/wifi, all working nice (wireless AP too, much to my surprise!). You can turn this (rather old for 2022) TVBOX into an extremely capable router with a nice www interface (too bad for the 100Mbit LAN port...). I guess you can add some more ethernet interfaces using USB ports, but do not expect too much on the performance side. The best way to add ethernet ports for these devices is a managed switch, so you can use VLANs (€20 for a cheap 5 ports on Amazon). Speed of wireguard VPN is quite nice (around 70Mbps on iperf3). If anyone is interested I can post the link for the image (flashable via multitool). It was - as usual - painful, but a nice challenge. edit: I had to do this because there are no OpenWRT releases for rockchip/32bit armv7: arm64 builds for Rockchip 3318/3328 are officially available.
-
Thanks for your suggestion. Much to my amazement network boot works pretty well: I managed to boot Alpine Linux via a modified init script that gets its rootfs from an AoE target. I did all the debugging via tcpdump fron another system, avoiding using a serial console, and zapped the mmbclk2 partition via the usual fdisk utility. U-boot properly started making a BOOTP/PXE/DHCP broadcast request. I post here my findings: first the dnsmasq.conf file (tftp+dhcp all in one) - Mac address redacted, insert the one from the box you want to boot --- dnsmasq.conf interface=br0 bogus-priv filterwin2k no-resolv localise-queries no-negcache no-hosts dhcp-authoritative listen-address=192.168.111.128 dhcp-option=3,192.168.111.1 dhcp-option=6,192.168.111.1 server=192.168.111.1 dhcp-range=interface=br0,192.168.111.35,192.168.111.40,infinite enable-tftp tftp-root=/var/tftp dhcp-host=ee:58:f3:XX:XX:XX,set:d01,192.168.111.35,cazzillo,infinite cname=set:d01,cazzillo --- end of dnsmasq.conf This assumes dns+router ad 192.168.111.1, and "cuts off" 5 IPs from 192.168.111.35 to 192.168.111.40. U-boot requests the following file: /var/tftp/pxelinux.cfg/01-ee-58-f3-XX-XX-XX As its PXELINUX config, i.e.: FDT /rk322x-box.dtb LINUX /kernel.img INITRD /initramfs-rk322x APPEND modloop=/modloop-rk322x modules=loop,squashfs,sd-mod,usb-storage,aoe ip=dhcp In the tftp root (/var/tftp) I've put the kernel, (alpine, modded by me) initrd, .dtb file, edited "/var/tftp/pxelinux.cfg/01-ee-58-f3-XX-XX-XX" and it booted! Pretty impressive. I've not dwelled into armbian because I am not into systemd, which is the "init" of Debian derivatives. I won't touch it with a 10-foot pole, but shouldn't be too hard to make it boot.
-
If anyone needs it, as a convenience, I leave here a google drive link for an Armbian "bullseye-minimal" image for the 322x box with FreePbx16 & Asterisk18 compiled in. Took a whole afternoon of compiling code to make it work. It's a .gz image you can restore via MultiTool. root password: freepbx Freepbx login: admin/freepbx Hardware .dtb is left vanilla to boot on any platform - use rk322x-config to configure proper cpu/ddr/storage/led speed. Gets IP from DHCP, you can of course use armbian-configure to use wifi or whatever. ODBC connector compiled and included for mysql, codec g729 compiled and included. It's working quite well with softphones ad Yealink VOIP DECT phones, on a couple of pjsip trunks. I expect it to work well with at least 8/10 extensions, maybe more. Interface is quite heavy for my taste (node.js ....) but it seems it's the "new normal" we have to adapt to. It's 2 gigs in size. https://drive.google.com/file/d/1PYuakmA-9JNVmJ3VOYE7GFQBo6dqN-8t/view?usp=sharing all credits to @jock for creating the original Debian Bullseye image.
-
CSC Armbian for RK3318/RK3328 TV box boards
Vittorio Mori replied to jock's topic in Rockchip CPU Boxes
-
I have a question: is possible to enable network-boot for those boxes ? Do they boot in EFI mode ? How do they get proper ethernet drivers ? I read from main page: " Boot device order: With Armbian also comes mainline U-boot. If you install Armbian or just the bootloader in the eMMC or the Jump Start on internal NAND, the bootloader will look for valid bootable images in this order: External SD Card External USB Stick in OTG Port Internal eMMC " Should I re-compile U-boot ? Any pointers ?
-
-
Hello, I own a lot of those MXqpro/4K boxes: I am thinking of re-purposing them to become a "one-channel" DVR viewers (from network streams made with FFMPEG). The project Multitool/Armbian is working exactly as it should on these boxes, but I have some troubles because Armbian is simply...too big for what I need, and I find it difficult to deal with, thanks to systemd. There is a way to make a stripped-down version of armbian (or maybe just a kernel & minimal binaries/libs) that has FFMPEG/MPV with hardware decoding enabled and a dumb/programmable startup script like the ancient AUTOEXEC.BAT in DOS ? Maybe starting with "multitool" (that boots a minimal rockchip 4.4 kernel) ? Something like LIbreElec, but without kodi and with FFMPEG/MPV instead. Maybe even statically linked (ffmpeg is already there, MPV & rockchip libs are not). LibreELEC is maybe the right thing, but it's "overlay" structure is somewhat obscure to deal with, and I don't want to boot from an SD card. I have a lot of experience in assembling x86_64 stuff for other minimal linux projects (Alpine Linux in particular), but those Debian Linuxes with systemd and all the nonsensical junk put me down, they are an endless loop of dependency nightmares when you try to modify the smallest of things. Maybe someone can point me in the right direction ?