-
Notifications
You must be signed in to change notification settings - Fork 289
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
async
API for Env
?
#685
Comments
Thank you for your interest. The current USB HID related
Storage related
Being async here is more problematic, since some of our security guarantees are tied to storage writes having persisted when execution continues. Can you help me understand why a blocking API doesn't work for you? |
Cool, then there's a chance I may propose a PR or two later 🙂
On my hardware, I'm using external eMMC memory for persistent storage, rather than embedded flash. It gives me quite a bit more capacity to work with, but it's also a slower channel where data is transferred over a bus 1 byte at a time with a checksum at the end for verification.
In my case, that's exactly why I'd prefer |
Question is how you'd design an So maybe it is indeed easier if you can use the sync OpenSK as is? Outside of user presence checking, our USB HID code is in the main loop, which is fully in your control. So the limitation that you can't run, e.g., display updates in parallel only applies when OpenSK processes a command. |
Hi! I'm working on a project using the RTIC framework on an STM32F4 microcontroller, and I'm interested in porting OpenSK to that architecture if at all possible.
RTIC leans heavily on Rust's
async
with interrupts for resource sharing and task scheduling. Right now it looks like the current definition of traits required byEnv
exclusively use blocking function calls. After a first review for my use-case it looks likeHidConnection::send_and_maybe_recv
,AttestationStore::{get,set}
,Storage::{read_slice,write_slice,erase_page}
, andUserPresence
would all need to access some kind of shared I/O peripherals. Under RTIC, non-blocking implementations of these traits would be awkward at best (and maybe highly unsafe at worst).Before I go down this route, I wanted to check in with the maintainers - is this something you'd be willing to merge if a PR was provided? Any other thoughts?
The text was updated successfully, but these errors were encountered: