I recently bought a mobile router powered by battery. I don't want to install the vendor's image due to some reason. Luckly they have opened the source and I can build my own image. In addition to Luci the vendor's image has a http page built in to show the HW information like signal strength and battery level etc. This part of function is closed source. I don't care about others but the battery level is esential. So I decided to make a change to luci status page to add the battery level(there's a node under /run/state that exposes the battery information). It looks like below.
Everything works as expected when I build and install the luci-mod-admin-full package separately. But later when I did a full build of the system image with the luci change the battery level doesn't show up. And if I do a force install for the luci-mod-admin-full.ipk from the bin/packages/aarch64_generic/luci/ folder then it works.
Below are the repos FYI.
This openwrt(actually based on legacy LEDE) repo is from vendor. I cloned it to my local storage and updated the luci feeds to below one where I made the battery level changes.
The change itself should be okay because it works when installed separately. It just looks like the change was built in but the binary was not installed to the system image. Does anyone have any idea what was wrong?
This is not OpenWrt. You will have to ask the vendor for questions surrounding there firmware.
It appears you are using firmware that is not from the official OpenWrt project.
When using forks/offshoots/vendor-specific builds that are "based on OpenWrt", there may be many differences compared to the official versions (hosted by OpenWrt.org). Some of these customizations may fundamentally change the way that OpenWrt works. You might need help from people with specific/specialized knowledge about the firmware you are using, so it is possible that advice you get here may not be useful.
Ask for help from the maintainer(s) or user community of the specific firmware that you are using.
Provide the source code for the firmware so that users on this forum can understand how your firmware works (OpenWrt forum users are volunteers, so somebody might look at the code if they have time and are interested in your issue).
If you believe that this specific issue is common to generic/official OpenWrt and/or the maintainers of your build have indicated as such, please feel free to clarify.
Sadly this device is not supported by official openwrt yet. I wish it will be because it's a really good and convinient device with LTE + wifi6 module integrated. It has meet all the needs for a router for travelling.
The device manufacturer doesn't have very well support so I asked here and hope there can be some helpful thoughts(Obviously a product vendor would tell you how to use their device but not how to develop code for it).
All the source codes are in above two repos.
I cannot argue that this is not an official openwrt because it indeed isn't. But obviously it was branched from legacy LEDE and shall work very similarly as official openwrt. At least as I can see the build steps are same. I'm not expecting some one just give me
the answer. But it'll very appraciated if there's any idea about what could be wrong or what I can look into.
Yes I did make clean before git clean. Also after these two steps I manually deleted the folders ignored by git to make sure nothing left. I even tried once to delete the repo and cloned a new one. But these made no difference.