- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Is it possible to set the application Major/Minor version numbers from a file, such as a header, versus defining it in the build target?
I want to go from this build target
Quickprojects.OTA_Test-QuicksilverEval-FreeRTOS-LwIP ota2_image APP_VERSION_FOR_OTA2_MAJOR=1 APP_VERSION_FOR_OTA2_MINOR=2
to
Quickprojects.OTA_Test-QuicksilverEval-FreeRTOS-LwIP ota2_image
and add a header file similar to this
version.h
#define APP_VERSION_FOR_OTA2_MAJOR 1
#define APP_VERSION_FOR_OTA2_MINOR 2
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
The WICED build system would take values from the makefile wiced_apps.mk and not from .h or .c files. In your case, the .cfg file took the default version values set in wiced_apps.mk. My bad. The major and minor versions are saved in application DCT to allow OTA2 version check during update.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Yes. It is possible to set application major/minor version and save it in application DCT section. Please see snip.ota2_example for more details. The versions have been set in ota2_dct_t in ota2_test_dct.c.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thanks. I believe I tried that and it seemed that the ota image builder application did not populate the major and minor field in the image header. I could of done something wrong so I will take another look at it.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
If i set it in the DCT, is it only populated in the DCT, or will it also populate the fields in the OTA2 image header?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
To followup, I just built it with the version set in the DCT ( Major=0 and Minor=1) and built a ota2_image and the OTA2_image_file.cfg shows 0 for the MAJOR_VERSION and the MINOR_VERSION.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
The WICED build system would take values from the makefile wiced_apps.mk and not from .h or .c files. In your case, the .cfg file took the default version values set in wiced_apps.mk. My bad. The major and minor versions are saved in application DCT to allow OTA2 version check during update.