Tockloader-rs: v0.1.0 release candidate#11
Open
eva-cosma wants to merge 18 commits into
Open
Conversation
This is a starting point for the tockloader-rs implementation.
remove .random
Co-authored-by: Micu Ana <ana.micu@oxidos.io>
Signed-off-by: George Cosma <george.cosma@oxidos.io>
--------- Co-authored-by: Micu Ana <ana.micu@oxidos.io> Co-authored-by: Negrila Rares <rares_negrila@yahoo.com>
chore: add pkg-config to prerequisites for wsl
Signed-off-by: Ana Micu <ana.micu@oxidos.io> Co-authored-by: Ana Micu <ana.micu@oxidos.io>
Co-authored-by: Micu Ana <ana.micu@oxidos.io>
Co-authored-by: Micu Ana <ana.micu@oxidos.io>
This file contains hidden or 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
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.
Tockloader-rs: v0.1.0 release candidate
Overview
This pull request contains all of the necessary features for an initial alpha release of tockloader-rs. Here is a comprehensive list of all major features:
tockloader listenimplemented usingratatui, based on @CAmi307's implementation and her version of tock which adds support for a packet-based communication. See also thetock-process-consolelib inside of this PR.tockloader infoimplemented with both probe-rs and bootloader protocol.tockloader listimplemented with both probe-rs and bootloader protocoltockloader installimplemented with both probe-rs and bootloader protocoltbf-parserlib based on tock's, but modified to work with non-static lifetimesTechnical Details
Inspired by probe-rs, we decided to extend the usability of tockloader from a CLI to both a CLI and a rust library which can then be used by users however they see fit. This can be useful in creating bespoke user interfaces and will aid in automation.
The
tockloader-libwas designed with partial connection agnosticism in mind. This means that the library can be used with either a bootloader connection or a probe-rs connection. This is achieved by using theConnectionenum. Implementation as a trait was considered, but deemed unnecessary due to the fact that the two connections are fundamentally different and would require different implementations of the same functions.The error handling in the library is comprehensive and should provide the user with enough information to diagnose any issues that may arise. The error handling is based on the
thiserrorcrate for the library and theanyhowcrate for the CLI. In the (very near) future, we will be looking into logging to provide the user with additional information.Future plans
Tockloader-rs is certainly not finished. Here are some of the features that we are planning to implement in the future:
uninstall,erase-apps, and flash IO (flash,read,write,dump-flash-page).Acknowledgements
This project would not have been possible without the help of @micuami and @NegrilaRares who have worked tirelessly to get this project to where it is now. We would also like to thank @CAmi307 for her work on the new protocol and for the ratatui library which we have used to implement the
tockloader listencommand.