-
Notifications
You must be signed in to change notification settings - Fork 90
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Dynamic App Loader Helper #387
Open
viswajith-g
wants to merge
5
commits into
tock:master
Choose a base branch
from
viswajith-g:app_loader
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
this app sends the tab file of an app that needs to be flashed to the capsule. once the app binary is written to flash, the userland app requests kernel to load the app.
alistair23
suggested changes
Apr 2, 2024
alistair23
reviewed
Apr 2, 2024
alistair23
reviewed
Apr 2, 2024
alistair23
reviewed
Apr 2, 2024
examples/tests/app_loader/main.c
Outdated
uint32_t app_size = 0; // variable to store app size | ||
|
||
// Tock Application Binary to be flashed. | ||
const uint8_t app_binary[] = {0x2, 0x0, 0x34, 0x0, 0x0, 0x8, 0x0, 0x0, 0x1, 0x0, 0x0, 0x0, 0xD7, 0x75, 0x50, 0x6E, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This application can build for any architecture. How does this data then work?
alistair23
reviewed
Apr 2, 2024
alistair23
reviewed
Apr 2, 2024
alistair23
reviewed
Apr 2, 2024
alistair23
reviewed
Apr 2, 2024
alistair23
reviewed
Apr 2, 2024
alistair23
reviewed
Apr 2, 2024
alistair23
reviewed
Apr 2, 2024
examples/tests/app_loader/main.c
Outdated
} | ||
|
||
for (uint32_t offset = 0; offset < write_count; offset++) { | ||
memcpy(write_buffer, &app_binary[FLASH_BUFFER_SIZE * offset], FLASH_BUFFER_SIZE); // copy binary to write buffer |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What if app_binary
isn't a multiple of FLASH_BUFFER_SIZE
?
alistair23
reviewed
Apr 2, 2024
alistair23
reviewed
Apr 2, 2024
… in internal/binaries.c. cleaned up and formatted removed old code removed userspace code from a previous implementation that was giving rise to confusion. added comments to app_loader.h added binaries headers and updated code added binaries in external files to make the app file more readable. Added a new subscribe and callback to support the async setup update readme
ppannuto
added
the
blocked-on-kernel
Waiting for parallel changes in the kernel to stabilize
label
Oct 9, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR introduces the helper app to validate the kernel's dynamic process loading functionality (tock/tock#3941). The helper app triggers the dynamic process loading with a button press.
This application is located in
/examples/tests/app_loader
and was tested on the nRF52840DK. A previous version of the dynamic process loader was tested with the same application on an Imix board as well.