Skip to contentSkip to conversation

Any ideas about mechanism of updating software/firmware?

Buildroot Xuebing Wang 2 participants 2 messages Apr 27, 2015

lore
Share & tools
lore
#0 lore raw

Hi Community,

I am new to Buildroot. I am developing a commercial product based on Buildroot 2014.02, and I need the mechanism to update software/firmware of the product.

Here are some of my thought:
1) In eMMC, there is a partition which can be exported to PC via USB mass storage.
2( Once u-boot detects a special key-combination or new file in above-mentioned eMMC partition, u-boot boots a special kernel with initramfs.
3) In above-mentioned kernel + initramfs, it compares version buildroot distribution kernel (/etc/issue) and version+build number embedded in the filename of in the partition above.
3.1) If a new version is found, it updates u-boot / kernel / rootfs.

Is it a good practice to update 'system/skeleton/etc/issue' when a new version will be 'git tag'ed and built?

Thanks.

Signature · 1 line
Xuebing
#1 lore raw

Hi Xuebing,

Quoted 2 lines

Is it a good practice to update 'system/skeleton/etc/issue' when a new version will be 'git tag'ed and built?

No, you shouldn't modify Buildroot's default files. All project-specific files should go in a new directory under board/, typically board/<customer>/<project>/. You can define a directory from which all files will be copied as is to the rootfs. For instance, try the following config:

BR2_ROOTFS_OVERLAY="board/<customer>/<project>/fs-overlay"

with a custom file board/<customer>/<project>/fs-overlay/etc/issue.

Note that if you want a dynamic value such as the git tag, you can use a post-build script writing to ${TARGET_DIR}/etc/issue (see BR2_ROOTFS_POST_BUILD_SCRIPT).

(Also note that /etc/os-release already contains the full version string).

Regards,
-v