-
Notifications
You must be signed in to change notification settings - Fork 25
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
Merge lpc55 into embedded runner #97
Merged
Merged
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
Ran some tests on NK3AM - Athene (development device):
Execution logs (nrf52)
|
To do:
|
9 tasks
robin-nitrokey
force-pushed
the
embedded-runner-lpc55
branch
3 times, most recently
from
November 15, 2022 16:09
ca0120e
to
afecbdf
Compare
The semihosting log target requires the cortex-m-semihosting dependency.
We only need the rtt-target dependency if the log-rtt feature is enabled.
This allows the user to select either log-rtt or log-semihosting.
The usbfs-peripheral feature is not used and does not cause any changes, so we can safely remove it.
This patch merges the old lpc55 runner into the embedded runner. It also removes dead code and features that are no longer used. Fixes #79
robin-nitrokey
force-pushed
the
embedded-runner-lpc55
branch
from
November 15, 2022 16:46
42add2b
to
e48f6d7
Compare
This commit causes an error message during the build (though it still succeeds):
Does this make sense to you @daringer? Otherwise this should be ready to merge. Edit: Should be fixed now. |
For the nrf52, no-encrypted-storage does not have any effects. For the lpc55, we only want to enable it in development builds as the release firmware is expected to be run with PRINCE enabled.
This patch renames the existing bin artifact to elf and then adds a real bin artifact generated by objcopy with `-O binary`.
This patch adds a builder Makefile for building and running the firmware for the lpc55.
robin-nitrokey
force-pushed
the
embedded-runner-lpc55
branch
from
November 15, 2022 16:58
e48f6d7
to
441869f
Compare
daringer
approved these changes
Nov 17, 2022
lgtm, some random tests on NK3mini also show no issues |
4 tasks
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 merges the lpc55 runner into the embedded runner (currently only used for nrf52). This makes the firmware very much hardware agnostic, reduces the code duplication between the lpc55 and nrf52 targets and makes maintenance easier.
Fixes #79
(The old lpc55 runner is not yet deleted in this PR so that it still can be used for reference.)
For comparison, the numbers of lines of Rust code in the runners (calculated with
cloc
) are:Build instructions
To build the firmware, you need a recent Rust version with the
thumbv8m.main-none-eabi
target, e. g. installed withrustup
:There are also some required libraries and tools, e. g. for Debian:
Now you can build the lpc55 and nrf52 runners:
Execution logs (lpc55)
Test of USB communication, touch button, LED, admin and FIDO2 applications:
(The test failures are caused by the device being a development device. The tests still show that the communication works correctly though.)