i am running openwrt on a rockchip rk3318 tv box, basically following this guide this guide,
im curious if it possible to add flash new firmware feature just like ordinary routers
to be noted this not important at all and i just asking because of my curiousity so please dont blame me if you dont want to explain, but if you want to blame your neighbor its absolutely okay at least for me, not your neighbor.
Is your device running an official version of OpenWrt? I’m not sure that any STBs are actually supported by the official project. Where did the download come from (exact link would be helpful)?
it is official, i build the openwrt tarbal using image builder then extract it to the sdcard which is pre filled with armbian's files based on that guide (boot/,/lib/firmware/,/lib/modules/)
perhaps there is a way to manipulate system to make openwrt think that this is a router to make a similar "flash" functionality using dd, parted, or other tool since armbian and openwrt are both linux right ?
'Anything' can be done, but it requires the necessary low-level development first - and it starts with the kernel and its DTS, to get SOC and the specific device working and supported.
it is linux kernel from unifreq, there is also other kernel version including 5.10, i believe he shared the kernel source in github, like this, i know its not pure openwrt, or that it just an "alternative", i was thinking if i better understand how that "flashing" work i will take a look if i can make something equivalent/fake sysupgrade.
in other word, sysupgrade functionality depends on the kernel ?
because the environment is all from official openwrt, only the kernel is not, at least that is what i know, when i install or update a package, it is downloading from openwrt
Not the kernel, but the rest of the target details and how the storage system works. What you're using is clearly very much outside the mold of a typical OpenWrt install on an unconventional device. The people who were able to figure out how to get it running on that product would be the ones who would probably know why the flash upgrade option is not there.
device support will eventually become part of the next major OpenWrt release; it's now supported in a stable release.
You can't do step 2, before step 1 is done - and neither is available in vanilla OpenWrt so far. Bugs or other problems are only interesting from step 4 and onwards.
As-is, an unsupported binary image provided by someone, somewhere unknown, for a device not known to- nor supported by OpenWrt doesn't work as expected, breaking news, there's nothing that could be done from OpenWrt's side.
I can't explain it but based on my casual reading in the forum and the wiki the past couple of years, the web ui either does the same thing as, or is a front end to, the command /sbin/sysupgrade.
hexdump -Cvn 100 /sbin/sysupgrade shows it to be shell script so cat /sbin/sysupgrade will reveal a lot of detail on how it works.
You might be able to adapt it to use the custom installation method you mention.
Look into the related luci code if you also want the web ui to do the same.
For automated download via the utility, you would need to point to a repository based on your own build server output.
There have been discussions on the forum about how upgrade works, like memory checks/clearing, extracting the image and copying to storage, reboot, and firstboot tasks. Do some searching as well as reading related material in the doc wiki.